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 boot.initrd.prepend = [ "${pkgs.microcodeIntel}/intel-ucode.img" ];
26 };
27
28}