set default kernel

This commit is contained in:
Travis Staton 2023-01-27 23:21:47 -05:00
parent 9cac87a79c
commit defb166e1e
5 changed files with 11 additions and 39 deletions

View file

@ -3,22 +3,11 @@ rpi:
{
imports = [ rpi ];
nixpkgs = {
overlays = [
(final: prev: {
raspberrypiWirelessFirmware =
final.rpi-kernels.v5_15_36.wireless-firmware;
raspberrypifw = final.rpi-kernels.v5_15_36.firmware;
})
];
};
hardware.raspberry-pi.deviceTree.base-dtb = "bcm2710-rpi-zero-2.dtb";
# u-boot expects bcm2837-rpi-zero-2.dtb for the zero 2 w (as of
# 2020.04), although the kernel has 2710. We rename it to satisfy
# u-boot for now.
# u-boot expects bcm2837-rpi-zero-2.dtb for the zero 2 w (this is
# the device tree name in the upstream kernel), Rename the raspberry
# pi dtb to the expected name to satisfy u-boot.
hardware.raspberry-pi.deviceTree.postInstall = ''
mv $out/broadcom/bcm2710-rpi-zero-2.dtb $out/broadcom/bcm2837-rpi-zero-2.dtb
'';
boot.kernelPackages =
pkgs.linuxPackagesFor (pkgs.rpi-kernels.v5_15_36.kernel);
}