at 18.09-beta 527 B view raw
1{ config, lib, pkgs, ... }: 2 3with lib; 4 5{ 6 7 ###### interface 8 9 options = { 10 11 hardware.cpu.intel.updateMicrocode = mkOption { 12 default = false; 13 type = types.bool; 14 description = '' 15 Update the CPU microcode for Intel processors. 16 ''; 17 }; 18 19 }; 20 21 22 ###### implementation 23 24 config = mkIf config.hardware.cpu.intel.updateMicrocode { 25 # Microcode updates must be the first item prepended in the initrd 26 boot.initrd.prepend = mkOrder 1 [ "${pkgs.microcodeIntel}/intel-ucode.img" ]; 27 }; 28 29}