cryodev/templates/raspberry-pi/hardware.nix
steffen 6ad46e7452
Some checks failed
CI / flake-check (pull_request) Successful in 33s
CI / build-hosts (pull_request) Failing after 47s
fix Pi build and CI pipeline ordering
- Fix Pi kernel build: disable includeDefaultModules in initrd.
  NixOS all-hardware.nix includes dw-hdmi which doesn't exist in
  the RPi4 kernel 6.12, causing module-shrunk to fail.
- Fix CI: SD image build now depends on build-hosts instead of
  flake-check, so it won't run if the Pi build fails.
- Apply same fix to raspberry-pi template.
2026-03-14 14:56:10 +01:00

27 lines
593 B
Nix

{ pkgs, lib, ... }:
{
boot = {
kernelPackages = pkgs.linuxKernel.packages.linux_rpi4;
initrd = {
availableKernelModules = [
"xhci_pci"
"usbhid"
"usb_storage"
];
# Disable default x86 modules that don't exist in the Pi kernel (e.g. dw-hdmi)
includeDefaultModules = false;
};
};
fileSystems = {
"/" = {
device = "/dev/disk/by-label/NIXOS_SD";
fsType = "ext4";
options = [ "noatime" ];
};
};
nixpkgs.hostPlatform = lib.mkDefault "aarch64-linux";
hardware.enableRedistributableFirmware = true;
}