2022-12-04 13:45:43 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
pkgs,
|
2024-04-11 14:42:56 +01:00
|
|
|
config,
|
2022-12-04 13:45:43 +00:00
|
|
|
...
|
2023-09-18 03:56:58 +01:00
|
|
|
}: let
|
|
|
|
inherit (lib.modules) mkIf;
|
2024-04-01 17:18:10 +01:00
|
|
|
|
|
|
|
is_x86 = "${pkgs.system}" == "x86_64-linux";
|
2023-09-18 03:56:58 +01:00
|
|
|
in {
|
2024-04-01 17:18:10 +01:00
|
|
|
hardware = {
|
2024-04-01 17:52:00 +01:00
|
|
|
enableAllFirmware = false; # we include a more minimal subset for base
|
|
|
|
enableRedistributableFirmware = false;
|
2024-04-01 17:18:10 +01:00
|
|
|
wirelessRegulatoryDatabase = true;
|
|
|
|
|
2024-04-01 17:52:00 +01:00
|
|
|
firmware = with pkgs; [
|
|
|
|
linux-firmware
|
|
|
|
];
|
|
|
|
|
2024-04-11 14:41:45 +01:00
|
|
|
ksm.enable = mkIf (!config.boot.isContainer) true;
|
2024-04-01 17:18:10 +01:00
|
|
|
|
|
|
|
i2c.enable = true;
|
|
|
|
|
|
|
|
cpu = {
|
|
|
|
intel.updateMicrocode = mkIf is_x86 true;
|
|
|
|
amd.updateMicrocode = mkIf is_x86 true;
|
|
|
|
};
|
|
|
|
};
|
2021-12-20 23:48:26 +00:00
|
|
|
}
|