some fixes

This commit is contained in:
2025-03-05 17:30:11 +01:00
parent 6b1058f6a4
commit 420a2a2fb6
10 changed files with 398 additions and 328 deletions

3
modules/nixos/flakes.nix Normal file
View File

@@ -0,0 +1,3 @@
{
nix.settings.experimental-features = [ "nix-command" "flakes" ];
}

View File

@@ -1,8 +1,8 @@
{
config,
lib,
pkgs,
...
config,
lib,
pkgs,
...
}:
{
@@ -29,14 +29,7 @@
intelBusId = "PCI:0:2:0";
};
package = config.boot.kernelPackages.nvidiaPackages.mkDriver {
version = "565.77";
sha256_64bit = "sha256-CnqnQsRrzzTXZpgkAtF7PbH9s7wbiTRNcM0SPByzFHw=";
sha256_aarch64 = "sha256-LSAYUnhfnK3rcuPe1dixOwAujSof19kNOfdRHE7bToE=";
openSha256 = "sha256-Fxo0t61KQDs71YA8u7arY+503wkAc1foaa51vi2Pl5I=";
settingsSha256 = "sha256-VUetj3LlOSz/LB+DDfMCN34uA4bNTTpjDrb6C6Iwukk=";
persistencedSha256 = "sha256-wnDjC099D8d9NJSp9D0CbsL+vfHXyJFYYgU3CwcqKww=";
};
package = config.boot.kernelPackages.nvidiaPackages.latest;
};
# overwrite the blacklists set previously
boot.extraModprobeConfig = "";
@@ -65,31 +58,9 @@
ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x030000", ATTR{power/control}="auto", ATTR{remove}="1"
'';
# # Remove the whole bridge responsible for the VGA/3D controller
# ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x8086", ATTR{class}=="0x060400", ATTR{power/control}="auto", ATTR{remove}="1"
# # somehow the udev rules are not enough to prevent the nouveau driver from loading
# # Also unload remove the bus by id manually
# # unload 0000:01:00.1 and 0000:01:00.0
# # at boot echo 1 > /sys/bus/pci/devices/0000:01:00.1/remove
# # at boot echo 1 > /sys/bus/pci/devices/0000:01:00.0/remove
# systemd.services.remove-nouveau = {
# description = "Remove Nouveau PCI devices";
# wantedBy = [ "multi-user.target" ];
# after = [ "sysinit.target" ];
# serviceConfig = {
# Type = "oneshot";
# ExecStart = "${pkgs.coreutils}/bin/echo 1 > /sys/bus/pci/devices/0000:01:00.1/remove";
# ExecStart = "${pkgs.coreutils}/bin/echo auto > /sys/bus/pci/devices/0000:00:01.0/power/control";
# ExecStart = "${pkgs.coreutils}/bin/echo 1 > /sys/bus/pci/devices/0000:01:00.0/remove";
# ExecStart = "${pkgs.coreutils}/bin/echo auto > /sys/bus/pci/devices/0000:00:01.0/power/control";
# };
# };
boot.blacklistedKernelModules = [ "nouveau" "nvidia" "nvidia_drm" "nvidia_modeset" ];
}