From 28684889c8d4632309cf21ca3f41d570498f11b0 Mon Sep 17 00:00:00 2001 From: Matteo Bongiovanni Date: Sun, 16 Jun 2024 16:45:50 +0200 Subject: [PATCH] System76 Gaze18 nvidia System76 Gaze18 flake System76 Gaze18 fix System76 Gaze18 fix --- flake.nix | 1 + system76/gaze18/default.nix | 40 +++++++++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+) create mode 100644 system76/gaze18/default.nix diff --git a/flake.nix b/flake.nix index b203958..a34fe9e 100644 --- a/flake.nix +++ b/flake.nix @@ -250,6 +250,7 @@ supermicro-x10sll-f = import ./supermicro/x10sll-f; supermicro-x12scz-tln4f = import ./supermicro/x12scz-tln4f; system76 = import ./system76; + system76-gaze18 = import ./system76/gaze18; system76-darp6 = import ./system76/darp6; toshiba-swanky = import ./toshiba/swanky; tuxedo-infinitybook-v4 = import ./tuxedo/infinitybook/v4; diff --git a/system76/gaze18/default.nix b/system76/gaze18/default.nix new file mode 100644 index 0000000..bdfe735 --- /dev/null +++ b/system76/gaze18/default.nix @@ -0,0 +1,40 @@ +{ config, lib, pkgs, ... }: +{ + imports = [ + ../. + ]; + boot.initrd.kernelModules = [ "nvidia" ]; + + hardware.opengl = { + enable = true; + driSupport = true; + driSupport32Bit = true; + extraPackages = with pkgs; [ + vaapiVdpau + ]; + }; + + services.xserver.videoDrivers = ["nvidia"]; + + hardware.nvidia = { + + modesetting.enable = true; + + powerManagement.finegrained = true; + + nvidiaSettings = true; + + package = config.boot.kernelPackages.nvidiaPackages.stable; + prime = { + intelBusId = "PCI:0:2:0"; + nvidiaBusId = "PCI:1:0:0"; + offload = { + enable = true; + enableOffloadCmd = true; + }; + }; + }; +} + + +