From 06c46e390287088e07eef9db3ff7ba20ef9cbdae Mon Sep 17 00:00:00 2001 From: Matei Dibu Date: Thu, 12 Sep 2024 19:20:09 +0300 Subject: [PATCH 1/4] dell-precision-5560: init --- dell/precision/5560/default.nix | 40 +++++++++++++++++++++++++++++++++ flake.nix | 1 + 2 files changed, 41 insertions(+) create mode 100644 dell/precision/5560/default.nix diff --git a/dell/precision/5560/default.nix b/dell/precision/5560/default.nix new file mode 100644 index 000000000..6c7ebaddb --- /dev/null +++ b/dell/precision/5560/default.nix @@ -0,0 +1,40 @@ +{ + config, + lib, + ... +}: { + imports = [ + ../../../common/pc/laptop + ../../../common/pc/laptop/ssd + ../../../common/cpu/intel + ../../../common/gpu/intel/tiger-lake + ../../../common/gpu/nvidia/prime.nix + ../../../common/gpu/nvidia/turing + ]; + + hardware.enableRedistributableFirmware = lib.mkDefault true; + + boot = { + blacklistedKernelModules = ["nouveau"]; + kernelModules = ["kvm-intel"]; + kernelParams = ["i915.modeset=1"]; + }; + + hardware = { + graphics = { + enable = lib.mkDefault true; + enable32Bit = lib.mkDefault true; + }; + nvidia = { + package = config.boot.kernelPackages.nvidiaPackages.beta; + modesetting.enable = lib.mkDefault true; + open = lib.mkDefault false; + prime = { + intelBusId = "PCI:0:2:0"; + nvidiaBusId = "PCI:1:0:0"; + }; + }; + }; + + powerManagement.cpuFreqGovernor = lib.mkDefault "performance"; +} diff --git a/flake.nix b/flake.nix index c146e968d..21e9a4288 100644 --- a/flake.nix +++ b/flake.nix @@ -67,6 +67,7 @@ dell-poweredge-r7515 = import ./dell/poweredge/r7515; dell-precision-3541 = import ./dell/precision/3541; dell-precision-5530 = import ./dell/precision/5530; + dell-precision-5560 = import ./dell/precision/5560; dell-precision-7520 = import ./dell/precision/7520; dell-xps-13-7390 = import ./dell/xps/13-7390; dell-xps-13-9300 = import ./dell/xps/13-9300; From c97623b428306711dc07dc68fd98b9f0b882ba3c Mon Sep 17 00:00:00 2001 From: Matei Dibu Date: Mon, 23 Sep 2024 12:48:34 +0300 Subject: [PATCH 2/4] dell-precision-5560: cleanup --- dell/precision/5560/default.nix | 33 +++++++++------------------------ 1 file changed, 9 insertions(+), 24 deletions(-) diff --git a/dell/precision/5560/default.nix b/dell/precision/5560/default.nix index 6c7ebaddb..e82938087 100644 --- a/dell/precision/5560/default.nix +++ b/dell/precision/5560/default.nix @@ -1,40 +1,25 @@ +{ lib, ... }: { - config, - lib, - ... -}: { imports = [ ../../../common/pc/laptop ../../../common/pc/laptop/ssd ../../../common/cpu/intel ../../../common/gpu/intel/tiger-lake - ../../../common/gpu/nvidia/prime.nix ../../../common/gpu/nvidia/turing ]; hardware.enableRedistributableFirmware = lib.mkDefault true; boot = { - blacklistedKernelModules = ["nouveau"]; - kernelModules = ["kvm-intel"]; - kernelParams = ["i915.modeset=1"]; + blacklistedKernelModules = [ "nouveau" ]; + kernelModules = [ "kvm-intel" ]; + kernelParams = [ "i915.modeset=1" ]; }; - hardware = { - graphics = { - enable = lib.mkDefault true; - enable32Bit = lib.mkDefault true; - }; - nvidia = { - package = config.boot.kernelPackages.nvidiaPackages.beta; - modesetting.enable = lib.mkDefault true; - open = lib.mkDefault false; - prime = { - intelBusId = "PCI:0:2:0"; - nvidiaBusId = "PCI:1:0:0"; - }; - }; - }; + services.xserver.videoDrivers = [ "nvidia" ]; - powerManagement.cpuFreqGovernor = lib.mkDefault "performance"; + hardware.nvidia.prime = { + intelBusId = "PCI:0:2:0"; + nvidiaBusId = "PCI:1:0:0"; + }; } From a4e69fc9ba6728f7ea9c8b7cb9c72b3744885880 Mon Sep 17 00:00:00 2001 From: Matei Dibu Date: Mon, 23 Sep 2024 12:48:45 +0300 Subject: [PATCH 3/4] dell-precision-5560: add README --- dell/precision/5560/README.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 dell/precision/5560/README.md diff --git a/dell/precision/5560/README.md b/dell/precision/5560/README.md new file mode 100644 index 000000000..8518cbd61 --- /dev/null +++ b/dell/precision/5560/README.md @@ -0,0 +1,20 @@ +## Dell Precision 5560 + +- Intel i7-11800H +- 00:02.0 VGA compatible controller [0300]: Intel Corporation TigerLake-H GT1 [UHD Graphics] [8086:9a60] (rev 01) +- 01:00.0 3D controller [0302]: NVIDIA Corporation TU117GLM [T1200 Laptop GPU] [10de:1fbc] (rev a1) + +If you want to use the new Intel Xe driver, add this to your config: +```nix +boot.extraModprobeConfig = '' + options xe force_probe=9a60 + options i915 force_probe=!9a60 +''; +``` + +And you should decide what you want to do with the NVIDIA GPU, either sync or offload. + +Fwupd works, you can update the BIOS and DBX. +```nix +services.fwupd.enable = true; +``` From 2061ba2611eb29efb24ffe4d730fc29ad20503a2 Mon Sep 17 00:00:00 2001 From: Matei Dibu Date: Fri, 27 Sep 2024 18:45:07 +0300 Subject: [PATCH 4/4] dell-precision-5560: remove redundant config --- dell/precision/5560/default.nix | 4 ---- 1 file changed, 4 deletions(-) diff --git a/dell/precision/5560/default.nix b/dell/precision/5560/default.nix index e82938087..6b6e3a0b7 100644 --- a/dell/precision/5560/default.nix +++ b/dell/precision/5560/default.nix @@ -11,13 +11,9 @@ hardware.enableRedistributableFirmware = lib.mkDefault true; boot = { - blacklistedKernelModules = [ "nouveau" ]; - kernelModules = [ "kvm-intel" ]; kernelParams = [ "i915.modeset=1" ]; }; - services.xserver.videoDrivers = [ "nvidia" ]; - hardware.nvidia.prime = { intelBusId = "PCI:0:2:0"; nvidiaBusId = "PCI:1:0:0";