add kernel patches from nixpkgs

This commit is contained in:
Charlotte 🦝 Delenk 2024-10-01 15:10:13 +02:00
parent ece5c45722
commit d1676165fc

View file

@ -9,30 +9,32 @@ buildLinux (
args
// {
src = linuxKernel.packages.linux_rpi4.kernel.src;
version = linuxKernel.packages.linux_rpi4.kernel.modDirVersion;
version = linuxKernel.packages.linux_rpi4.kernel.modDirVersion + "-v8";
defconfig = "bcm2711_defconfig";
autoModules = false;
kernelPatches = [
{
name = "devterm";
patch = ./linux-devterm.patch;
extraStructuredConfig = with lib.kernel; {
AXP20X_ADC = module;
AXP20X_POWER = module;
BATTERY_AXP20X = module;
CHARGER_AXP20X = module;
INPUT_AXP20X_PEK = yes;
MFD_AXP20X = yes;
MFD_AXP20X_I2C = yes;
REGULATOR_AXP20X = yes;
BACKLIGHT_OCP8178 = module;
DRM_PANEL_CWD686 = module;
TI_ADC081C = module;
I2C_BCM2835 = yes;
FW_LOADER_COMPRESS = yes;
};
}
];
kernelPatches =
linuxKernel.packages.linux_rpi4.kernel.kernelPatches
++ [
{
name = "devterm";
patch = ./linux-devterm.patch;
extraStructuredConfig = with lib.kernel; {
AXP20X_ADC = module;
AXP20X_POWER = module;
BATTERY_AXP20X = module;
CHARGER_AXP20X = module;
INPUT_AXP20X_PEK = yes;
MFD_AXP20X = yes;
MFD_AXP20X_I2C = yes;
REGULATOR_AXP20X = yes;
BACKLIGHT_OCP8178 = module;
DRM_PANEL_CWD686 = module;
TI_ADC081C = module;
I2C_BCM2835 = yes;
FW_LOADER_COMPRESS = yes;
};
}
];
enableCommonConfig = false;
}
)