notably, this relaxes some constraints on the kernel so that e.g. postmarketOS kernel actually passes eval checks (and boots to ssh! no graphics yet)
27 lines
1.0 KiB
Nix
27 lines
1.0 KiB
Nix
{ lib, pkgs, ... }:
|
|
|
|
{
|
|
config = lib.mkIf (pkgs.system == "x86_64-linux") {
|
|
boot.initrd.availableKernelModules = [
|
|
"xhci_pci" "ahci" "sd_mod" "sdhci_pci" # nixos-generate-config defaults
|
|
"usb_storage" # rpi needed this to boot from usb storage, i think.
|
|
"nvme" # to boot from nvme devices
|
|
# efi_pstore evivars
|
|
|
|
# added (speculatively) 2024/05/21; these were implicitly being added by nixos/modules/system/boot/kernel.nix
|
|
# i've copied not all of them, but most
|
|
"mmc_block"
|
|
"dm_mod"
|
|
# USB keyboards
|
|
"uhci_hcd" "ehci_hcd" "ehci_pci" "ohci_hcd" "ohci_pci" "xhci_hcd" "xhci_pci" "usbhid" "hid_generic" "hid_lenovo" "hid_apple" "hid_roccat" "hid_logitech_hidpp" "hid_logitech_dj" "hid_microsoft" "hid_cherry" "hid_corsair"
|
|
# x86 keyboard stuff
|
|
"pcips2" "atkbd" "i8042"
|
|
# stage-2 init needs rtc?
|
|
"rtc_cmos"
|
|
];
|
|
|
|
hardware.cpu.amd.updateMicrocode = true; # desktop
|
|
hardware.cpu.intel.updateMicrocode = true; # laptop
|
|
};
|
|
}
|