Switch Kell back to Nvidia

This commit is contained in:
Thomas Avé 2024-11-20 13:59:28 +01:00
parent a1ceb72f49
commit 7e82900408
8 changed files with 82 additions and 136 deletions

View File

@ -2,15 +2,15 @@
"nodes": {
"ags": {
"inputs": {
"nixpkgs": "nixpkgs",
"systems": "systems"
"astal": "astal",
"nixpkgs": "nixpkgs"
},
"locked": {
"lastModified": 1728326430,
"narHash": "sha256-tV1ABHuA1HItMdCTuNdA8fMB+qw7LpjvI945VwMSABI=",
"lastModified": 1731966249,
"narHash": "sha256-9hDeMy6S2q1wWBFGiJic5yUms19zW8LhAX9MlCtuN6k=",
"owner": "Aylur",
"repo": "ags",
"rev": "60180a184cfb32b61a1d871c058b31a3b9b0743d",
"rev": "12e0bfefd2051c43d7450123fcb095f655b891e8",
"type": "github"
},
"original": {
@ -39,11 +39,11 @@
]
},
"locked": {
"lastModified": 1730968822,
"narHash": "sha256-NocDjINsh6ismkhb0Xr6xPRksmhuB2WGf8ZmXMhxu7Y=",
"lastModified": 1731774881,
"narHash": "sha256-1Dxryiw8u2ejntxrrv3sMtIE8WHKxmlN4KeH+uMGbmc=",
"owner": "hyprwm",
"repo": "aquamarine",
"rev": "a49bc3583ff223f426cb3526fdaa4bcaa247ec14",
"rev": "b31a6a4da8199ae3489057db7d36069a70749a56",
"type": "github"
},
"original": {
@ -52,6 +52,27 @@
"type": "github"
}
},
"astal": {
"inputs": {
"nixpkgs": [
"ags",
"nixpkgs"
]
},
"locked": {
"lastModified": 1731952585,
"narHash": "sha256-Sh1E7sJd8JJM3PCU1ZOei/QWz97OLCENIi2rTRoaniw=",
"owner": "aylur",
"repo": "astal",
"rev": "664c7a4ddfcf48c6e8accd3c33bb94424b0e8609",
"type": "github"
},
"original": {
"owner": "aylur",
"repo": "astal",
"type": "github"
}
},
"flake-compat": {
"flake": false,
"locked": {
@ -158,11 +179,11 @@
]
},
"locked": {
"lastModified": 1730837930,
"narHash": "sha256-0kZL4m+bKBJUBQse0HanewWO0g8hDdCvBhudzxgehqc=",
"lastModified": 1732025103,
"narHash": "sha256-qjEI64RKvDxRyEarY0jTzrZMa8ebezh2DEZmJJrpVdo=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "2f607e07f3ac7e53541120536708e824acccfaa8",
"rev": "a46e702093a5c46e192243edbd977d5749e7f294",
"type": "github"
},
"original": {
@ -210,15 +231,15 @@
"hyprwayland-scanner": "hyprwayland-scanner",
"nixpkgs": "nixpkgs_3",
"pre-commit-hooks": "pre-commit-hooks",
"systems": "systems_2",
"systems": "systems",
"xdph": "xdph"
},
"locked": {
"lastModified": 1731086737,
"narHash": "sha256-3072G8QfgmLCEDwU4HDpnLsQmijaSyhs308MY27Z9/k=",
"lastModified": 1732098770,
"narHash": "sha256-uCJOkbv79r4PRyi/KHyqENn/A5pVoIvrQ4kiVUZPo4E=",
"ref": "refs/heads/main",
"rev": "3b66351eeb76e802bac37cc892529549efc49905",
"revCount": 5426,
"rev": "e5fa017172156fa5c70fedeaee5f51eace9577c0",
"revCount": 5483,
"submodules": true,
"type": "git",
"url": "https://github.com/hyprwm/Hyprland"
@ -290,11 +311,11 @@
]
},
"locked": {
"lastModified": 1730131687,
"narHash": "sha256-pzJd3u0s4JVAquGav3oGxSvPdfdUkOSf+KxnZK2BWyA=",
"lastModified": 1732041261,
"narHash": "sha256-jTvfpYrtaLEKMR3N89hUjIgh18GxnHsEUg1+w8gk4hg=",
"ref": "refs/heads/main",
"rev": "b98cc80aab041677cd7648f6e44c18e8f36fa907",
"revCount": 48,
"rev": "09a1f2b89f61b32b3d7a58e8d1eae93653009859",
"revCount": 50,
"type": "git",
"url": "https://github.com/shezdy/hyprsplit"
},
@ -315,11 +336,11 @@
]
},
"locked": {
"lastModified": 1730968903,
"narHash": "sha256-zFvzLXcSm0Ia4XI1SE4FQ9KE63hlGrRWhLtwMolWuR8=",
"lastModified": 1731702627,
"narHash": "sha256-+JeO9gevnXannQxMfR5xzZtF4sYmSlWkX/BPmPx0mWk=",
"owner": "hyprwm",
"repo": "hyprutils",
"rev": "3ce0cde8709cdacbfba471f8e828433b58a561e9",
"rev": "e911361a687753bbbdfe3b6a9eab755ecaf1d9e1",
"type": "github"
},
"original": {
@ -375,15 +396,15 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1725634671,
"narHash": "sha256-v3rIhsJBOMLR8e/RNWxr828tB+WywYIoajrZKFM+0Gg=",
"owner": "NixOS",
"lastModified": 1731676054,
"narHash": "sha256-OZiZ3m8SCMfh3B6bfGC/Bm4x3qc1m2SVEAlkV6iY7Yg=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "574d1eac1c200690e27b8eb4e24887f8df7ac27c",
"rev": "5e4fbfb6b3de1aa2872b76d49fafc942626e2add",
"type": "github"
},
"original": {
"owner": "NixOS",
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
@ -423,11 +444,11 @@
},
"nixpkgs_3": {
"locked": {
"lastModified": 1730785428,
"narHash": "sha256-Zwl8YgTVJTEum+L+0zVAWvXAGbWAuXHax3KzuejaDyo=",
"lastModified": 1731676054,
"narHash": "sha256-OZiZ3m8SCMfh3B6bfGC/Bm4x3qc1m2SVEAlkV6iY7Yg=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "4aa36568d413aca0ea84a1684d2d46f55dbabad7",
"rev": "5e4fbfb6b3de1aa2872b76d49fafc942626e2add",
"type": "github"
},
"original": {
@ -439,11 +460,11 @@
},
"nixpkgs_4": {
"locked": {
"lastModified": 1730785428,
"narHash": "sha256-Zwl8YgTVJTEum+L+0zVAWvXAGbWAuXHax3KzuejaDyo=",
"lastModified": 1731676054,
"narHash": "sha256-OZiZ3m8SCMfh3B6bfGC/Bm4x3qc1m2SVEAlkV6iY7Yg=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "4aa36568d413aca0ea84a1684d2d46f55dbabad7",
"rev": "5e4fbfb6b3de1aa2872b76d49fafc942626e2add",
"type": "github"
},
"original": {
@ -471,11 +492,11 @@
},
"nur": {
"locked": {
"lastModified": 1731094464,
"narHash": "sha256-C0cfE3mFNq0AblMTjswuLgGwhSlw0qHF01+ZkYJ1cm8=",
"lastModified": 1732099841,
"narHash": "sha256-XwpBKjFzkBhZJ//m+iAsvgO4XLuFoui9GRyE7R+PQ5Y=",
"owner": "nix-community",
"repo": "NUR",
"rev": "52f1bda909b9bbcb834508499d4bc4b2ba4b5545",
"rev": "13f83516cdc2fd2fce2ee0f62d82ec698fb39184",
"type": "github"
},
"original": {
@ -495,11 +516,11 @@
"nixpkgs-stable": "nixpkgs-stable"
},
"locked": {
"lastModified": 1730814269,
"narHash": "sha256-fWPHyhYE6xvMI1eGY3pwBTq85wcy1YXqdzTZF+06nOg=",
"lastModified": 1731363552,
"narHash": "sha256-vFta1uHnD29VUY4HJOO/D6p6rxyObnf+InnSMT4jlMU=",
"owner": "cachix",
"repo": "git-hooks.nix",
"rev": "d70155fdc00df4628446352fc58adc640cd705c2",
"rev": "cd1af27aa85026ac759d5d3fccf650abe7e1bbf0",
"type": "github"
},
"original": {
@ -536,21 +557,6 @@
"type": "github"
}
},
"systems_2": {
"locked": {
"lastModified": 1689347949,
"narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=",
"owner": "nix-systems",
"repo": "default-linux",
"rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default-linux",
"type": "github"
}
},
"worktimer": {
"inputs": {
"flake-parts": "flake-parts_2",
@ -599,11 +605,11 @@
]
},
"locked": {
"lastModified": 1730743262,
"narHash": "sha256-iTLqj3lU8kFehPm5tXpctzkD274t/k1nwSSq3qCWXeg=",
"lastModified": 1731703417,
"narHash": "sha256-rheDc/7C+yI+QspYr9J2z9kQ5P9F4ATapI7qyFAe1XA=",
"owner": "hyprwm",
"repo": "xdg-desktop-portal-hyprland",
"rev": "09b23cef06fe248e61cec8862c04b9bcb62f4b6d",
"rev": "8070f36deec723de71e7557441acb17e478204d3",
"type": "github"
},
"original": {

View File

@ -21,7 +21,7 @@
services.hyprpaper = {
settings = {
wallpaper = [
"DP-3,${./hyprland/files/wallpaper.png}"
"DP-1,${./hyprland/files/wallpaper.png}"
"DP-2,${./hyprland/files/wallpaper.png}"
"HDMI-A-1,${./hyprland/files/wallpaper.png}"
];
@ -29,8 +29,8 @@
};
wayland.windowManager.hyprland.settings = {
monitor = [
"DP-3,preferred,0x550,1"
"DP-2,preferred,1920x0,1"
"DP-2,preferred,0x550,1"
"DP-1,preferred,1920x0,1"
"HDMI-A-1,preferred,5760x550,1"
];
input.kb_options = "compose:rctrl, caps:super, altwin:swap_alt_win";

View File

@ -122,10 +122,6 @@ in {
"minsize 1 1, title:^()$,class:^(steam)$"
"stayfocused, title:^()$,class:^(steam)$"
];
workspace = [
"w[t1], gapsout:0, gapsin:0, border: 0, rounding:0"
"w[tg1], gapsout:0, gapsin:0, border: 0, rounding:0"
];
layerrule = [ "noanim,ags_bar_0" "noanim,selection" ];
general = {
gaps_in = 1;

View File

@ -13,6 +13,7 @@
cursor_shape = "block";
cursor_beam_thickness = 1;
scrollback_lines = 100000;
scrollback_fill_enlarged_window = "yes";
enable_audio_bell = "no";
confirm_os_window_close = 0;
modify_font = "cell_height 115%";

View File

@ -1624,7 +1624,7 @@ function pause_state(name, enabled)
if user_opts.showtitle then
if enabled then
state.lastvisibility = user_opts.visibility
visibility_mode('always', true)
visibility_mode('auto', true)
show_osc()
else
if (mp.get_property('video') ~= 'no') then

View File

@ -79,12 +79,12 @@ return {
dap.listeners.before.launch.dapui_config = function()
ui.open()
end
dap.listeners.before.event_terminated.dapui_config = function()
ui.close()
end
dap.listeners.before.event_exited.dapui_config = function()
ui.close()
end
-- dap.listeners.before.event_terminated.dapui_config = function()
-- ui.close()
-- end
-- dap.listeners.before.event_exited.dapui_config = function()
-- ui.close()
-- end
end,
},
}

View File

@ -13,63 +13,11 @@
nixpkgs.config.cudaSupport = true;
hardware.nvidia-container-toolkit.enable = true;
hardware.nvidia = {
package = config.boot.kernelPackages.nvidiaPackages.stable;
package = config.boot.kernelPackages.nvidiaPackages.beta;
modesetting.enable = true;
powerManagement.enable = false;
powerManagement.finegrained = true;
powerManagement.finegrained = false;
open = false;
nvidiaSettings = true;
prime = {
intelBusId = "PCI:0:2:0";
nvidiaBusId = "PCI:1:0:0";
offload = {
enable = true;
enableOffloadCmd = true;
};
};
};
systemd.services.nvidia-control-devices = {
wantedBy = [ "multi-user.target" ];
serviceConfig.ExecStart = "${pkgs.linuxPackages.nvidia_x11.bin}/bin/nvidia-smi";
};
specialisation = {
docked.configuration = {
system.nixos.tags = [ "docked" ];
hardware.nvidia = {
powerManagement.finegrained = pkgs.lib.mkForce false;
prime.offload.enable = pkgs.lib.mkForce false;
prime.offload.enableOffloadCmd = pkgs.lib.mkForce false;
prime.sync.enable = pkgs.lib.mkForce true;
};
};
disable.configuration = {
system.nixos.tags = [ "disable" ];
hardware.nvidia = {
modesetting.enable = pkgs.lib.mkForce false;
powerManagement.enable = pkgs.lib.mkForce false;
powerManagement.finegrained = pkgs.lib.mkForce false;
open = pkgs.lib.mkForce false;
nvidiaSettings = pkgs.lib.mkForce false;
prime.offload.enable = pkgs.lib.mkForce false;
prime.offload.enableOffloadCmd = pkgs.lib.mkForce false;
};
boot.extraModprobeConfig = ''
blacklist nouveau
options nouveau modeset=0
'';
services.udev.extraRules = ''
# Remove NVIDIA USB xHCI Host Controller devices, if present
ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x0c0330", ATTR{power/control}="auto", ATTR{remove}="1"
# Remove NVIDIA USB Type-C UCSI devices, if present
ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x0c8000", ATTR{power/control}="auto", ATTR{remove}="1"
# Remove NVIDIA Audio devices, if present
ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x040300", ATTR{power/control}="auto", ATTR{remove}="1"
# Remove NVIDIA VGA/3D controller devices
ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x03[0-9]*", ATTR{power/control}="auto", ATTR{remove}="1"
'';
boot.blacklistedKernelModules = [ "nouveau" "nvidia" "nvidia_drm" "nvidia_modeset" ];
};
};
}

View File

@ -4,9 +4,10 @@ let
in {
imports = [
(import ../Common/default.nix { inherit inputs pkgs; })
(import ../Common/nvidia.nix { inherit inputs pkgs config; })
(import ../Common/desktop.nix { inherit inputs pkgs config; })
(import ../Common/nfs.nix { inherit pkgs serverIP; })
(import ../Common/android.nix { inherit pkgs serverIP; })
(import ../Common/android.nix { inherit pkgs; })
];
# Kernel
@ -18,8 +19,9 @@ in {
boot.kernelModules = [ "zenpower amd_pstate=active" ];
boot.kernelParams = ["amd_pstate=active"];
# AMD CPU & GPU
boot.initrd.kernelModules = [ "amdgpu" ];
# AMD GPU
# boot.initrd.kernelModules = [ "amdgpu" ];
services.logind.extraConfig = ''HandlePowerKey=suspend'';
# Virtualization
@ -32,13 +34,6 @@ in {
# enable = true;
# };
# hardware.graphics.extraPackages = with pkgs; [
# rocmPackages.clr.icd
# ];
# systemd.tmpfiles.rules = [
# "L+ /opt/rocm/hip - - - - ${pkgs.rocmPackages.clr}"
# ];
networking.wg-quick.interfaces = {
wg0 = {
address = [ "10.0.0.10/24" " 2a02:a03f:83ad:2101::2/128" ];