diff options
author | Akshay <[email protected]> | 2023-02-04 08:47:17 +0000 |
---|---|---|
committer | Akshay <[email protected]> | 2023-02-04 08:47:17 +0000 |
commit | 1e99e723c598fface4bedffe60220d2c424bcae9 (patch) | |
tree | 946e18b94c3b87d46b9fcecc0bd563f693dfc460 /hosts | |
parent | 7df356950a6a6455a562ea6d349b03945e189e46 (diff) |
enable i915
Diffstat (limited to 'hosts')
-rw-r--r-- | hosts/myrtle/configuration.nix | 63 |
1 files changed, 50 insertions, 13 deletions
diff --git a/hosts/myrtle/configuration.nix b/hosts/myrtle/configuration.nix index db70416..74f4861 100644 --- a/hosts/myrtle/configuration.nix +++ b/hosts/myrtle/configuration.nix | |||
@@ -12,7 +12,7 @@ | |||
12 | boot.kernelPackages = pkgs.linuxPackages_latest; | 12 | boot.kernelPackages = pkgs.linuxPackages_latest; |
13 | boot.blacklistedKernelModules = [ "nouveau" ]; | 13 | boot.blacklistedKernelModules = [ "nouveau" ]; |
14 | boot.kernelParams = [ | 14 | boot.kernelParams = [ |
15 | "module_blacklist=i915" | 15 | "i915.modeset=0" |
16 | # "intel_pstate=disable" | 16 | # "intel_pstate=disable" |
17 | ]; | 17 | ]; |
18 | 18 | ||
@@ -54,18 +54,23 @@ | |||
54 | vim-colors-plain | 54 | vim-colors-plain |
55 | ]; | 55 | ]; |
56 | 56 | ||
57 | environment.systemPackages = with pkgs; [ | 57 | environment = { |
58 | _2bwm | 58 | variables = { |
59 | man-pages | 59 | MOZ_USE_XINPUT2 = "1"; |
60 | man-pages-posix | 60 | }; |
61 | (lib.hiPrio pkgs.bashInteractive_5) | 61 | systemPackages = with pkgs; [ |
62 | _2bwm | ||
63 | man-pages | ||
64 | man-pages-posix | ||
65 | (lib.hiPrio pkgs.bashInteractive_5) | ||
62 | 66 | ||
63 | # turbo | 67 | # turbo |
64 | config.boot.kernelPackages.turbostat | 68 | config.boot.kernelPackages.turbostat |
65 | config.boot.kernelPackages.nvidia_x11 | 69 | config.boot.kernelPackages.nvidia_x11 |
66 | 70 | ||
67 | xdotool | 71 | xdotool |
68 | ]; | 72 | ]; |
73 | }; | ||
69 | 74 | ||
70 | 75 | ||
71 | documentation = { | 76 | documentation = { |
@@ -86,7 +91,9 @@ | |||
86 | }; | 91 | }; |
87 | 92 | ||
88 | sound.enable = true; | 93 | sound.enable = true; |
94 | |||
89 | hardware = { | 95 | hardware = { |
96 | opengl.driSupport = true; | ||
90 | pulseaudio = { | 97 | pulseaudio = { |
91 | enable = true; | 98 | enable = true; |
92 | package = pkgs.pulseaudioFull; | 99 | package = pkgs.pulseaudioFull; |
@@ -96,19 +103,46 @@ | |||
96 | enable = true; | 103 | enable = true; |
97 | powerOnBoot = true; | 104 | powerOnBoot = true; |
98 | }; | 105 | }; |
99 | nvidia.package = config.boot.kernelPackages.nvidiaPackages.latest; | 106 | nvidia = { |
107 | prime = { | ||
108 | offload.enable = true; | ||
109 | intelBusId = "PCI:00:02:0"; | ||
110 | nvidiaBusId = "PCI:01:00:0"; | ||
111 | }; | ||
112 | package = config.boot.kernelPackages.nvidiaPackages.latest; | ||
113 | powerManagement = { | ||
114 | enable = true; | ||
115 | finegrained = true; | ||
116 | }; | ||
117 | }; | ||
100 | }; | 118 | }; |
101 | 119 | ||
120 | powerManagement = { | ||
121 | enable = true; | ||
122 | powertop.enable = true; | ||
123 | }; | ||
102 | 124 | ||
103 | services = { | 125 | services = { |
104 | xserver = { | 126 | xserver = { |
105 | enable = true; | 127 | enable = true; |
106 | layout = "us"; | 128 | layout = "us"; |
107 | videoDrivers = [ "nvidia" ]; | 129 | videoDrivers = [ "nvidia" "intel" ]; |
108 | displayManager.startx.enable = true; | 130 | displayManager.startx.enable = true; |
131 | dpi = 192; | ||
109 | libinput.enable = true; | 132 | libinput.enable = true; |
133 | serverLayoutSection = '' | ||
134 | Screen "Screen-nvidia[0]" | ||
135 | ''; | ||
136 | config = lib.mkAfter '' | ||
137 | Section "Screen" | ||
138 | Identifier "Screen-nvidia[0]" | ||
139 | Device "Device-nvidia[0]" | ||
140 | EndSection | ||
141 | ''; | ||
110 | }; | 142 | }; |
111 | 143 | ||
144 | openssh.enable = true; | ||
145 | |||
112 | asusd = { | 146 | asusd = { |
113 | enable = true; | 147 | enable = true; |
114 | enableUserService = true; | 148 | enableUserService = true; |
@@ -138,6 +172,9 @@ | |||
138 | isNormalUser = true; | 172 | isNormalUser = true; |
139 | home = "/home/np"; | 173 | home = "/home/np"; |
140 | extraGroups = [ "wheel" "users" "tty" "audio" "video" "input" "adbusers" "docker" ]; | 174 | extraGroups = [ "wheel" "users" "tty" "audio" "video" "input" "adbusers" "docker" ]; |
175 | openssh.authorizedKeys.keys = [ | ||
176 | "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCrmh1vEWwKm8gpOk9j3DkZsiJCojpBdxuWU4M8rFeV/U9isRB+3pSJvF3Sncc6Yd+hSDohpzQF/Q5urubjkrGDniAKFjZnUHWZEzJmfQLHLIHXBkHjY8UMYF/WZprcplBKAZ7S9tS0YGa6NOQe2KEFtNG6XtBnrI3lswAHPOlqKJBG47MxfjIi9aUhczlzPxtGC9AfdwaNQYgLoJ91I6jkKuyKjbYt8KDDL+6PJ63TZc18LKKct1rf+ejRJKR9+jHTkEXhltUSQkieOJiEOdVcYWbYBxSoWutrnrksnhi9dLABOvueG6mAORU5g1yrMnX80RbK8DauwG4WI9qIGvHNPpQqP0vjj4mr8YkOUmzyeTW3KlOsQJZ7279WruBYV96/a7YoHKj9fGzV4McvVpvLMYa47hqyCBRK/qz0BSLFEhSNZzqseXCk91qZ0EhROBQEckqlKVip75YWFhqjVrgSPnVYWHxceNMttKmfGgIGXI8Bc8TKRZd+7quJNG7cWIE= np@olive" | ||
177 | ]; | ||
141 | }; | 178 | }; |
142 | 179 | ||
143 | nix = { | 180 | nix = { |