Add device tree binary for Xiaomi Pad 6 and update flake.nix for hardware support
This commit is contained in:
@@ -2,3 +2,4 @@
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.mbn filter=lfs diff=lfs merge=lfs -text
|
||||
*.bin filter=lfs diff=lfs merge=lfs -text
|
||||
*.dtb filter=lfs diff=lfs merge=lfs -text
|
||||
|
||||
@@ -94,38 +94,42 @@
|
||||
# BUILT-IN HARDWARE DRIVERS FOR INITRD-LESS BOOT
|
||||
# ---------------------------------------------------------
|
||||
|
||||
# 0. Core Subsystems (Forced to override NixOS defaults)
|
||||
# 0. Core Storage & Security Subsystems
|
||||
SCSI = pkgs.lib.mkForce yes;
|
||||
BLK_DEV_SD = pkgs.lib.mkForce yes;
|
||||
EXTCON = pkgs.lib.mkForce yes;
|
||||
RPMB = pkgs.lib.mkForce yes;
|
||||
|
||||
# USB Frameworks
|
||||
USB_XHCI_HCD = pkgs.lib.mkForce yes;
|
||||
USB_XHCI_PLATFORM = pkgs.lib.mkForce yes;
|
||||
USB_ROLE_SWITCH = pkgs.lib.mkForce yes;
|
||||
USB_GADGET = pkgs.lib.mkForce yes;
|
||||
# Master Physical Layer Framework
|
||||
PHY_QCOM_QMP = pkgs.lib.mkForce yes;
|
||||
|
||||
# 1. UFS Storage Stack
|
||||
# 1. UFS Storage Stack (Mounts the root disk)
|
||||
SCSI_UFSHCD = yes;
|
||||
SCSI_UFSHCD_PLATFORM = yes;
|
||||
SCSI_UFS_QCOM = yes;
|
||||
PHY_QCOM_QMP_UFS = yes;
|
||||
|
||||
# 2. Display Subsystem
|
||||
DRM_MSM = yes;
|
||||
# 2. Qualcomm SoC Subsystems (Required for Display)
|
||||
QCOM_OCMEM = pkgs.lib.mkForce yes;
|
||||
QCOM_LLCC = pkgs.lib.mkForce yes;
|
||||
QCOM_COMMAND_DB = pkgs.lib.mkForce yes;
|
||||
|
||||
# 3. USB Host & Recovery Stack
|
||||
USB_DWC3 = yes;
|
||||
USB_DWC3_QCOM = yes;
|
||||
PHY_QCOM_QMP_USB = yes;
|
||||
USB_STORAGE = yes;
|
||||
USB_UAS = yes;
|
||||
# 3. Display Subsystem (Turns on the screen)
|
||||
DRM_MSM = yes;
|
||||
};
|
||||
};
|
||||
in
|
||||
lib.recurseIntoAttrs (pkgs.linuxPackagesFor customKernel);
|
||||
|
||||
# -------------------------------------------------------------------
|
||||
# 4. Hardware & Device Tree Override
|
||||
# -------------------------------------------------------------------
|
||||
hardware.deviceTree.enable = true;
|
||||
|
||||
# Point Nix directly to your known-working binary DTB file
|
||||
hardware.deviceTree.package = lib.mkForce (pkgs.runCommand "pipa-working-dtb" {} ''
|
||||
mkdir -p $out/qcom
|
||||
cp ${./sm8250-xiaomi-pipa.dtb} $out/qcom/sm8250-xiaomi-pipa.dtb
|
||||
'');
|
||||
hardware.deviceTree.name = "qcom/sm8250-xiaomi-pipa.dtb";
|
||||
|
||||
# -------------------------------------------------------------------
|
||||
|
||||
BIN
Binary file not shown.
Reference in New Issue
Block a user