mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-20 04:19:00 +02:00
nixos/ryzen-smu: init module
Provide a module for installing ryzen_smu, a Linux kernel driver that exposes access to the SMU (System Management Unit) for certain AMD Ryzen Processors. Installs monitor_cpu, a userspace tool for viewing info. Using fork of original to match ryzen_monitor_ng, a more advanced userspace tool for accessing the SMU via this kernel module, planned for a later commit.
This commit is contained in:
parent
cc0f056492
commit
ba0566726e
26
nixos/modules/hardware/cpu/amd-ryzen-smu.nix
Normal file
26
nixos/modules/hardware/cpu/amd-ryzen-smu.nix
Normal file
|
@ -0,0 +1,26 @@
|
|||
{ config
|
||||
, lib
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
cfg = config.hardware.cpu.amd.ryzen-smu;
|
||||
ryzen-smu = config.boot.kernelPackages.ryzen-smu;
|
||||
in
|
||||
{
|
||||
options.hardware.cpu.amd.ryzen-smu = {
|
||||
enable = mkEnableOption ''
|
||||
ryzen_smu, a linux kernel driver that exposes access to the SMU (System Management Unit) for certain AMD Ryzen Processors.
|
||||
|
||||
WARNING: Damage cause by use of your AMD processor outside of official AMD specifications or outside of factory settings are not covered under any AMD product warranty and may not be covered by your board or system manufacturer's warranty
|
||||
'';
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
boot.kernelModules = [ "ryzen-smu" ];
|
||||
boot.extraModulePackages = [ ryzen-smu ];
|
||||
environment.systemPackages = [ ryzen-smu ];
|
||||
};
|
||||
|
||||
meta.maintainers = with lib.maintainers; [ Cryolitia phdyellow ];
|
||||
}
|
|
@ -54,6 +54,7 @@
|
|||
./hardware/corectrl.nix
|
||||
./hardware/cpu/amd-microcode.nix
|
||||
./hardware/cpu/amd-sev.nix
|
||||
./hardware/cpu/amd-ryzen-smu.nix
|
||||
./hardware/cpu/intel-microcode.nix
|
||||
./hardware/cpu/intel-sgx.nix
|
||||
./hardware/cpu/x86-msr.nix
|
||||
|
|
Loading…
Reference in a new issue