mirror of
https://github.com/aviallon/nixos-lib.git
synced 2026-04-06 01:38:06 +00:00
[Hardware/AMD] Begin rocm-overlay suport
This commit is contained in:
parent
3dc72fae02
commit
1e54cd710b
1 changed files with 12 additions and 3 deletions
|
|
@ -2,6 +2,7 @@
|
||||||
with lib;
|
with lib;
|
||||||
let
|
let
|
||||||
cfg = config.aviallon.hardware.amd;
|
cfg = config.aviallon.hardware.amd;
|
||||||
|
devCfg = config.aviallon.developer;
|
||||||
generalCfg = config.aviallon.general;
|
generalCfg = config.aviallon.general;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
|
@ -24,9 +25,16 @@ in
|
||||||
"amdgpu.mes" = mkIf generalCfg.unsafeOptimizations 1;
|
"amdgpu.mes" = mkIf generalCfg.unsafeOptimizations 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; []
|
||||||
|
++ [
|
||||||
rocm-smi
|
rocm-smi
|
||||||
];
|
]
|
||||||
|
++ optionals devCfg.enable ([]
|
||||||
|
++ [ rocminfo ]
|
||||||
|
++ optional (hasAttr "hipify-perl" pkgs) pkgs.hipify-perl
|
||||||
|
++ optional (hasAttr "tensorflow2-rocm" pkgs) pkgs.tensorflow2-rocm
|
||||||
|
)
|
||||||
|
;
|
||||||
|
|
||||||
services.xserver.videoDrivers = []
|
services.xserver.videoDrivers = []
|
||||||
++ optional cfg.useProprietary "amdgpu-pro"
|
++ optional cfg.useProprietary "amdgpu-pro"
|
||||||
|
|
@ -35,6 +43,7 @@ in
|
||||||
"radeon"
|
"radeon"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
hardware.opengl.enable = true;
|
||||||
hardware.opengl.extraPackages = with pkgs; mkIf (!cfg.useProprietary) [
|
hardware.opengl.extraPackages = with pkgs; mkIf (!cfg.useProprietary) [
|
||||||
rocm-opencl-icd
|
rocm-opencl-icd
|
||||||
rocm-opencl-runtime
|
rocm-opencl-runtime
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue