mirror of
https://github.com/NixOS/nixos-hardware.git
synced 2025-11-08 19:46:10 +01:00
common/gpu: add option to choose intel-compute-runtime variant
This commit is contained in:
parent
a98f1a2b75
commit
4100cffdbe
1 changed files with 14 additions and 1 deletions
|
|
@ -23,6 +23,15 @@
|
||||||
default = true;
|
default = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
computeRuntime = lib.mkOption {
|
||||||
|
description = "intel-compute-runtime variant to use";
|
||||||
|
type = lib.types.enum [
|
||||||
|
"default"
|
||||||
|
"legacy"
|
||||||
|
];
|
||||||
|
default = "default";
|
||||||
|
};
|
||||||
|
|
||||||
vaapiDriver = lib.mkOption {
|
vaapiDriver = lib.mkOption {
|
||||||
description = "Intel VAAPI driver to use (use null to use both)";
|
description = "Intel VAAPI driver to use (use null to use both)";
|
||||||
type = lib.types.nullOr (
|
type = lib.types.nullOr (
|
||||||
|
|
@ -59,7 +68,11 @@
|
||||||
useIntelMediaDriver = cfg.vaapiDriver == "intel-media-driver" || cfg.vaapiDriver == null;
|
useIntelMediaDriver = cfg.vaapiDriver == "intel-media-driver" || cfg.vaapiDriver == null;
|
||||||
intel-media-driver = pkgs.intel-media-driver;
|
intel-media-driver = pkgs.intel-media-driver;
|
||||||
intel-media-driver-32 = pkgs.driversi686Linux.intel-media-driver;
|
intel-media-driver-32 = pkgs.driversi686Linux.intel-media-driver;
|
||||||
intel-compute-runtime = pkgs.intel-compute-runtime;
|
intel-compute-runtime =
|
||||||
|
if cfg.computeRuntime == "legacy" then
|
||||||
|
pkgs.intel-compute-runtime-legacy1
|
||||||
|
else
|
||||||
|
pkgs.intel-compute-runtime;
|
||||||
vpl-gpu-rt = pkgs.vpl-gpu-rt or pkgs.onevpl-intel-gpu;
|
vpl-gpu-rt = pkgs.vpl-gpu-rt or pkgs.onevpl-intel-gpu;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue