xiaomi-lavender: Fix build using new options
manufacturer = "Xiaomi";
};
- mobile.device.info = rec {
+ mobile.device.info = {
# TODO : make kernel part of options.
kernel = pkgs.callPackage ./kernel { kernelPatches = pkgs.defaultKernelPatches; };
- bootimg_qcdt = false;
- flash_offset_base = "0x00000000";
- flash_offset_kernel = "0x00008000";
- flash_offset_ramdisk = "0x01000000";
- flash_offset_second = "0x00f00000";
- flash_offset_tags = "0x00000100";
- flash_pagesize = "4096";
-
- # This device adds skip_initramfs to cmdline for normal boots
- boot_as_recovery = true;
- # Though this device has "boot_as_recovery", it still has a classic
- # recovery partition for recovery. Go figure.
- has_recovery_partition = true;
-
- vendor_partition = "/dev/disk/by-partlabel/vendor";
- gadgetfs.functions = {
- rndis = "rndis_bam.rndis";
- # FIXME: This is likely the right function name, but doesn't work.
- # adb = "ffs.usb0";
- };
};
+
mobile.hardware = {
soc = "qualcomm-sdm660";
# 4GB for the specific revision supported.
};
};
+ mobile.system.android = {
+ # This device adds skip_initramfs to cmdline for normal boots
+ boot_as_recovery = true;
+
+ # Though this device has "boot_as_recovery", it still has a classic
+ # recovery partition for recovery. Go figure.
+ has_recovery_partition = true;
+
+ bootimg.flash = {
+ offset_base = "0x00000000";
+ offset_kernel = "0x00008000";
+ offset_ramdisk = "0x01000000";
+ offset_second = "0x00f00000";
+ offset_tags = "0x00000100";
+ pagesize = "4096";
+ };
+ };
+
+ mobile.system.vendor.partition = "/dev/disk/by-partlabel/vendor";
+
boot.kernelParams = [
"earlycon=msm_serial_dm,0xc170000"
"androidboot.hardware=qcom"
"buildvariant=userdebug"
];
+ mobile.system.type = "android";
+
mobile.usb.mode = "gadgetfs";
# FIXME: attribute to sources.
mobile.usb.idVendor = "2717"; # Xiaomi Communications Co., Ltd.
mobile.usb.idProduct = "FF80"; # Mi/Redmi series (RNDIS)
- mobile.system.type = "android";
+ mobile.usb.gadgetfs.functions = {
+ rndis = "rndis_bam.rndis";
+ # FIXME: This is likely the right function name, but doesn't work.
+ # adb = "ffs.usb0";
+ };
}
