mirror of
https://github.com/NixOS/nixos-hardware.git
synced 2026-11-30 21:13:30 +01:00
Compare commits
83
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1878da65d7 | ||
|
|
d201afb2e7 | ||
|
|
d23a3bc3c6 | ||
|
|
009b764ac9 | ||
|
|
d58f642ddb | ||
|
|
55e9685ec6 | ||
|
|
bbf25ca940 | ||
|
|
9430c63e02 | ||
|
|
76a98e3958 | ||
|
|
9d5dedae84 | ||
|
|
0b2e2fe9b3 | ||
|
|
ab84bd93a3 | ||
|
|
28f2a7454f | ||
|
|
79bc209be8 | ||
|
|
80340dcf86 | ||
|
|
099d38a69e | ||
|
|
71cca26f33 | ||
|
|
8f44cbb48c | ||
|
|
fb12c8270a | ||
|
|
cda8312060 | ||
|
|
a0252d668c | ||
|
|
d098b09500 | ||
|
|
04be27ce49 | ||
|
|
9b49e20140 | ||
|
|
f75203cc31 | ||
|
|
d2483459e8 | ||
|
|
18e9f9753e | ||
|
|
3e2ea8a49d | ||
|
|
08c94a8b62 | ||
|
|
e47365f377 | ||
|
|
ba37846397 | ||
|
|
4f90da509b | ||
|
|
2eccff41ba | ||
|
|
d1f201fc62 | ||
|
|
68cc7a876b | ||
|
|
52047449bf | ||
|
|
c5666d9cd6 | ||
|
|
d85ec4b3c6 | ||
|
|
240f698fc8 | ||
|
|
d9819a6791 | ||
|
|
da7014af5d | ||
|
|
9bdd53f590 | ||
|
|
537286c3c5 | ||
|
|
b8be6f78b0 | ||
|
|
34b64e4e1d | ||
|
|
21fa58535d | ||
|
|
95c8efc0cb | ||
|
|
3009bcb058 | ||
|
|
dfad538f75 | ||
|
|
7659093598 | ||
|
|
c2aa5756c0 | ||
|
|
3a123626d9 | ||
|
|
cbefe8bde7 | ||
|
|
9368027715 | ||
|
|
6209032a7c | ||
|
|
5f052b2663 | ||
|
|
63c0f02ce5 | ||
|
|
8b5ef47338 | ||
|
|
61c79181e7 | ||
|
|
b539957839 | ||
|
|
1f23785afe | ||
|
|
ce98bebf0f | ||
|
|
e7ac747157 | ||
|
|
c3e369baa6 | ||
|
|
cb3173dc5c | ||
|
|
f8d5f4ea3e | ||
|
|
abe22227d7 | ||
|
|
3883dfe5ee | ||
|
|
b31613ae10 | ||
|
|
b678606690 | ||
|
|
91c1069cba | ||
|
|
06c52bbc79 | ||
|
|
8870dcaff6 | ||
|
|
e315f86472 | ||
|
|
d73a04dabf | ||
|
|
4f339f6be2 | ||
|
|
ca30f8501a | ||
|
|
75a920536c | ||
|
|
95a812557b | ||
|
|
4c5c3be74d | ||
|
|
d3b4fe46c8 | ||
|
|
b98df1827a | ||
|
|
4c0d42b582 |
No files matched your search
@@ -5,7 +5,6 @@ dell/xps/15-9560 @Lyndeno
|
||||
lenovo/thinkpad/x230 @makefu @yegortimoshenko
|
||||
lenovo/thinkpad/x250 @Mic92
|
||||
pcengines/apu @yegortimoshenko
|
||||
pine64/pinebook-pro @tomfitzhenry
|
||||
pine64/rockpro64 @tomfitzhenry
|
||||
pine64/star64 @fgaz
|
||||
purism/librem/13v3 @yegortimoshenko
|
||||
|
||||
@@ -91,8 +91,11 @@ See code for all available configurations.
|
||||
| [Apple MacBook Pro 14,1](apple/macbook-pro/14-1) | `<nixos-hardware/apple/macbook-pro/14-1>` |
|
||||
| [Apple MacMini (2010, Intel, Nvidia)](apple/macmini/4) | `<nixos-hardware/apple/macmini/4>` |
|
||||
| [Apple Macs with a T2 Chip](apple/t2) | `<nixos-hardware/apple/t2>` |
|
||||
| [Aoostar R1 N100](aoostar/r1/n100) | `<nixos-hardware/aoostar/r1/n100>` |
|
||||
| [Asus Pro WS X570-ACE](asus/pro-ws-x570-ace) | `<nixos-hardware/asus/pro-ws-x570-ace>` |
|
||||
| [Asus ROG Ally RC71L (2023)](asus/ally/rc71l) | `<nixos-hardware/asus/ally/rc71l>` |
|
||||
| [Asus ROG Flow X13 GV302X\* (2023)](asus/flow/gv302x/amdgpu) | `<nixos-hardware/asus/flow/gv302x/amdgpu>` |
|
||||
| [Asus ROG Flow X13 GV302X\* (2023)](asus/flow/gv302x/nvidia) | `<nixos-hardware/asus/flow/gv302x/nvidia>` |
|
||||
| [Asus ROG Strix G513IM](asus/rog-strix/g513im) | `<nixos-hardware/asus/rog-strix/g513im>` |
|
||||
| [Asus ROG Strix G713IE](asus/rog-strix/g713ie) | `<nixos-hardware/asus/rog-strix/g713ie>` |
|
||||
| [Asus ROG Strix G733QS](asus/rog-strix/g733qs) | `<nixos-hardware/asus/rog-strix/g733qs>` |
|
||||
@@ -107,6 +110,7 @@ See code for all available configurations.
|
||||
| [Asus ROG Zephyrus M16 GU603H](asus/zephyrus/gu603h) | `<nixos-hardware/asus/zephyrus/gu603h>` |
|
||||
| [Asus TUF FX504GD](asus/fx504gd) | `<nixos-hardware/asus/fx504gd>` |
|
||||
| [Asus TUF FX506HM](asus/fx506hm) | `<nixos-hardware/asus/fx506hm>` |
|
||||
| [Asus TUF FA506IC](asus/fa506ic) | `<nixos-hardware/asus/fa506ic>` |
|
||||
| [Asus TUF FA507RM](asus/fa507rm) | `<nixos-hardware/asus/fa507rm>` |
|
||||
| [Asus TUF FA507NV](asus/fa507nv) | `<nixos-hardware/asus/fa507nv>` |
|
||||
| [Asus Zenbook Flip S13 UX371](asus/zenbook/ux371/) | `<nixos-hardware/asus/zenbook/ux371>` |
|
||||
@@ -115,19 +119,25 @@ See code for all available configurations.
|
||||
| [Chuwi MiniBook X](chuwi/minibook-x) | `<nixos-hardware/chuwi/minibook-x>` |
|
||||
| [Deciso DEC series](deciso/dec) | `<nixos-hardware/deciso/dec>` |
|
||||
| [Dell G3 3779](dell/g3/3779) | `<nixos-hardware/dell/g3/3779>` |
|
||||
| [Dell Inspiron 14 5420](dell/inspiron/14-5420) | `<nixos-hardawre/dell/inspiron/14-5420>` |
|
||||
| [Dell G3 3579](dell/g3/3579) | `<nixos-hardware/dell/g3/3579>` |
|
||||
| [Dell Inspiron 3442](dell/inspiron/3442) | `<nixos-hardware/dell/inspiron/3442>` |
|
||||
| [Dell Inspiron 14 5420](dell/inspiron/14-5420) | `<nixos-hardware/dell/inspiron/14-5420>` |
|
||||
| [Dell Inspiron 5509](dell/inspiron/5509) | `<nixos-hardware/dell/inspiron/5509>` |
|
||||
| [Dell Inspiron 5515](dell/inspiron/5515) | `<nixos-hardware/dell/inspiron/5515>` |
|
||||
| [Dell Inspiron 7405](dell/inspiron/7405) | `<nixos-hardware/dell/inspiron/7405>` |
|
||||
| [Dell Inspiron 7460](dell/inspiron/7460) | `<nixos-hardware/dell/inspiron/7460>` |
|
||||
| [Dell Inspiron 7559](dell/inspiron/7559) | `<nixos-hardware/dell/inspiron/7559>` |
|
||||
| [Dell Latitude 3340](dell/latitude/3340) | `<nixos-hardware/dell/latitude/3340>` |
|
||||
| [Dell Latitude 3480](dell/latitude/3480) | `<nixos-hardware/dell/latitude/3480>` |
|
||||
| [Dell Latitude 5490](dell/latitude/5490) | `<nixos-hardware/dell/latitude/5490>` |
|
||||
| [Dell Latitude 5520](dell/latitude/5520) | `<nixos-hardware/dell/latitude/5520>` |
|
||||
| [Dell Latitude 7280](dell/latitude/7280) | `<nixos-hardware/dell/latitude/7280>` |
|
||||
| [Dell Latitude 7390](dell/latitude/7390) | `<nixos-hardware/dell/latitude/7390>` |
|
||||
| [Dell Latitude 7420](dell/latitude/7420) | `<nixos-hardware/dell/latitude/7420>` |
|
||||
| [Dell Latitude 7430](dell/latitude/7430) | `<nixos-hardware/dell/latitude/7430>` |
|
||||
| [Dell Latitude 7490](dell/latitude/7490) | `<nixos-hardware/dell/latitude/7490>` |
|
||||
| [Dell Latitude 9430](dell/latitude/9430) | `<nixos-hardware/dell/latitude/9430>` |
|
||||
| [Dell Latitude E7240](dell/latitude/e7240) | `<nixos-hardware/dell/latitude/e7240>` |
|
||||
| [Dell Optiplex 3050](dell/optiplex/3050) | `<nixos-hardware/dell/optiplex/3050>` |
|
||||
| [Dell Poweredge R7515](dell/poweredge/r7515) | `<nixos-hardware/dell/poweredge/r7515>` |
|
||||
| [Dell Precision 3541](dell/precision/3541) | `<nixos-hardware/dell/precision/3541>` |
|
||||
@@ -152,6 +162,8 @@ See code for all available configurations.
|
||||
| [Dell XPS 15 9510](dell/xps/15-9510) | `<nixos-hardware/dell/xps/15-9510>` |
|
||||
| [Dell XPS 15 9520, nvidia](dell/xps/15-9520/nvidia) | `<nixos-hardware/dell/xps/15-9520/nvidia>` |
|
||||
| [Dell XPS 15 9520](dell/xps/15-9520) | `<nixos-hardware/dell/xps/15-9520>` |
|
||||
| [Dell XPS 15 9530, nvidia](dell/xps/15-9520/nvidia) | `<nixos-hardware/dell/xps/15-9530/nvidia>` |
|
||||
| [Dell XPS 15 9420](dell/xps/15-9520) | `<nixos-hardware/dell/xps/15-9530>` |
|
||||
| [Dell XPS 15 9550, nvidia](dell/xps/15-9550/nvidia) | `<nixos-hardware/dell/xps/15-9550/nvidia>` |
|
||||
| [Dell XPS 15 9550](dell/xps/15-9550) | `<nixos-hardware/dell/xps/15-9550>` |
|
||||
| [Dell XPS 15 9560, intel only](dell/xps/15-9560/intel) | `<nixos-hardware/dell/xps/15-9560/intel>` |
|
||||
@@ -163,7 +175,6 @@ See code for all available configurations.
|
||||
| [Dell XPS 17 9700, intel](dell/xps/17-9700/intel) | `<nixos-hardware/dell/xps/17-9700/intel` |
|
||||
| [Dell XPS 17 9700, nvidia](dell/xps/17-9700/nvidia) | `<nixos-hardware/dell/xps/17-9700/nvidia>` |
|
||||
| [Dell XPS 17 9710, intel only](dell/xps/17-9710/intel) | `<nixos-hardware/dell/xps/17-9710/intel>` |
|
||||
| [Dell XPS E7240](dell/e7240) | `<nixos-hardware/dell/e7240>` |
|
||||
| [Framework 11th Gen Intel Core](framework/13-inch/11th-gen-intel) | `<nixos-hardware/framework/13-inch/11th-gen-intel>` |
|
||||
| [Framework 12th Gen Intel Core](framework/13-inch/12th-gen-intel) | `<nixos-hardware/framework/13-inch/12th-gen-intel>` |
|
||||
| [Framework 13th Gen Intel Core](framework/13-inch/13th-gen-intel) | `<nixos-hardware/framework/13-inch/13th-gen-intel>` |
|
||||
@@ -174,9 +185,11 @@ See code for all available configurations.
|
||||
| [FriendlyARM NanoPi R5s](friendlyarm/nanopi-r5s) | `<nixos-hardware/friendlyarm/nanopi-r5s>` |
|
||||
| [Focus M2 Gen 1](focus/m2/gen1) | `<nixos-hardware/focus/m2/gen1>` |
|
||||
| [Gigabyte B550](gigabyte/b550) | `<nixos-hardware/gigabyte/b550>` |
|
||||
| [Gigabyte B650](gigabyte/b650) | `<nixos-hardware/gigabyte/b650>` |
|
||||
| [GPD MicroPC](gpd/micropc) | `<nixos-hardware/gpd/micropc>` |
|
||||
| [GPD P2 Max](gpd/p2-max) | `<nixos-hardware/gpd/p2-max>` |
|
||||
| [GPD Pocket 3](gpd/pocket-3) | `<nixos-hardware/gpd/pocket-3>` |
|
||||
| [GPD Pocket 4](gpd/pocket-4) | `<nixos-hardware/gpd/pocket-4>` |
|
||||
| [GPD WIN 2](gpd/win-2) | `<nixos-hardware/gpd/win-2>` |
|
||||
| [GPD WIN Max 2 2023](gpd/win-max-2/2023) | `<nixos-hardware/gpd/win-max-2/2023>` |
|
||||
| [GPD WIN Mini 2024](gpd/win-mini/2024) | `<nixos-hardware/gpd/win-mini/2024>` |
|
||||
@@ -186,11 +199,13 @@ See code for all available configurations.
|
||||
| [HP Elitebook 845g7](hp/elitebook/845/g7) | `<nixos-hardware/hp/elitebook/845/g7>` |
|
||||
| [HP Elitebook 845g8](hp/elitebook/845/g8) | `<nixos-hardware/hp/elitebook/845/g8>` |
|
||||
| [HP Elitebook 845g9](hp/elitebook/845/g9) | `<nixos-hardware/hp/elitebook/845/g9>` |
|
||||
| [HP Notebook 14-df0023](hp/notebook/14-df0023) | `<nixos-hardware/hp/notebook/14-df0023>` |
|
||||
| [HP Laptop 14s-dq2024nf](hp/laptop/14s-dq2024nf) | `<nixos-hardware/hp/laptop/14s-dq2024nf>` |
|
||||
| [HP Notebook 14-df0023](hp/notebook/14-df0023) | `<nixos-hardware/hp/notebook/14-df0023>` |
|
||||
| [HP Probook 440G5](hp/probook/440g5) | `<nixos-hardware/hp/probook/440g5>` |
|
||||
| [Huawei Matebook X Pro (2020)](huawei/machc-wa) | `<nixos-hardware/huawei/machc-wa>` |
|
||||
| [i.MX8QuadMax Multisensory Enablement Kit](nxp/imx8qm-mek/) | `<nixos-hardware/nxp/imx8qm-mek>` |
|
||||
| [Intel NUC 8i7BEH](intel/nuc/8i7beh/) | `<nixos-hardware/intel/nuc/8i7beh>` |
|
||||
| [Lenovo IdeaCentre K330](lenovo/ideacentre/k330) | `<nixos-hardware/lenovo/ideacentre/k330>` |
|
||||
| [Lenovo IdeaPad 3 15alc6](lenovo/ideapad/15alc6) | `<nixos-hardware/lenovo/ideapad/15alc6>` |
|
||||
| [Lenovo IdeaPad Gaming 3 15arh05](lenovo/ideapad/15arh05) | `<nixos-hardware/lenovo/ideapad/15arh05>` |
|
||||
| [Lenovo IdeaPad Gaming 3 15ach6](lenovo/ideapad/15ach6) | `<nixos-hardware/lenovo/ideapad/15ach6>` |
|
||||
@@ -230,6 +245,7 @@ See code for all available configurations.
|
||||
| [Lenovo ThinkPad P14s AMD Gen 4](lenovo/thinkpad/p14s/amd/gen4) | `<nixos-hardware/lenovo/thinkpad/p14s/amd/gen4>` |
|
||||
| [Lenovo ThinkPad P14s Intel Gen 3](lenovo/thinkpad/p14s/intel/gen3) | `<nixos-hardware/lenovo/thinkpad/p14s/intel/gen3>` |
|
||||
| [Lenovo ThinkPad P16s AMD Gen 1](lenovo/thinkpad/p16s/amd/gen1) | `<nixos-hardware/lenovo/thinkpad/p16s/amd/gen1>` |
|
||||
| [Lenovo ThinkPad P16s AMD Gen 2](lenovo/thinkpad/p16s/amd/gen2) | `<nixos-hardware/lenovo/thinkpad/p16s/amd/gen2>` |
|
||||
| [Lenovo ThinkPad P1](lenovo/thinkpad/p1) | `<nixos-hardware/lenovo/thinkpad/p1>` |
|
||||
| [Lenovo ThinkPad P50](lenovo/thinkpad/p50) | `<nixos-hardware/lenovo/thinkpad/p50>` |
|
||||
| [Lenovo ThinkPad P51](lenovo/thinkpad/p51) | `<nixos-hardware/lenovo/thinkpad/p51>` |
|
||||
@@ -257,6 +273,7 @@ See code for all available configurations.
|
||||
| [Lenovo ThinkPad T480](lenovo/thinkpad/t480) | `<nixos-hardware/lenovo/thinkpad/t480>` |
|
||||
| [Lenovo ThinkPad T480s](lenovo/thinkpad/t480s) | `<nixos-hardware/lenovo/thinkpad/t480s>` |
|
||||
| [Lenovo ThinkPad T490](lenovo/thinkpad/t490) | `<nixos-hardware/lenovo/thinkpad/t490>` |
|
||||
| [Lenovo ThinkPad T490s](lenovo/thinkpad/t490s) | `<nixos-hardware/lenovo/thinkpad/t490s>` |
|
||||
| [Lenovo ThinkPad T495](lenovo/thinkpad/t495) | `<nixos-hardware/lenovo/thinkpad/t495>` |
|
||||
| [Lenovo ThinkPad T520](lenovo/thinkpad/t520) | `<nixos-hardware/lenovo/thinkpad/t520>` |
|
||||
| [Lenovo ThinkPad T550](lenovo/thinkpad/t550) | `<nixos-hardware/lenovo/thinkpad/t550>` |
|
||||
@@ -293,8 +310,8 @@ See code for all available configurations.
|
||||
| [LENOVO Yoga 6 13ALC6 82ND](lenovo/yoga/6/13ALC6) | `<nixos-hardware/lenovo/yoga/6/13ALC6>` |
|
||||
| [LENOVO Yoga Slim 7 Pro-X 14ARH7 82ND](lenovo/yoga/7/14ARH7/amdgpu) | `<nixos-hardware/lenovo/yoga/7/14ARH7/amdgpu>` |
|
||||
| [LENOVO Yoga Slim 7 Pro-X 14ARH7 82ND](lenovo/yoga/7/14ARH7/nvidia) | `<nixos-hardware/lenovo/yoga/7/14ARH7/nvidia>` |
|
||||
| [Lenovo Yoga Slim 7i Pro X 14IAH7 (Integrated)](lenovo/yoga/7/14IAH7/integrated) |`<nixos-hardware/lenovo/yoga/7/14IAH7/integrated>` |
|
||||
| [Lenovo Yoga Slim 7i Pro X 14IAH7 (Hybrid)](lenovo/yoga/7/14IAH7/hybrid) |`<nixos-hardware/lenovo/yoga/7/14IAH7/hybrid>` |
|
||||
| [Lenovo Yoga Slim 7i Pro X 14IAH7 (Integrated)](lenovo/yoga/7/14IAH7/integrated) | `<nixos-hardware/lenovo/yoga/7/14IAH7/integrated>` |
|
||||
| [Lenovo Yoga Slim 7i Pro X 14IAH7 (Hybrid)](lenovo/yoga/7/14IAH7/hybrid) | `<nixos-hardware/lenovo/yoga/7/14IAH7/hybrid>` |
|
||||
| [LENOVO Yoga 7 Slim Gen8](lenovo/yoga/7/slim/gen8) | `<nixos-hardware/lenovo/yoga/7/slim/gen8>` |
|
||||
| [MSI B550-A PRO](msi/b550-a-pro) | `<nixos-hardware/msi/b550-a-pro>` |
|
||||
| [MSI B350 TOMAHAWK](msi/b350-tomahawk) | `<nixos-hardware/msi/b350-tomahawk>` |
|
||||
@@ -314,7 +331,9 @@ See code for all available configurations.
|
||||
| [NXP iMX8 MQuad Evaluation Kit](nxp/imx8mq-evk) | `<nixos-hardware/nxp/imx8mq-evk>` |
|
||||
| [Hardkernel Odroid HC4](hardkernel/odroid-hc4/default.nix) | `<nixos-hardware/hardkernel/odroid-hc4>` |
|
||||
| [Hardkernel Odroid H3](hardkernel/odroid-h3/default.nix) | `<nixos-hardware/hardkernel/odroid-h3>` |
|
||||
| [Hardkernel Odroid H4](hardkernel/odroid-h4/default.nix) | `<nixos-hardware/hardkernel/odroid-h4>` |
|
||||
| [Omen 14-fb0798ng](omen/14-fb0798ng) | `<nixos-hardware/omen/14-fb0798ng>` |
|
||||
| [Omen 15-ce002ns](omen/15-ce002ns) | `<nixos-hardware/omen/15-ce002ns>` |
|
||||
| [Omen 15-en0010ca](omen/15-en0010ca) | `<nixos-hardware/omen/15-en0010ca>` |
|
||||
| [Omen 16-n0005ne](omen/16-n0005ne) | `<nixos-hardware/omen/16-n0005ne>` |
|
||||
| [Omen 16-n0280nd](/omen/16-n0280nd) | `<nixos-hardware/omen/16-n0280nd>` |
|
||||
@@ -330,11 +349,16 @@ See code for all available configurations.
|
||||
| [Purism Librem 13v3](purism/librem/13v3) | `<nixos-hardware/purism/librem/13v3>` |
|
||||
| [Purism Librem 15v3](purism/librem/13v3) | `<nixos-hardware/purism/librem/15v3>` |
|
||||
| [Purism Librem 5r4](purism/librem/5r4) | `<nixos-hardware/purism/librem/5r4>` |
|
||||
| [Radxa ROCK 4C+](radxa/rock-4c-plus) | `<nixos-hardware/radxa/rock-4c-plus>` |
|
||||
| [Radxa ROCK 5 Model B](radxa/rock-5b) | `<nixos-hardware/radxa/rock-5b>` |
|
||||
| [Radxa ROCK Pi 4](radxa/rock-pi-4) | `<nixos-hardware/radxa/rock-pi-4>` |
|
||||
| [Radxa ROCK Pi E](radxa/rock-pi-e) | `<nixos-hardware/radxa/rock-pi-e>` |
|
||||
| [Raspberry Pi 2](raspberry-pi/2) | `<nixos-hardware/raspberry-pi/2>` |
|
||||
| [Raspberry Pi 3](raspberry-pi/3) | `<nixos-hardware/raspberry-pi/3>` |
|
||||
| [Raspberry Pi 4](raspberry-pi/4) | `<nixos-hardware/raspberry-pi/4>` |
|
||||
| [Raspberry Pi 5](raspberry-pi/5) | `<nixos-hardware/raspberry-pi/5>` |
|
||||
| [Samsung Series 9 NP900X3C](samsung/np900x3c) | `<nixos-hardware/samsung/np900x3c>` |
|
||||
| [Slimbook Hero RPL-RTX](slimbook/hero/rpl-rtx) | `<nixos-hardware/slimbook/hero/rpl-rtx>` |
|
||||
| [StarFive VisionFive v1](starfive/visionfive/v1) | `<nixos-hardware/starfive/visionfive/v1>` |
|
||||
| [StarFive VisionFive 2](starfive/visionfive/v2) | `<nixos-hardware/starfive/visionfive/v2>` |
|
||||
| [StarLabs StarLite 5 (I5)](starlabs/starlite/i5) | `<nixos-hardware/starlabs/starlite/i5>` |
|
||||
@@ -352,3 +376,4 @@ See code for all available configurations.
|
||||
| [TUXEDO InfinityBook Pro 14 - Gen7](tuxedo/infinitybook/pro14/gen7) | `<nixos-hardware/tuxedo/infinitybook/pro14/gen7>` |
|
||||
| [TUXEDO Pulse 14 - Gen3](tuxedo/pulse/14/gen3) | `<nixos-hardware/tuxedo/pulse/14/gen3>` |
|
||||
| [TUXEDO Pulse 15 - Gen2](tuxedo/pulse/15/gen2) | `<nixos-hardware/tuxedo/pulse/15/gen2>` |
|
||||
| [Xiaomi Redmibook 16 Pro 2024](xiaomi/redmibook/16-pro-2024) | `<nixos-hardware/xiaomi/redmibook/16-pro-2024>` |
|
||||
@@ -0,0 +1,12 @@
|
||||
{
|
||||
imports = [
|
||||
../../../common/cpu/intel/alder-lake
|
||||
];
|
||||
|
||||
# lopter@(2025-02-06): according to sensors-detect this comes with an ITE
|
||||
# IT8613E super io chip, which is not officialy supported yet. See also:
|
||||
#
|
||||
# - unofficial driver: https://github.com/frankcrawford/it87
|
||||
# - reddit thread on with useful information to configure pwm from the bios:
|
||||
# https://www.reddit.com/r/MiniPCs/comments/1bnkg1u/aoostar_r1r7_question_does_the_fan_header_support/
|
||||
}
|
||||
+2
-26
@@ -8,29 +8,5 @@ Following [this guide](https://wiki.t2linux.org/distributions/nixos/installation
|
||||
|
||||
You can consult the [wiki](https://wiki.t2linux.org/) for information specific to T2 Macs.
|
||||
|
||||
## Unlocking Internal iGPU
|
||||
|
||||
The `apple-set-os-loader-installer` module serves as an installer for the [`apple-set-os-loader`](https://github.com/Redecorating/apple_set_os-loader). This tool is designed to unlock the internal integrated GPU (iGPU) on certain MacBooks. See https://wiki.t2linux.org/guides/hybrid-graphics/ for more details.
|
||||
|
||||
### What it Does:
|
||||
|
||||
Upon activation, this module performs the following:
|
||||
|
||||
- Renames the existing `BOOTX64.EFI` file to `bootx64_original.efi`.
|
||||
- Installs the `apple-set-os-loader` hook in its place as `bootx64.efi`.
|
||||
- Before the system boots the hook unlocks the iGPU and subsequently calls the original `bootx64_original.efi`.
|
||||
- Enables the iGPU by default.
|
||||
|
||||
### How to Implement:
|
||||
|
||||
1. Add this into your `configuration.nix`:
|
||||
```
|
||||
hardware.apple-t2.enableAppleSetOsLoader = true;
|
||||
```
|
||||
|
||||
2. **Rebuild your system**:
|
||||
```
|
||||
sudo nixos-rebuild switch
|
||||
```
|
||||
|
||||
> **Note**: Always ensure compatibility and make backups of your data before making any system changes.
|
||||
> [!warning]
|
||||
> Always ensure compatibility and make backups of your data before making any system changes.
|
||||
+47
-55
@@ -1,6 +1,12 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
inherit (lib) types;
|
||||
audioFiles = pkgs.fetchFromGitHub {
|
||||
owner = "kekrby";
|
||||
repo = "t2-better-audio";
|
||||
@@ -8,69 +14,73 @@ let
|
||||
hash = "sha256-x7K0qa++P1e1vuCGxnsFxL1d9+nwMtZUJ6Kd9e27TFs=";
|
||||
};
|
||||
|
||||
audioFilesUdevRules = pkgs.runCommand "audio-files-udev-rules" {} ''
|
||||
audioFilesUdevRules = pkgs.runCommand "audio-files-udev-rules" { } ''
|
||||
mkdir -p $out/lib/udev/rules.d
|
||||
cp ${audioFiles}/files/*.rules $out/lib/udev/rules.d
|
||||
substituteInPlace $out/lib/udev/rules.d/*.rules --replace "/usr/bin/sed" "${pkgs.gnused}/bin/sed"
|
||||
'';
|
||||
|
||||
overrideAudioFiles = package: pluginsPath:
|
||||
package.overrideAttrs (new: old: {
|
||||
preConfigurePhases = old.preConfigurePhases or [ ] ++ [ "postPatchPhase" ];
|
||||
postPatchPhase = ''
|
||||
cp -r ${audioFiles}/files/{profile-sets,paths} ${pluginsPath}/alsa/mixer/
|
||||
'';
|
||||
});
|
||||
overrideAudioFiles =
|
||||
package: pluginsPath:
|
||||
package.overrideAttrs (
|
||||
new: old: {
|
||||
preConfigurePhases = old.preConfigurePhases or [ ] ++ [ "postPatchPhase" ];
|
||||
postPatchPhase = ''
|
||||
cp -r ${audioFiles}/files/{profile-sets,paths} ${pluginsPath}/alsa/mixer/
|
||||
'';
|
||||
}
|
||||
);
|
||||
|
||||
pipewirePackage = overrideAudioFiles pkgs.pipewire "spa/plugins/";
|
||||
|
||||
apple-set-os-loader-installer = pkgs.stdenv.mkDerivation {
|
||||
name = "apple-set-os-loader-installer-1.0";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "Redecorating";
|
||||
repo = "apple_set_os-loader";
|
||||
rev = "r33.9856dc4";
|
||||
sha256 = "hvwqfoF989PfDRrwU0BMi69nFjPeOmSaD6vR6jIRK2Y=";
|
||||
};
|
||||
buildInputs = [ pkgs.gnu-efi ];
|
||||
buildPhase = ''
|
||||
substituteInPlace Makefile --replace "/usr" '$(GNU_EFI)'
|
||||
export GNU_EFI=${pkgs.gnu-efi}
|
||||
make
|
||||
'';
|
||||
installPhase = ''
|
||||
install -D bootx64_silent.efi $out/bootx64.efi
|
||||
'';
|
||||
};
|
||||
|
||||
t2Cfg = config.hardware.apple-t2;
|
||||
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
(lib.mkRemovedOptionModule ["hardware" "apple-t2" "enableTinyDfr"] ''
|
||||
(lib.mkRemovedOptionModule [ "hardware" "apple-t2" "enableTinyDfr" ] ''
|
||||
The hardware.apple-t2.enableTinyDfr option was deprecated and removed since upstream Nixpkgs now has an identical module.
|
||||
Please migrate to hardware.apple.touchBar.
|
||||
'')
|
||||
|
||||
(lib.mkRemovedOptionModule [ "hardware" "apple-t2" "enableAppleSetOsLoader" ] ''
|
||||
The hardware.apple-t2.enableAppleSetOsLoader option was removed as the apple_set_os functionality was integrated into the kernel.
|
||||
Please uninstall the loader by replacing /esp/EFI/BOOTX64.EFI with /esp/EFI/BOOTX64_original.EFI, where esp is the EFI partition mount point.
|
||||
|
||||
If you have a device with an AMD dGPU and would like to keep using the iGPU, please set hardware.apple-t2.enableIGPU to true.
|
||||
'')
|
||||
];
|
||||
options.hardware.apple-t2 = {
|
||||
enableAppleSetOsLoader = lib.mkOption {
|
||||
default = false;
|
||||
type = lib.types.bool;
|
||||
description = "Whether to enable the appleSetOsLoader activation script.";
|
||||
enableIGPU = lib.mkEnableOption "the usage of the iGPU on specific Apple devices with an AMD dGPU";
|
||||
kernelChannel = lib.mkOption {
|
||||
type = types.enum [
|
||||
"stable"
|
||||
"latest"
|
||||
];
|
||||
default = "stable";
|
||||
example = "latest";
|
||||
description = "The kernel release stream to use.";
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkMerge [
|
||||
{
|
||||
# For keyboard and touchbar
|
||||
boot.kernelPackages = pkgs.linuxPackagesFor (pkgs.callPackage ./pkgs/linux-t2.nix { });
|
||||
# Specialized kernel for keyboard, touchpad, touchbar and audio.
|
||||
boot.kernelPackages = pkgs.linuxPackagesFor (
|
||||
pkgs.callPackage (
|
||||
if t2Cfg.kernelChannel == "stable" then ./pkgs/linux-t2 else ./pkgs/linux-t2/latest.nix
|
||||
) { }
|
||||
);
|
||||
boot.initrd.kernelModules = [ "apple-bce" ];
|
||||
|
||||
services.udev.packages = [ audioFilesUdevRules ];
|
||||
|
||||
# For audio
|
||||
boot.kernelParams = [ "pcie_ports=compat" "intel_iommu=on" "iommu=pt" ];
|
||||
boot.kernelParams = [
|
||||
"pcie_ports=compat"
|
||||
"intel_iommu=on"
|
||||
"iommu=pt"
|
||||
];
|
||||
|
||||
hardware.pulseaudio.package = overrideAudioFiles pkgs.pulseaudio "src/modules/";
|
||||
|
||||
@@ -82,25 +92,7 @@ in
|
||||
# Make sure post-resume.service exists
|
||||
powerManagement.enable = true;
|
||||
}
|
||||
(lib.mkIf t2Cfg.enableAppleSetOsLoader {
|
||||
# Activation script to install apple-set-os-loader in order to unlock the iGPU
|
||||
system.activationScripts.appleSetOsLoader = ''
|
||||
if [[ -e /boot/efi/efi/boot/bootx64_original.efi ]]; then
|
||||
true # It's already installed, no action required
|
||||
elif [[ -e /boot/efi/efi/boot/bootx64.efi ]]; then
|
||||
# Copy the new bootloader to a temporary location
|
||||
cp ${apple-set-os-loader-installer}/bootx64.efi /boot/efi/efi/boot/bootx64_temp.efi
|
||||
|
||||
# Rename the original bootloader
|
||||
mv /boot/efi/efi/boot/bootx64.efi /boot/efi/efi/boot/bootx64_original.efi
|
||||
|
||||
# Move the new bootloader to the final destination
|
||||
mv /boot/efi/efi/boot/bootx64_temp.efi /boot/efi/efi/boot/bootx64.efi
|
||||
else
|
||||
echo "Error: /boot/efi/efi/boot/bootx64.efi is missing" >&2
|
||||
fi
|
||||
'';
|
||||
|
||||
(lib.mkIf t2Cfg.enableIGPU {
|
||||
# Enable the iGPU by default if present
|
||||
environment.etc."modprobe.d/apple-gmux.conf".text = ''
|
||||
options apple-gmux force_igd=y
|
||||
|
||||
@@ -1,56 +0,0 @@
|
||||
{ lib, buildLinux, fetchFromGitHub, fetchzip, runCommand
|
||||
, ... } @ args:
|
||||
|
||||
let
|
||||
version = "6.12.4";
|
||||
majorVersion = lib.elemAt (lib.take 1 (lib.splitVersion version)) 0;
|
||||
|
||||
patchRepo = fetchFromGitHub {
|
||||
owner = "t2linux";
|
||||
repo = "linux-t2-patches";
|
||||
rev = "539eea1f9127f1623794ee8c7ccc37e8b00f60a3";
|
||||
hash = "sha256-pFeNOLTqnEupyEZDk+fX/5GFpobvN+L7Wv2K6V5Xx9g=";
|
||||
};
|
||||
|
||||
kernel = fetchzip {
|
||||
url = "mirror://kernel/linux/kernel/v${majorVersion}.x/linux-${version}.tar.xz";
|
||||
hash = "sha256-SiQzaqraT/5s6Mown8/DeOWU7VR3IG0ojvkqThO09+0=";
|
||||
};
|
||||
in
|
||||
buildLinux (args // {
|
||||
inherit version;
|
||||
|
||||
pname = "linux-t2";
|
||||
# Snippet from nixpkgs
|
||||
modDirVersion = "${lib.concatStringsSep "." (lib.take 3 (lib.splitVersion "${version}.0"))}";
|
||||
|
||||
src = runCommand "patched-source" {} ''
|
||||
cp -r ${kernel} $out
|
||||
chmod -R u+w $out
|
||||
cd $out
|
||||
while read -r patch; do
|
||||
echo "Applying patch $patch";
|
||||
patch -p1 < $patch;
|
||||
done < <(find ${patchRepo} -type f -name "*.patch" | sort)
|
||||
'';
|
||||
|
||||
structuredExtraConfig = with lib.kernel; {
|
||||
APPLE_BCE = module;
|
||||
APPLE_GMUX = module;
|
||||
APFS_FS = module;
|
||||
BRCMFMAC = module;
|
||||
BT_BCM = module;
|
||||
BT_HCIBCM4377 = module;
|
||||
BT_HCIUART_BCM = yes;
|
||||
BT_HCIUART = module;
|
||||
HID_APPLETB_BL = module;
|
||||
HID_APPLETB_KBD = module;
|
||||
HID_APPLE = module;
|
||||
DRM_APPLETBDRM = module;
|
||||
HID_SENSOR_ALS = module;
|
||||
SND_PCM = module;
|
||||
STAGING = yes;
|
||||
};
|
||||
|
||||
kernelPatches = [];
|
||||
} // (args.argsOverride or {}))
|
||||
@@ -0,0 +1,6 @@
|
||||
{ callPackage, linux_6_12, ... }@args:
|
||||
|
||||
callPackage ./generic.nix args {
|
||||
kernel = linux_6_12;
|
||||
patchesFile = ./stable.json;
|
||||
}
|
||||
@@ -0,0 +1,59 @@
|
||||
{
|
||||
lib,
|
||||
fetchurl, # fetchpatch does unnecessary normalization
|
||||
...
|
||||
}@args:
|
||||
|
||||
{
|
||||
kernel,
|
||||
patchesFile,
|
||||
}:
|
||||
let
|
||||
inherit (builtins) readFile fromJSON;
|
||||
|
||||
patchset = fromJSON (readFile patchesFile);
|
||||
t2-patches = map (
|
||||
{ name, hash }:
|
||||
{
|
||||
inherit name;
|
||||
patch = fetchurl {
|
||||
inherit name hash;
|
||||
url = patchset.base_url + name;
|
||||
};
|
||||
}
|
||||
) patchset.patches;
|
||||
in
|
||||
kernel.override (
|
||||
args
|
||||
// {
|
||||
pname = "linux-t2";
|
||||
|
||||
structuredExtraConfig = with lib.kernel; {
|
||||
APPLE_BCE = module;
|
||||
APPLE_GMUX = module;
|
||||
APFS_FS = module;
|
||||
BRCMFMAC = module;
|
||||
BT_BCM = module;
|
||||
BT_HCIBCM4377 = module;
|
||||
BT_HCIUART_BCM = yes;
|
||||
BT_HCIUART = module;
|
||||
HID_APPLETB_BL = module;
|
||||
HID_APPLETB_KBD = module;
|
||||
HID_APPLE = module;
|
||||
DRM_APPLETBDRM = module;
|
||||
HID_SENSOR_ALS = module;
|
||||
SND_PCM = module;
|
||||
STAGING = yes;
|
||||
};
|
||||
|
||||
kernelPatches = t2-patches ++ (args.kernelPatches or [ ]);
|
||||
|
||||
argsOverride.extraMeta = {
|
||||
description = "The Linux kernel (with patches from the T2 Linux project)";
|
||||
|
||||
# take responsibility for the downstream kernel
|
||||
maintainers = with lib.maintainers; [ soopyc ];
|
||||
};
|
||||
}
|
||||
// (args.argsOverride or { })
|
||||
)
|
||||
@@ -0,0 +1,113 @@
|
||||
{
|
||||
"base_url": "https://raw.githubusercontent.com/t2linux/linux-t2-patches/73bbcb413e8c9294c27ec9b53f84d8b19ecd3f05/",
|
||||
"patches": [
|
||||
{
|
||||
"name": "1001-Add-apple-bce-driver.patch",
|
||||
"hash": "sha256-e3RPvWPj2QASGOS4kieO8YFekrXsBCJtfF82OPlOn2E="
|
||||
},
|
||||
{
|
||||
"name": "1002-Put-apple-bce-in-drivers-staging.patch",
|
||||
"hash": "sha256-wkveNo1qwAwXWDGTFed4ZDbuBnJbwKgWLmTHK9qq0oM="
|
||||
},
|
||||
{
|
||||
"name": "1005-HID-hid-appletb-bl-add-driver-for-the-backlight-of-A.patch",
|
||||
"hash": "sha256-kEscS1FAyDxLZPOPInYTXFEf4fouBEa4zGctX14hSu8="
|
||||
},
|
||||
{
|
||||
"name": "1006-HID-hid-appletb-kbd-add-driver-for-the-keyboard-mode.patch",
|
||||
"hash": "sha256-eVEuvnoRItaDjwWu41nn9bTkgHgY+1SL/hFAvUR2IlY="
|
||||
},
|
||||
{
|
||||
"name": "1007-HID-multitouch-support-getting-the-contact-ID-from.patch",
|
||||
"hash": "sha256-A4tExJafroVAv/Hbdt7farJM6RYl/DU5KwSbzqcdEVY="
|
||||
},
|
||||
{
|
||||
"name": "1008-HID-multitouch-support-getting-the-tip-state-from-HI.patch",
|
||||
"hash": "sha256-GwK+d87p3UMy66037dzq6/Zearj8gnRHhqSdZczRadY="
|
||||
},
|
||||
{
|
||||
"name": "1009-HID-multitouch-take-cls-maxcontacts-into-account-for.patch",
|
||||
"hash": "sha256-fywzHnCQ657UFye1ckiufral3pBwBGtKdxWqWqaFHM0="
|
||||
},
|
||||
{
|
||||
"name": "1010-HID-multitouch-allow-specifying-if-a-device-is-direc.patch",
|
||||
"hash": "sha256-87SOnLgeG60Svu2Z9QUyP9P6cZ1Gznt6ZYLFImfx+vY="
|
||||
},
|
||||
{
|
||||
"name": "1011-HID-multitouch-add-device-ID-for-Apple-Touch-Bars.patch",
|
||||
"hash": "sha256-TJjXAlQ4WEROnq/xd6/4JHTuEJjqT7dLLcE4etKdzc0="
|
||||
},
|
||||
{
|
||||
"name": "1012-lib-vsprintf-Add-support-for-generic-FOURCCs-by-exte.patch",
|
||||
"hash": "sha256-cMl4WJcT/nM/z12LEsnLxssQgnRqKE+d/P2uMr5PUDQ="
|
||||
},
|
||||
{
|
||||
"name": "1014-drm-format-helper-add-helper-for-BGR888-to-XRGB8888-.patch",
|
||||
"hash": "sha256-iBM2z+/jZb/3+c9wHjC7W359oRl+DzFDZ1KL5eUc3qo="
|
||||
},
|
||||
{
|
||||
"name": "1015-drm-tiny-add-driver-for-Apple-Touch-Bars-in-x86-Macs.patch",
|
||||
"hash": "sha256-sTb+ruY6W18wz9XRJzZKlfl4a8fGo1nrtCoOYNaPAjI="
|
||||
},
|
||||
{
|
||||
"name": "2008-i915-4-lane-quirk-for-mbp15-1.patch",
|
||||
"hash": "sha256-f/PTDwRGEyVkGHFyypTKi+gIni3R4TmcsOneGc7Ay5A="
|
||||
},
|
||||
{
|
||||
"name": "2009-apple-gmux-allow-switching-to-igpu-at-probe.patch",
|
||||
"hash": "sha256-XKwlyJZjJLQz39mc0/S7sPnRnwrqMsq9OKy+QCO+oho="
|
||||
},
|
||||
{
|
||||
"name": "3001-applesmc-convert-static-structures-to-drvdata.patch",
|
||||
"hash": "sha256-7KGC0pCos351wKNhwJI/Qoc7w+orOPpiTkdCN50G8nI="
|
||||
},
|
||||
{
|
||||
"name": "3002-applesmc-make-io-port-base-addr-dynamic.patch",
|
||||
"hash": "sha256-1fnmMP/3WSy2JqjdCvxu8tWoshCPr8eiG6ttYK/N9WA="
|
||||
},
|
||||
{
|
||||
"name": "3003-applesmc-switch-to-acpi_device-from-platform.patch",
|
||||
"hash": "sha256-3S6BzyoPLoirfyAu4yDyE9aYjUYr/7etmAvN3uKSDLE="
|
||||
},
|
||||
{
|
||||
"name": "3004-applesmc-key-interface-wrappers.patch",
|
||||
"hash": "sha256-9Bq28WcqiOnef0br6bATOudr1ViSpajQs7fv7o8Tg0I="
|
||||
},
|
||||
{
|
||||
"name": "3005-applesmc-basic-mmio-interface-implementation.patch",
|
||||
"hash": "sha256-Hh9DymQ+Y74oSs1zv9F0lTU3jfAenKTM+cmFH9tmN9Q="
|
||||
},
|
||||
{
|
||||
"name": "3006-applesmc-fan-support-on-T2-Macs.patch",
|
||||
"hash": "sha256-D5IQHE8QFo49mnUawSau7xUsMFkHKayyhnHW4hi+fWE="
|
||||
},
|
||||
{
|
||||
"name": "3007-applesmc-Add-iMacPro-to-applesmc_whitelist.patch",
|
||||
"hash": "sha256-rLDuyQYzAaWuu/u6nRRVvGdwyfpLvkGPu1OoD8KS0os="
|
||||
},
|
||||
{
|
||||
"name": "3008-applesmc-make-applesmc_remove-void.patch",
|
||||
"hash": "sha256-j2Rj1PW/bFEYh9IkGkkG9b+G27IAPCInyd828z4WE1s="
|
||||
},
|
||||
{
|
||||
"name": "3009-applesmc-battery-charge-limiter.patch",
|
||||
"hash": "sha256-skYKmLsJ6O42/wINLccZWoKS0XhVlC1Nfxi1Ekloxns="
|
||||
},
|
||||
{
|
||||
"name": "4001-Input-bcm5974-Add-support-for-the-T2-Macs.patch",
|
||||
"hash": "sha256-CaviinY3rYqQh+/DGyeBTzLL/ZfIvguOQlWCs3KN4zc="
|
||||
},
|
||||
{
|
||||
"name": "7001-drm-i915-fbdev-Discard-BIOS-framebuffers-exceeding-h.patch",
|
||||
"hash": "sha256-O6RHFxmKZn7aCq1D+r5z2T3jLt0r5+01EABD9rs0E5M="
|
||||
},
|
||||
{
|
||||
"name": "8001-Add-APFS-driver.patch",
|
||||
"hash": "sha256-40Gl8eR9RB6qEoU+vY7+sVWms8e566OUmAb9LZWZK3w="
|
||||
},
|
||||
{
|
||||
"name": "8002-Necessary-modifications-to-build-APFS-with-the-kerne.patch",
|
||||
"hash": "sha256-n1SH5vC//LRJdWOavH9/BHqBTjkUj5f+dFGitSeHksw="
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{ callPackage, linux_6_13, ... }@args:
|
||||
|
||||
callPackage ./generic.nix args {
|
||||
kernel = linux_6_13;
|
||||
patchesFile = ./latest.json;
|
||||
}
|
||||
@@ -0,0 +1,113 @@
|
||||
{
|
||||
"base_url": "https://raw.githubusercontent.com/t2linux/linux-t2-patches/19c29ff4bbda9f512b7b69d63d249de269dc66ab/",
|
||||
"patches": [
|
||||
{
|
||||
"name": "1001-Add-apple-bce-driver.patch",
|
||||
"hash": "sha256-e3RPvWPj2QASGOS4kieO8YFekrXsBCJtfF82OPlOn2E="
|
||||
},
|
||||
{
|
||||
"name": "1002-Put-apple-bce-in-drivers-staging.patch",
|
||||
"hash": "sha256-DXj4CmE7TKMGrAhQDOR5RVw9YHmyQMiXZsmxYfkKAEA="
|
||||
},
|
||||
{
|
||||
"name": "1005-HID-hid-appletb-bl-add-driver-for-the-backlight-of-A.patch",
|
||||
"hash": "sha256-kEscS1FAyDxLZPOPInYTXFEf4fouBEa4zGctX14hSu8="
|
||||
},
|
||||
{
|
||||
"name": "1006-HID-hid-appletb-kbd-add-driver-for-the-keyboard-mode.patch",
|
||||
"hash": "sha256-eVEuvnoRItaDjwWu41nn9bTkgHgY+1SL/hFAvUR2IlY="
|
||||
},
|
||||
{
|
||||
"name": "1007-HID-multitouch-support-getting-the-contact-ID-from.patch",
|
||||
"hash": "sha256-A4tExJafroVAv/Hbdt7farJM6RYl/DU5KwSbzqcdEVY="
|
||||
},
|
||||
{
|
||||
"name": "1008-HID-multitouch-support-getting-the-tip-state-from-HI.patch",
|
||||
"hash": "sha256-GwK+d87p3UMy66037dzq6/Zearj8gnRHhqSdZczRadY="
|
||||
},
|
||||
{
|
||||
"name": "1009-HID-multitouch-take-cls-maxcontacts-into-account-for.patch",
|
||||
"hash": "sha256-fywzHnCQ657UFye1ckiufral3pBwBGtKdxWqWqaFHM0="
|
||||
},
|
||||
{
|
||||
"name": "1010-HID-multitouch-allow-specifying-if-a-device-is-direc.patch",
|
||||
"hash": "sha256-87SOnLgeG60Svu2Z9QUyP9P6cZ1Gznt6ZYLFImfx+vY="
|
||||
},
|
||||
{
|
||||
"name": "1011-HID-multitouch-add-device-ID-for-Apple-Touch-Bars.patch",
|
||||
"hash": "sha256-TJjXAlQ4WEROnq/xd6/4JHTuEJjqT7dLLcE4etKdzc0="
|
||||
},
|
||||
{
|
||||
"name": "1012-lib-vsprintf-Add-support-for-generic-FOURCCs-by-exte.patch",
|
||||
"hash": "sha256-cMl4WJcT/nM/z12LEsnLxssQgnRqKE+d/P2uMr5PUDQ="
|
||||
},
|
||||
{
|
||||
"name": "1014-drm-format-helper-add-helper-for-BGR888-to-XRGB8888-.patch",
|
||||
"hash": "sha256-iBM2z+/jZb/3+c9wHjC7W359oRl+DzFDZ1KL5eUc3qo="
|
||||
},
|
||||
{
|
||||
"name": "1015-drm-tiny-add-driver-for-Apple-Touch-Bars-in-x86-Macs.patch",
|
||||
"hash": "sha256-sTb+ruY6W18wz9XRJzZKlfl4a8fGo1nrtCoOYNaPAjI="
|
||||
},
|
||||
{
|
||||
"name": "2008-i915-4-lane-quirk-for-mbp15-1.patch",
|
||||
"hash": "sha256-lZ7MWXZubmAlJCqBmuzueg7agENJbikxP1SE46SmwNw="
|
||||
},
|
||||
{
|
||||
"name": "2009-apple-gmux-allow-switching-to-igpu-at-probe.patch",
|
||||
"hash": "sha256-XKwlyJZjJLQz39mc0/S7sPnRnwrqMsq9OKy+QCO+oho="
|
||||
},
|
||||
{
|
||||
"name": "3001-applesmc-convert-static-structures-to-drvdata.patch",
|
||||
"hash": "sha256-7KGC0pCos351wKNhwJI/Qoc7w+orOPpiTkdCN50G8nI="
|
||||
},
|
||||
{
|
||||
"name": "3002-applesmc-make-io-port-base-addr-dynamic.patch",
|
||||
"hash": "sha256-1fnmMP/3WSy2JqjdCvxu8tWoshCPr8eiG6ttYK/N9WA="
|
||||
},
|
||||
{
|
||||
"name": "3003-applesmc-switch-to-acpi_device-from-platform.patch",
|
||||
"hash": "sha256-3S6BzyoPLoirfyAu4yDyE9aYjUYr/7etmAvN3uKSDLE="
|
||||
},
|
||||
{
|
||||
"name": "3004-applesmc-key-interface-wrappers.patch",
|
||||
"hash": "sha256-9Bq28WcqiOnef0br6bATOudr1ViSpajQs7fv7o8Tg0I="
|
||||
},
|
||||
{
|
||||
"name": "3005-applesmc-basic-mmio-interface-implementation.patch",
|
||||
"hash": "sha256-Hh9DymQ+Y74oSs1zv9F0lTU3jfAenKTM+cmFH9tmN9Q="
|
||||
},
|
||||
{
|
||||
"name": "3006-applesmc-fan-support-on-T2-Macs.patch",
|
||||
"hash": "sha256-D5IQHE8QFo49mnUawSau7xUsMFkHKayyhnHW4hi+fWE="
|
||||
},
|
||||
{
|
||||
"name": "3007-applesmc-Add-iMacPro-to-applesmc_whitelist.patch",
|
||||
"hash": "sha256-rLDuyQYzAaWuu/u6nRRVvGdwyfpLvkGPu1OoD8KS0os="
|
||||
},
|
||||
{
|
||||
"name": "3008-applesmc-make-applesmc_remove-void.patch",
|
||||
"hash": "sha256-j2Rj1PW/bFEYh9IkGkkG9b+G27IAPCInyd828z4WE1s="
|
||||
},
|
||||
{
|
||||
"name": "3009-applesmc-battery-charge-limiter.patch",
|
||||
"hash": "sha256-skYKmLsJ6O42/wINLccZWoKS0XhVlC1Nfxi1Ekloxns="
|
||||
},
|
||||
{
|
||||
"name": "4001-Input-bcm5974-Add-support-for-the-T2-Macs.patch",
|
||||
"hash": "sha256-CaviinY3rYqQh+/DGyeBTzLL/ZfIvguOQlWCs3KN4zc="
|
||||
},
|
||||
{
|
||||
"name": "7001-drm-i915-fbdev-Discard-BIOS-framebuffers-exceeding-h.patch",
|
||||
"hash": "sha256-O6RHFxmKZn7aCq1D+r5z2T3jLt0r5+01EABD9rs0E5M="
|
||||
},
|
||||
{
|
||||
"name": "8001-Add-APFS-driver.patch",
|
||||
"hash": "sha256-RjEhzCqGvwRSGFjMgg1Z1kFwbxB9VT3SkVKoOdtDvP0="
|
||||
},
|
||||
{
|
||||
"name": "8002-Necessary-modifications-to-build-APFS-with-the-kerne.patch",
|
||||
"hash": "sha256-n1SH5vC//LRJdWOavH9/BHqBTjkUj5f+dFGitSeHksw="
|
||||
}
|
||||
]
|
||||
}
|
||||
Executable
+93
@@ -0,0 +1,93 @@
|
||||
#!/usr/bin/env nix-shell
|
||||
#!nix-shell -i python -p nix -p "python3.withPackages (p: [p.requests])"
|
||||
|
||||
import argparse
|
||||
import json
|
||||
import re
|
||||
import subprocess
|
||||
import sys
|
||||
from tempfile import NamedTemporaryFile
|
||||
|
||||
import requests
|
||||
|
||||
API_BASE = "https://api.github.com"
|
||||
PATCH_PATTERN = re.compile(r"^\d{4}-.*\.patch$")
|
||||
|
||||
parser = argparse.ArgumentParser(
|
||||
description="Update linux-t2 patches from a GitHub repository."
|
||||
)
|
||||
parser.add_argument("filename", help="the output filename")
|
||||
parser.add_argument(
|
||||
"--repository",
|
||||
help="the source github repository",
|
||||
default="t2linux/linux-t2-patches",
|
||||
nargs="?",
|
||||
)
|
||||
ref_group = parser.add_mutually_exclusive_group()
|
||||
ref_group.add_argument(
|
||||
"--reference", help="the git reference for the patches", default=None, nargs="?"
|
||||
)
|
||||
ref_group.add_argument(
|
||||
"--branch", help="the git branch to fetch", default=None, nargs="?"
|
||||
)
|
||||
|
||||
|
||||
def get_api(endpoint, *args, **kwargs):
|
||||
kwargs["headers"] = {"X-GitHub-Api-Version": "2022-11-28"}
|
||||
response = requests.get(API_BASE + endpoint, *args, **kwargs)
|
||||
response.raise_for_status()
|
||||
return response.json()
|
||||
|
||||
|
||||
def get_sri_hash(data: bytes):
|
||||
with NamedTemporaryFile() as tmpfile:
|
||||
tmpfile.write(data)
|
||||
tmpfile.flush()
|
||||
proc = subprocess.run(
|
||||
["nix-hash", "--sri", "--flat", "--type", "sha256", tmpfile.name],
|
||||
check=True,
|
||||
capture_output=True,
|
||||
)
|
||||
return proc.stdout.decode("utf8").strip()
|
||||
|
||||
|
||||
def main():
|
||||
args = parser.parse_args()
|
||||
reference = args.reference
|
||||
branch = args.branch
|
||||
|
||||
if reference is None:
|
||||
if branch is None:
|
||||
print("Branch and reference not provided, fetching default branch")
|
||||
branch = get_api(f"/repos/{args.repository}")["default_branch"]
|
||||
|
||||
print(f"Reference not provided, fetching from branch {branch}")
|
||||
branch_data = get_api(f"/repos/{args.repository}/branches/{branch}")
|
||||
reference = branch_data["commit"]["sha"]
|
||||
|
||||
print(f"Repository: {args.repository}")
|
||||
print(f" Reference: {reference}")
|
||||
|
||||
base_url = f"https://raw.githubusercontent.com/{args.repository}/{reference}/"
|
||||
contents = get_api(f"/repos/{args.repository}/contents", {"ref": reference})
|
||||
patches = filter(lambda e: PATCH_PATTERN.match(e.get("name")), contents)
|
||||
|
||||
patches_with_hash = []
|
||||
for patch in patches:
|
||||
patch_content = requests.get(patch["download_url"])
|
||||
patch_hash = get_sri_hash(patch_content.content)
|
||||
print(f"{patch['name']}: {patch_hash}")
|
||||
patches_with_hash.append({"name": patch["name"], "hash": patch_hash})
|
||||
|
||||
result = {"base_url": base_url, "patches": patches_with_hash}
|
||||
|
||||
with open(args.filename, "w+") as f:
|
||||
json.dump(result, f, indent=2)
|
||||
f.write("\n") # write final newline
|
||||
print(f"Wrote to {args.filename}")
|
||||
|
||||
return 0
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.exit(main())
|
||||
@@ -0,0 +1,33 @@
|
||||
{ lib, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../common/cpu/amd
|
||||
../../common/cpu/amd/pstate.nix
|
||||
../../common/gpu/amd
|
||||
../../common/gpu/nvidia/prime.nix
|
||||
../../common/gpu/nvidia/ampere
|
||||
../../common/pc/laptop
|
||||
../../common/pc/laptop/ssd
|
||||
];
|
||||
|
||||
hardware.nvidia = {
|
||||
modesetting.enable = lib.mkDefault true;
|
||||
open = lib.mkDefault false;
|
||||
nvidiaSettings = lib.mkDefault true;
|
||||
dynamicBoost.enable = lib.mkDefault true;
|
||||
|
||||
prime = {
|
||||
amdgpuBusId = "PCI:0:6:0";
|
||||
nvidiaBusId = "PCI:0:1:0";
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
asusd = {
|
||||
enable = lib.mkDefault true;
|
||||
enableUserService = lib.mkDefault true;
|
||||
};
|
||||
supergfxd.enable = lib.mkDefault true;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
{ config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf mkMerge;
|
||||
cfg = config.hardware.asus.flow.gv302x;
|
||||
|
||||
in {
|
||||
imports = [
|
||||
../shared.nix
|
||||
];
|
||||
|
||||
options.hardware.asus.flow.gv302x.amdgpu = {
|
||||
recovery.enable = (mkEnableOption "Enable amdgpu.gpu_recovery kernel boot param") // { default = false; };
|
||||
sg_display.enable = (mkEnableOption "Enable amdgpu.gpu_recovery kernel boot param") // { default = true; };
|
||||
psr.enable = (mkEnableOption "Enable amdgpu.dcdebugmask=0x10 kernel boot param") // { default = true; };
|
||||
};
|
||||
|
||||
config = mkMerge [
|
||||
(mkIf cfg.amdgpu.recovery.enable {
|
||||
# Hopefully fixes for where the kernel sometimes hangs when suspending or hibernating
|
||||
# (Though, I'm very suspicious of the Mediatek Wifi...)
|
||||
boot.kernelParams = [
|
||||
"amdgpu.gpu_recovery=1"
|
||||
];
|
||||
})
|
||||
|
||||
(mkIf (!cfg.amdgpu.sg_display.enable) {
|
||||
# Can help solve flickering/glitching display issues since Scatter/Gather code was reenabled
|
||||
boot.kernelParams = [
|
||||
"amdgpu.sg_display=0"
|
||||
];
|
||||
})
|
||||
|
||||
(mkIf (!cfg.amdgpu.psr.enable) {
|
||||
# Can help solve flickering/glitching display issues since Scatter/Gather code was reenabled
|
||||
boot.kernelParams = [
|
||||
"amdgpu.dcdebugmask=0x10"
|
||||
];
|
||||
})
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,55 @@
|
||||
{ lib,
|
||||
pkgs,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
inherit (lib) mkDefault;
|
||||
|
||||
in {
|
||||
imports = [
|
||||
../shared.nix
|
||||
## "prime.nix" loads this, aleady:
|
||||
# ../../../common/gpu/nvidia
|
||||
../../../../common/gpu/nvidia/prime.nix
|
||||
../../../../common/gpu/nvidia/ada-lovelace
|
||||
|
||||
];
|
||||
|
||||
# NVIDIA GeForce RTX 4070 Mobile
|
||||
|
||||
boot = {
|
||||
blacklistedKernelModules = [ "nouveau" ];
|
||||
};
|
||||
|
||||
|
||||
|
||||
hardware = {
|
||||
## Enable the Nvidia card, as well as Prime and Offload:
|
||||
amdgpu.initrd.enable = mkDefault true;
|
||||
|
||||
nvidia = {
|
||||
|
||||
modesetting.enable = true;
|
||||
nvidiaSettings = mkDefault true;
|
||||
|
||||
prime = {
|
||||
offload = {
|
||||
enable = mkDefault true;
|
||||
enableOffloadCmd = mkDefault true;
|
||||
};
|
||||
amdgpuBusId = "PCI:69:0:0";
|
||||
nvidiaBusId = "PCI:1:0:0";
|
||||
};
|
||||
|
||||
powerManagement = {
|
||||
enable = mkDefault true;
|
||||
finegrained = mkDefault true;
|
||||
};
|
||||
|
||||
dynamicBoost.enable = mkDefault true;
|
||||
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,106 @@
|
||||
{ config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
inherit (lib) mkDefault mkEnableOption mkIf mkMerge version versionAtLeast versionOlder;
|
||||
|
||||
cfg = config.hardware.asus.flow.gv302x;
|
||||
in {
|
||||
|
||||
imports = [
|
||||
../../../common/cpu/amd
|
||||
# Better power-savings from AMD PState:
|
||||
../../../common/cpu/amd/pstate.nix
|
||||
../../../common/gpu/amd
|
||||
../../../common/pc/laptop
|
||||
../../../common/pc/ssd
|
||||
];
|
||||
|
||||
options.hardware.asus.flow.gv302x = {
|
||||
# Kernels earlier than 6.9 (possibly even earlier) tend to take 1-2 key-presses
|
||||
# to wake-up the internal keyboard after the device is suspended.
|
||||
# Therefore, this option disables auto-suspend for the keyboard by default, but
|
||||
# enables it for kernel 6.9.x onwards.
|
||||
#
|
||||
# Note: the device name is "ASUS N-KEY Device".
|
||||
keyboard.autosuspend.enable = (
|
||||
mkEnableOption "Enable auto-suspend on the internal USB keyboard (ASUS N-KEY Device) on Flow GV302X"
|
||||
) // {
|
||||
default = versionAtLeast config.boot.kernelPackages.kernel.version "6.9";
|
||||
defaultText = lib.literalExpression "lib.versionAtLeast config.boot.kernelPackages.kernel.version \"6.9\"";
|
||||
};
|
||||
# The ASUS 8295 ITE device will cause an immediate wake-up when trying to suspend the laptop.
|
||||
# After the first successful hibernate, it will work as expected, however.
|
||||
# NOTE: I'm not actually sure what this device, as neither the touchpad nor the M1-M4 keys cause a wake-up.
|
||||
ite-device.wakeup.enable = mkEnableOption "Enable power wakeup on the internal USB keyboard-like device (8295 ITE Device) on Flow GV302X";
|
||||
};
|
||||
|
||||
config = mkMerge [
|
||||
{
|
||||
# Configure basic system settings:
|
||||
boot = {
|
||||
kernelModules = [ "kvm-amd" ];
|
||||
kernelParams = [
|
||||
"mem_sleep_default=deep"
|
||||
"pcie_aspm.policy=powersupersave"
|
||||
];
|
||||
};
|
||||
|
||||
services = {
|
||||
asusd = {
|
||||
enable = mkDefault true;
|
||||
enableUserService = mkDefault true;
|
||||
};
|
||||
|
||||
supergfxd.enable = mkDefault true;
|
||||
|
||||
udev = {
|
||||
extraHwdb = ''
|
||||
# Fixes mic mute button
|
||||
evdev:name:*:dmi:bvn*:bvr*:bd*:svnASUS*:pn*:*
|
||||
KEYBOARD_KEY_ff31007c=f20
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
#flow devices are 2 in 1 laptops
|
||||
hardware.sensor.iio.enable = mkDefault true;
|
||||
|
||||
}
|
||||
|
||||
(mkIf (! cfg.keyboard.autosuspend.enable) {
|
||||
services.udev.extraRules = ''
|
||||
# Disable power auto-suspend for the ASUS N-KEY device, i.e. USB Keyboard.
|
||||
# Otherwise on certain kernel-versions, it will tend to take 1-2 key-presses to wake-up after the device suspends.
|
||||
ACTION=="add", SUBSYSTEM=="usb", TEST=="power/autosuspend", ATTR{idVendor}=="0b05", ATTR{idProduct}=="19b6", ATTR{power/autosuspend}="-1"
|
||||
'';
|
||||
})
|
||||
|
||||
(mkIf (! cfg.ite-device.wakeup.enable) {
|
||||
services.udev.extraRules = ''
|
||||
# Disable power wakeup for the 8295 ITE device.
|
||||
# Otherwise on certain kernel-versions, it will tend to cause the laptop to immediately wake-up when suspending.
|
||||
# ACTION=="add|change", SUBSYSTEM=="usb", DRIVER="usb", TEST="power/wakeup", ATTR{idVendor}=="0b05", ATTR{idProduct}=="193b", ATTR{power/wakeup}="disabled"
|
||||
ACTION=="add|change", SUBSYSTEM=="usb", ATTR{idVendor}=="0b05", ATTR{idProduct}=="193b", ATTR{power/wakeup}="disabled"
|
||||
'';
|
||||
})
|
||||
|
||||
(mkIf (config.networking.wireless.iwd.enable && config.networking.wireless.scanOnLowSignal) {
|
||||
# Meditek doesn't seem to be quite sensitive enough on the default roaming settings:
|
||||
# https://wiki.archlinux.org/title/Wpa_supplicant#Roaming
|
||||
# https://wiki.archlinux.org/title/Iwd#iwd_keeps_roaming
|
||||
#
|
||||
# But NixOS doesn't have the tweaks for IWD, yet.
|
||||
networking.wireless.iwd.settings = {
|
||||
General = {
|
||||
RoamThreshold = -75;
|
||||
RoamThreshold5G = -80;
|
||||
RoamRetryInterval = 20;
|
||||
};
|
||||
};
|
||||
})
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
imports = [
|
||||
../cpu-only.nix
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
imports = [
|
||||
./cpu-only.nix
|
||||
../../../gpu/intel/skylake
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [ ../. ];
|
||||
|
||||
boot.kernelParams = [
|
||||
"i915.enable_guc=2"
|
||||
];
|
||||
|
||||
# VP9 decoding not supported when using intel-media-driver
|
||||
# https://github.com/intel/media-driver/issues/1024
|
||||
# NixOS Wiki recommends using the legacy intel-vaapi-driver with the hybrid codec over that one for Skylake.
|
||||
# https://wiki.nixos.org/wiki/Accelerated_Video_Playback
|
||||
hardware.intelgpu = {
|
||||
vaapiDriver = "intel-vaapi-driver";
|
||||
enableHybridCodec = true;
|
||||
};
|
||||
}
|
||||
@@ -2,7 +2,6 @@
|
||||
{
|
||||
imports = [ ../. ];
|
||||
config = {
|
||||
hardware.intelgpu.driver = lib.mkIf (lib.versionAtLeast config.boot.kernelPackages.kernel.version "6.8") "xe";
|
||||
boot.kernelParams = lib.mkIf (config.hardware.intelgpu.driver == "i915") [ "i915.enable_guc=3" ];
|
||||
hardware.intelgpu.vaapiDriver = "intel-media-driver";
|
||||
};
|
||||
|
||||
@@ -3,6 +3,4 @@
|
||||
{
|
||||
imports = [ ../24.05-compat.nix ];
|
||||
services.xserver.videoDrivers = lib.mkDefault [ "nvidia" ];
|
||||
# TODO: this will be a default after https://github.com/NixOS/nixpkgs/pull/326369
|
||||
hardware.nvidia.modesetting.enable = lib.mkDefault true;
|
||||
}
|
||||
@@ -1,6 +1,13 @@
|
||||
{
|
||||
imports = [
|
||||
../../common/cpu/intel
|
||||
../../common/pc/laptop
|
||||
../latitude/e7240/default.nix
|
||||
];
|
||||
|
||||
warnings = [
|
||||
''
|
||||
DEPRECATED: Importing dell/e7240 is deprecated. Use dell/latitude/e7240 instead.
|
||||
|
||||
This module will be removed in a future release.
|
||||
''
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
{ lib, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../../common/cpu/intel/coffee-lake
|
||||
../../../common/gpu/nvidia/prime.nix
|
||||
../../../common/gpu/nvidia/pascal
|
||||
../../../common/pc/laptop
|
||||
../../../common/pc/laptop/ssd
|
||||
];
|
||||
|
||||
# Specify bus id of Nvidia and Intel graphics
|
||||
hardware.nvidia.prime = {
|
||||
intelBusId = "PCI:0:2:0";
|
||||
nvidiaBusId = "PCI:1:0:0";
|
||||
};
|
||||
|
||||
# Cooling management
|
||||
services.thermald.enable = lib.mkDefault true;
|
||||
|
||||
boot = {
|
||||
# Use same ACPI identifier as Dell Ubuntu
|
||||
kernelParams = [ "acpi_osi=Linux-Dell-Video" ];
|
||||
|
||||
# Enable fan sensors.
|
||||
kernelModules = [ "dell-smm-hwmon" ];
|
||||
|
||||
# Forces the driver to load on unknown hardware
|
||||
extraModprobeConfig = "options dell-smm-hwmon ignore_dmi=1";
|
||||
# NOTE: PWM fan control compatibility needs explicit whitelisting in the kernel driver's code.
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
## Dell Inspiron 3442
|
||||
|
||||
### Tested Hardware
|
||||
|
||||
```shellsession
|
||||
$ lspci -nn
|
||||
|
||||
00:00.0 Host bridge [0600]: Intel Corporation Haswell-ULT DRAM Controller [8086:0a04] (rev 0b)
|
||||
00:02.0 VGA compatible controller [0300]: Intel Corporation Haswell-ULT Integrated Graphics Controller [8086:0a16] (rev 0b)
|
||||
00:03.0 Audio device [0403]: Intel Corporation Haswell-ULT HD Audio Controller [8086:0a0c] (rev 0b)
|
||||
00:14.0 USB controller [0c03]: Intel Corporation 8 Series USB xHCI HC [8086:9c31] (rev 04)
|
||||
00:16.0 Communication controller [0780]: Intel Corporation 8 Series HECI #0 [8086:9c3a] (rev 04)
|
||||
00:1b.0 Audio device [0403]: Intel Corporation 8 Series HD Audio Controller [8086:9c20] (rev 04)
|
||||
00:1c.0 PCI bridge [0604]: Intel Corporation 8 Series PCI Express Root Port 1 [8086:9c10] (rev e4)
|
||||
00:1c.2 PCI bridge [0604]: Intel Corporation 8 Series PCI Express Root Port 3 [8086:9c14] (rev e4)
|
||||
00:1c.3 PCI bridge [0604]: Intel Corporation 8 Series PCI Express Root Port 4 [8086:9c16] (rev e4)
|
||||
00:1d.0 USB controller [0c03]: Intel Corporation 8 Series USB EHCI #1 [8086:9c26] (rev 04)
|
||||
00:1f.0 ISA bridge [0601]: Intel Corporation 8 Series LPC Controller [8086:9c45] (rev 04)
|
||||
00:1f.2 SATA controller [0106]: Intel Corporation 8 Series SATA Controller 1 [AHCI mode] [8086:9c03] (rev 04)
|
||||
00:1f.3 SMBus [0c05]: Intel Corporation 8 Series SMBus Controller [8086:9c22] (rev 04)
|
||||
06:00.0 Network controller [0280]: Broadcom Inc. and subsidiaries BCM43142 802.11b/g/n [14e4:4365] (rev 01)
|
||||
07:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL810xE PCI Express Fast Ethernet controller [10ec:8136] (rev 07)
|
||||
|
||||
```
|
||||
|
||||
### Extra Configuration
|
||||
|
||||
#### Bluetooth
|
||||
|
||||
To enable bluetooth support, set `hardware.bluetooth.enable = true;`.
|
||||
|
||||
### Firmware Upgrades
|
||||
|
||||
This device is partially supported by [fwupd](https://fwupd.org).
|
||||
Use `fwupdmgr` to perform updates.
|
||||
@@ -0,0 +1,22 @@
|
||||
{ config, lib, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../../common/cpu/intel
|
||||
../../../common/pc/laptop
|
||||
../../../common/gpu/intel/haswell
|
||||
];
|
||||
|
||||
hardware.enableAllFirmware = lib.mkDefault true;
|
||||
|
||||
services = {
|
||||
fwupd.enable = lib.mkDefault true;
|
||||
thermald.enable = lib.mkDefault true;
|
||||
};
|
||||
|
||||
boot = {
|
||||
# needs to be explicitly loaded or else bluetooth/wifi won't work.
|
||||
kernelModules = [ "wl" ];
|
||||
extraModulePackages = [ config.boot.kernelPackages.broadcom_sta ];
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
## Dell Inspiron 7559
|
||||
|
||||
### Tested Hardware
|
||||
|
||||
```shellsession
|
||||
$ lspci -nn
|
||||
00:00.0 Host bridge [0600]: Intel Corporation Xeon E3-1200 v5/E3-1500 v5/6th Gen Core Processor Host Bridge/DRAM Registers [8086:1910] (rev 07)
|
||||
00:01.0 PCI bridge [0604]: Intel Corporation 6th-10th Gen Core Processor PCIe Controller (x16) [8086:1901] (rev 07)
|
||||
00:01.1 PCI bridge [0604]: Intel Corporation Xeon E3-1200 v5/E3-1500 v5/6th Gen Core Processor PCIe Controller (x8) [8086:1905] (rev 07)
|
||||
00:02.0 VGA compatible controller [0300]: Intel Corporation HD Graphics 530 [8086:191b] (rev 06)
|
||||
00:04.0 Signal processing controller [1180]: Intel Corporation Xeon E3-1200 v5/E3-1500 v5/6th Gen Core Processor Thermal Subsystem [8086:1903] (rev 07)
|
||||
00:14.0 USB controller [0c03]: Intel Corporation 100 Series/C230 Series Chipset Family USB 3.0 xHCI Controller [8086:a12f] (rev 31)
|
||||
00:14.2 Signal processing controller [1180]: Intel Corporation 100 Series/C230 Series Chipset Family Thermal Subsystem [8086:a131] (rev 31)
|
||||
00:15.0 Signal processing controller [1180]: Intel Corporation 100 Series/C230 Series Chipset Family Serial IO I2C Controller #0 [8086:a160] (rev 31)
|
||||
00:16.0 Communication controller [0780]: Intel Corporation 100 Series/C230 Series Chipset Family MEI Controller #1 [8086:a13a] (rev 31)
|
||||
00:17.0 SATA controller [0106]: Intel Corporation HM170/QM170 Chipset SATA Controller [AHCI Mode] [8086:a103] (rev 31)
|
||||
00:1c.0 PCI bridge [0604]: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #1 [8086:a110] (rev f1)
|
||||
00:1c.4 PCI bridge [0604]: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #5 [8086:a114] (rev f1)
|
||||
00:1c.5 PCI bridge [0604]: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #6 [8086:a115] (rev f1)
|
||||
00:1c.6 PCI bridge [0604]: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #7 [8086:a116] (rev f1)
|
||||
00:1f.0 ISA bridge [0601]: Intel Corporation HM170 Chipset LPC/eSPI Controller [8086:a14e] (rev 31)
|
||||
00:1f.2 Memory controller [0580]: Intel Corporation 100 Series/C230 Series Chipset Family Power Management Controller [8086:a121] (rev 31)
|
||||
00:1f.3 Audio device [0403]: Intel Corporation 100 Series/C230 Series Chipset Family HD Audio Controller [8086:a170] (rev 31)
|
||||
00:1f.4 SMBus [0c05]: Intel Corporation 100 Series/C230 Series Chipset Family SMBus [8086:a123] (rev 31)
|
||||
02:00.0 3D controller [0302]: NVIDIA Corporation GM107M [GeForce GTX 960M] [10de:139b] (rev a2)
|
||||
04:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL8111/8168/8211/8411 PCI Express Gigabit Ethernet Controller [10ec:8168] (rev 10)
|
||||
05:00.0 Network controller [0280]: Intel Corporation Wireless 3165 [8086:3165] (rev 79)
|
||||
06:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS522A PCI Express Card Reader [10ec:522a] (rev 01)
|
||||
|
||||
```
|
||||
|
||||
### Extra Configuration
|
||||
|
||||
#### Bluetooth
|
||||
|
||||
To enable bluetooth support, set `hardware.bluetooth.enable = true;`.
|
||||
|
||||
#### Prime Offloading
|
||||
|
||||
This configuration uses Nvidia Prime offloading, which allows use of the `nvidia-offload` script for running commands on the dGPU. For example, you can instruct Steam to launch a game offloaded to the GPU by setting the launch options for that game to `nvidia-offload %command%`.
|
||||
|
||||
#### SSD
|
||||
|
||||
This laptop has an optional M.2 SSD slot, which isn't accounted for here. If you are using the SSD, you could look into implementing the options in [ssd](common/pc/laptop/ssd) manually. Some sources also say you should ensure your SATA Mode is set to AHCI in your BIOS for it to be detected, however I think this is a prerequisite to installing Linux on this laptop in the first place so you probably already have that set.
|
||||
|
||||
#### Subwoofer
|
||||
|
||||
Tested with the default PipeWire configuration on Plasma, the subwoofer appears to work depending on the device Profile in sound settings ("Analog Stereo Duplex" works best for me). I have had issues with it in the past on other distros, so if it's not working on your system you could try the solution in [this thread](https://bbs.archlinux.org/viewtopic.php?id=207222).
|
||||
|
||||
#### Other issues
|
||||
|
||||
There are plenty of documented bugs and threads around issues on Dell laptops like this. Some of them stem from using the nouveau drivers, but we're using the proprietary Nvidia drivers here. Some things to look into if you're experiencing issues:
|
||||
|
||||
* I/O is slow: `nouveau` could be added as a kernel blocklist item: searching this repo shows other laptops with this configuration
|
||||
* Power drain while sleeping: add the following as boot.kernelParams: `"mem_sleep_default=deep"`
|
||||
* Issues coming back from suspend (particularly if the previous kernelParam is applied): add the following as boot.kernelParams: `"acpi_rev_override=1"` `"acpi_osi=Linux"`
|
||||
* I also spotted [one person recommending](https://connorkuehl.github.io/dell-inspiron-7559-linux-guide/) setting just `"acpi_osi="`. This article is quite old though and I haven't tested the difference.
|
||||
* Brightness function keys don't work: add the following as boot.kernelParams: `"acpi_backlight=vendor"` or `"acpi_backlight=native"`
|
||||
@@ -0,0 +1,24 @@
|
||||
{ lib, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../../common/pc/laptop
|
||||
../../../common/pc/laptop/hdd
|
||||
../../../common/cpu/intel/skylake
|
||||
../../../common/gpu/nvidia/maxwell
|
||||
../../../common/gpu/nvidia/prime.nix
|
||||
];
|
||||
|
||||
hardware = {
|
||||
nvidia.prime = {
|
||||
intelBusId = "PCI:0:2:0";
|
||||
nvidiaBusId = "PCI:2:0:0";
|
||||
};
|
||||
|
||||
enableRedistributableFirmware = lib.mkDefault true;
|
||||
};
|
||||
|
||||
services = {
|
||||
thermald.enable = lib.mkDefault true;
|
||||
};
|
||||
}
|
||||
@@ -12,7 +12,7 @@
|
||||
|
||||
boot = {
|
||||
# Kernel Panic on suspend fix, taken from ArchLinux wiki.
|
||||
kernelParams = "acpi_enforce_resources=lax i915.enable_dc=0";
|
||||
kernelParams = [ "acpi_enforce_resources=lax" "i915.enable_dc=0" ];
|
||||
# Audio Mute LED
|
||||
extraModprobeConfig = ''
|
||||
options snd-hda-intel model=mute-led-gpio
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
{ lib, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../../common/cpu/intel/tiger-lake
|
||||
../../../common/pc/laptop
|
||||
../../../common/pc/laptop/ssd
|
||||
];
|
||||
}
|
||||
File renamed without changes.
@@ -0,0 +1,6 @@
|
||||
{
|
||||
imports = [
|
||||
../../../common/cpu/intel
|
||||
../../../common/pc/laptop
|
||||
];
|
||||
}
|
||||
@@ -27,4 +27,7 @@
|
||||
|
||||
# enable cooling management, see NixOS/nixos-hardware#127
|
||||
services.thermald.enable = lib.mkDefault true;
|
||||
|
||||
# fix laptop's screen flickering, see https://wiki.archlinux.org/title/Intel_graphics#Screen_flickering
|
||||
boot.kernelParams = ["i915.enable_psr=0"];
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
= Dell XPS 15 9530 =
|
||||
|
||||
== Tested Hardware ==
|
||||
|
||||
* CPU: 13th Gen Intel(R) Core(TM) i9-13900H
|
||||
* RAM: 32 GB
|
||||
* HDD: 1 TiB SSD (NVME)
|
||||
* Screen: 15" 4k (3456 x 2160)
|
||||
* Graphics: NVIDIA GeForce RTX 4070 Laptop GPU, with Intel Graphics too.
|
||||
* Input: Touchscreen and trackpad.
|
||||
|
||||
== Notes ==
|
||||
|
||||
== NVIDIA Offload ==
|
||||
|
||||
In order to run a program on the NVIDIA gpu, you can use the `nvidia-offload` function, for example:
|
||||
```
|
||||
nvidia-offload `nix-shell -p glxinfo --run 'glxgears'`
|
||||
```
|
||||
This is a short bash script that sets the proper environment variables and calls your command.
|
||||
@@ -0,0 +1,29 @@
|
||||
{ lib, ... }:
|
||||
{
|
||||
imports = [
|
||||
../../../common/cpu/intel
|
||||
../../../common/pc/laptop
|
||||
../../../common/pc/laptop/ssd
|
||||
];
|
||||
|
||||
# This will save you money and possibly your life!
|
||||
services.thermald.enable = lib.mkDefault true;
|
||||
|
||||
# 9530 wifi is:
|
||||
# > lspci | grep i Network
|
||||
# - 00:14.3 Network controller: Intel Corporation Raptor Lake PCH CNVi WiFi (rev 01)
|
||||
# > sudo lspci -vv -s 00:14.3
|
||||
# 00:14.3 Network controller: Intel Corporation Raptor Lake PCH CNVi WiFi (rev 01)
|
||||
# Subsystem: Intel Corporation Wi-Fi 6E AX211 160MHz
|
||||
#
|
||||
# WiFi speed is slow and crashes by default (https://bugzilla.kernel.org/show_bug.cgi?id=213381)
|
||||
# disable_11ax - required until ax driver support is fixed
|
||||
# power_save - works well on this card
|
||||
# boot.extraModprobeConfig = ''
|
||||
# options iwlwifi power_save=1 disable_11ax=1
|
||||
# '';
|
||||
|
||||
boot.extraModprobeConfig = ''
|
||||
options iwlwifi power_save=1
|
||||
'';
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
{ lib, ... }:
|
||||
{
|
||||
imports = [
|
||||
../default.nix
|
||||
../../../../common/gpu/nvidia/prime.nix
|
||||
];
|
||||
|
||||
hardware.nvidia.prime = {
|
||||
# Bus ID of the Intel GPU.
|
||||
intelBusId = lib.mkDefault "PCI:0:2:0";
|
||||
|
||||
# Bus ID of the NVIDIA GPU.
|
||||
nvidiaBusId = lib.mkDefault "PCI:1:0:0";
|
||||
};
|
||||
}
|
||||
@@ -1,11 +1,6 @@
|
||||
{ lib, ... }:
|
||||
{
|
||||
imports = [
|
||||
../../../common/cpu/intel/kaby-lake
|
||||
../../../common/pc/laptop
|
||||
./xps-common.nix
|
||||
./shared.nix
|
||||
];
|
||||
|
||||
# Includes the Wi-Fi and Bluetooth firmware
|
||||
hardware.enableRedistributableFirmware = lib.mkDefault true;
|
||||
}
|
||||
@@ -1,8 +1,8 @@
|
||||
{
|
||||
imports = [
|
||||
../../../../common/cpu/intel
|
||||
../../../../common/pc/laptop
|
||||
../../../../common/gpu/nvidia/disable.nix
|
||||
../xps-common.nix
|
||||
../shared.nix
|
||||
];
|
||||
|
||||
# Disables the Nvidia GPU, better for battery life
|
||||
}
|
||||
@@ -1,12 +1,9 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../../../common/cpu/intel
|
||||
../../../../common/gpu/nvidia/prime.nix
|
||||
../../../../common/gpu/nvidia/pascal
|
||||
../../../../common/pc/laptop
|
||||
../xps-common.nix
|
||||
../shared.nix
|
||||
];
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
{ lib, ... }:
|
||||
{
|
||||
|
||||
imports = [
|
||||
../../../common/cpu/intel/coffee-lake
|
||||
../../../common/pc/laptop
|
||||
];
|
||||
|
||||
# Solution to rcu_sched freezing
|
||||
boot.kernelParams = [ "acpi_rev_override" ];
|
||||
|
||||
# This will save you money and possibly your life!
|
||||
# https://github.com/NixOS/nixos-hardware/pull/127
|
||||
services.thermald.enable = lib.mkDefault true;
|
||||
|
||||
hardware.graphics = {
|
||||
enable = lib.mkDefault true;
|
||||
enable32Bit = lib.mkDefault true;
|
||||
};
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
{ lib, ... }:
|
||||
|
||||
{
|
||||
# Solution to rcu_sched freezing
|
||||
boot.kernelParams = [ "acpi_rev_override" ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
|
||||
# This will save you money and possibly your life!
|
||||
services.thermald.enable = lib.mkDefault true;
|
||||
}
|
||||
@@ -12,6 +12,7 @@
|
||||
{
|
||||
acer-aspire-4810t = import ./acer/aspire/4810t;
|
||||
airis-n990 = import ./airis/n990;
|
||||
aoostar-r1-n100 = import ./aoostar/r1/n100;
|
||||
apple-imac-14-2 = import ./apple/imac/14-2;
|
||||
apple-imac-18-2 = import ./apple/imac/18-2;
|
||||
apple-macbook-air-3 = import ./apple/macbook-air/3;
|
||||
@@ -31,8 +32,11 @@
|
||||
asus-ally-rc71l = import ./asus/ally/rc71l;
|
||||
asus-fx504gd = import ./asus/fx504gd;
|
||||
asus-fx506hm = import ./asus/fx506hm;
|
||||
asus-fa506ic = import ./asus/fa506ic;
|
||||
asus-fa507nv = import ./asus/fa507nv;
|
||||
asus-fa507rm = import ./asus/fa507rm;
|
||||
asus-flow-gv302x-amdgpu = import ./asus/flow/gv302x/amdgpu;
|
||||
asus-flow-gv302x-nvidia = import ./asus/flow/gv302x/nvidia;
|
||||
asus-pro-ws-x570-ace = import ./asus/pro-ws-x570-ace;
|
||||
asus-rog-strix-g513im = import ./asus/rog-strix/g513im;
|
||||
asus-rog-strix-g713ie = import ./asus/rog-strix/g713ie;
|
||||
@@ -52,21 +56,28 @@
|
||||
beagleboard-pocketbeagle = import ./beagleboard/pocketbeagle;
|
||||
chuwi-minibook-x = import ./chuwi/minibook-x;
|
||||
deciso-dec = import ./deciso/dec;
|
||||
dell-e7240 = import ./dell/e7240;
|
||||
dell-e7240 =
|
||||
deprecated "1326" "dell-e7240"
|
||||
(import ./dell/e7240);
|
||||
dell-g3-3779 = import ./dell/g3/3779;
|
||||
dell-g3-3579 = import ./dell/g3/3579;
|
||||
dell-inspiron-14-5420 = import ./dell/inspiron/14-5420;
|
||||
dell-inspiron-5509 = import ./dell/inspiron/5509;
|
||||
dell-inspiron-5515 = import ./dell/inspiron/5515;
|
||||
dell-inspiron-7405 = import ./dell/inspiron/7405;
|
||||
dell-inspiron-7460 = import ./dell/inspiron/7460;
|
||||
dell-inspiron-7559 = import ./dell/inspiron/7559;
|
||||
dell-latitude-3340 = import ./dell/latitude/3340;
|
||||
dell-latitude-3480 = import ./dell/latitude/3480;
|
||||
dell-latitude-5490 = import ./dell/latitude/5490;
|
||||
dell-latitude-5520 = import ./dell/latitude/5520;
|
||||
dell-latitude-7280 = import ./dell/latitude/7280;
|
||||
dell-latitude-7390 = import ./dell/latitude/7390;
|
||||
dell-latitude-7420 = import ./dell/latitude/7420;
|
||||
dell-latitude-7430 = import ./dell/latitude/7430;
|
||||
dell-latitude-7490 = import ./dell/latitude/7490;
|
||||
dell-latitude-9430 = import ./dell/latitude/9430;
|
||||
dell-latitude-e7240 = import ./dell/latitude/e7240;
|
||||
dell-optiplex-3050 = import ./dell/optiplex/3050;
|
||||
dell-poweredge-r7515 = import ./dell/poweredge/r7515;
|
||||
dell-precision-3541 = import ./dell/precision/3541;
|
||||
@@ -92,6 +103,8 @@
|
||||
dell-xps-15-9510-nvidia = import ./dell/xps/15-9510/nvidia;
|
||||
dell-xps-15-9520 = import ./dell/xps/15-9520;
|
||||
dell-xps-15-9520-nvidia = import ./dell/xps/15-9520/nvidia;
|
||||
dell-xps-15-9530 = import ./dell/xps/15-9530;
|
||||
dell-xps-15-9530-nvidia = import ./dell/xps/15-9530/nvidia;
|
||||
dell-xps-15-9550 = import ./dell/xps/15-9550;
|
||||
dell-xps-15-9550-nvidia = import ./dell/xps/15-9550/nvidia;
|
||||
dell-xps-15-9560 = import ./dell/xps/15-9560;
|
||||
@@ -114,10 +127,12 @@
|
||||
friendlyarm-nanopi-r5s = import ./friendlyarm/nanopi-r5s;
|
||||
focus-m2-gen1 = import ./focus/m2/gen1;
|
||||
gigabyte-b550 = import ./gigabyte/b550;
|
||||
gigabyte-b650 = import ./gigabyte/b650;
|
||||
google-pixelbook = import ./google/pixelbook;
|
||||
gpd-micropc = import ./gpd/micropc;
|
||||
gpd-p2-max = import ./gpd/p2-max;
|
||||
gpd-pocket-3 = import ./gpd/pocket-3;
|
||||
gpd-pocket-4 = import ./gpd/pocket-4;
|
||||
gpd-win-2 = import ./gpd/win-2;
|
||||
gpd-win-max-2-2023 = import ./gpd/win-max-2/2023;
|
||||
gpd-win-mini-2024 = import ./gpd/win-mini/2024;
|
||||
@@ -126,10 +141,12 @@
|
||||
hp-elitebook-845g7 = import ./hp/elitebook/845/g7;
|
||||
hp-elitebook-845g8 = import ./hp/elitebook/845/g8;
|
||||
hp-elitebook-845g9 = import ./hp/elitebook/845/g9;
|
||||
hp-probook-440G5 = import ./hp/probook/440G5;
|
||||
hp-laptop-14s-dq2024nf = import ./hp/laptop/14s-dq2024nf;
|
||||
huawei-machc-wa = import ./huawei/machc-wa;
|
||||
hp-notebook-14-df0023 = import ./hp/notebook/14-df0023;
|
||||
intel-nuc-8i7beh = import ./intel/nuc/8i7beh;
|
||||
lenovo-ideacentre-k330 = import ./lenovo/ideacentre/k330;
|
||||
lenovo-ideapad-15alc6 = import ./lenovo/ideapad/15alc6;
|
||||
lenovo-ideapad-15arh05 = import ./lenovo/ideapad/15arh05;
|
||||
lenovo-ideapad-15ach6 = import ./lenovo/ideapad/15ach6;
|
||||
@@ -172,6 +189,7 @@
|
||||
lenovo-thinkpad-p14s-amd-gen4 = import ./lenovo/thinkpad/p14s/amd/gen4;
|
||||
lenovo-thinkpad-p14s-intel-gen3 = import ./lenovo/thinkpad/p14s/intel/gen3;
|
||||
lenovo-thinkpad-p16s-amd-gen1 = import ./lenovo/thinkpad/p16s/amd/gen1;
|
||||
lenovo-thinkpad-p16s-amd-gen2 = import ./lenovo/thinkpad/p16s/amd/gen2;
|
||||
lenovo-thinkpad-p50 = import ./lenovo/thinkpad/p50;
|
||||
lenovo-thinkpad-p51 = import ./lenovo/thinkpad/p51;
|
||||
lenovo-thinkpad-p52 = import ./lenovo/thinkpad/p52;
|
||||
@@ -198,6 +216,7 @@
|
||||
lenovo-thinkpad-t480 = import ./lenovo/thinkpad/t480;
|
||||
lenovo-thinkpad-t480s = import ./lenovo/thinkpad/t480s;
|
||||
lenovo-thinkpad-t490 = import ./lenovo/thinkpad/t490;
|
||||
lenovo-thinkpad-t490s = import ./lenovo/thinkpad/t490s;
|
||||
lenovo-thinkpad-t495 = import ./lenovo/thinkpad/t495;
|
||||
lenovo-thinkpad-t520 = import ./lenovo/thinkpad/t520;
|
||||
lenovo-thinkpad-w520 = import ./lenovo/thinkpad/w520;
|
||||
@@ -263,7 +282,9 @@
|
||||
nxp-imx8qm-mek = import ./nxp/imx8qm-mek;
|
||||
hardkernel-odroid-hc4 = import ./hardkernel/odroid-hc4;
|
||||
hardkernel-odroid-h3 = import ./hardkernel/odroid-h3;
|
||||
hardkernel-odroid-h4 = import ./hardkernel/odroid-h4;
|
||||
omen-14-fb0798ng = import ./omen/14-fb0798ng;
|
||||
omen-15-ce002ns = import ./omen/15-ce002ns;
|
||||
omen-15-en0010ca = import ./omen/15-en0010ca;
|
||||
omen-16-n0005ne = import ./omen/16-n0005ne;
|
||||
omen-16-n0280nd = import ./omen/16-n0280nd;
|
||||
@@ -283,8 +304,13 @@
|
||||
raspberry-pi-3 = import ./raspberry-pi/3;
|
||||
raspberry-pi-4 = import ./raspberry-pi/4;
|
||||
raspberry-pi-5 = import ./raspberry-pi/5;
|
||||
rock-4c-plus = import ./radxa/rock-4c-plus;
|
||||
rock-5b = import ./radxa/rock-5b;
|
||||
rock-pi-4 = import ./radxa/rock-pi-4;
|
||||
rock-pi-e = import ./radxa/rock-pi-e;
|
||||
kobol-helios4 = import ./kobol/helios4;
|
||||
samsung-np900x3c = import ./samsung/np900x3c;
|
||||
slimbook-hero-rpl-rtx = import ./slimbook/hero/rpl-rtx;
|
||||
starfive-visionfive-v1 = import ./starfive/visionfive/v1;
|
||||
starfive-visionfive-2 = import ./starfive/visionfive/v2;
|
||||
starlabs-starlite-i5 = import ./starlabs/starlite/i5;
|
||||
@@ -303,6 +329,7 @@
|
||||
tuxedo-infinitybook-pro14-gen7 = import ./tuxedo/infinitybook/pro14/gen7;
|
||||
tuxedo-pulse-14-gen3 = import ./tuxedo/pulse/14/gen3;
|
||||
tuxedo-pulse-15-gen2 = import ./tuxedo/pulse/15/gen2;
|
||||
xiaomi-redmibook-16-pro-2024 = import ./xiaomi/redmibook/16-pro-2024;
|
||||
|
||||
common-cpu-amd = import ./common/cpu/amd;
|
||||
common-cpu-amd-pstate = import ./common/cpu/amd/pstate.nix;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{ lib, pkgs, ... }:
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
@@ -9,4 +9,29 @@
|
||||
# Need at least 6.9 to make suspend properly
|
||||
# Specifically this patch: https://github.com/torvalds/linux/commit/073237281a508ac80ec025872ad7de50cfb5a28a
|
||||
boot.kernelPackages = lib.mkIf (lib.versionOlder pkgs.linux.version "6.9") (lib.mkDefault pkgs.linuxPackages_latest);
|
||||
|
||||
# Intel NPU Driver
|
||||
# https://discourse.nixos.org/t/new-installation-on-asus-zenbook-ux5406-intel-vpu-firmware-error-2/58732/2
|
||||
hardware.firmware = lib.optionals (config.hardware.enableRedistributableFirmware) [
|
||||
(
|
||||
let
|
||||
model = "37xx";
|
||||
version = "0.0";
|
||||
|
||||
firmware = pkgs.fetchurl {
|
||||
url = "https://github.com/intel/linux-npu-driver/raw/v1.13.0/firmware/bin/vpu_${model}_v${version}.bin";
|
||||
hash = "sha256-Mpoeq8HrwChjtHALsss/7QsFtDYAoFNsnhllU0xp3os=";
|
||||
};
|
||||
in
|
||||
pkgs.runCommand "intel-vpu-firmware-${model}-${version}" { } ''
|
||||
mkdir -p "$out/lib/firmware/intel/vpu"
|
||||
cp '${firmware}' "$out/lib/firmware/intel/vpu/vpu_${model}_v${version}.bin"
|
||||
''
|
||||
)
|
||||
];
|
||||
|
||||
warnings = lib.mkIf (!config.hardware.enableRedistributableFirmware) [
|
||||
''For Intel NPU support, set the option: hardware.enableRedistributableFirmware = true;''
|
||||
];
|
||||
|
||||
}
|
||||
@@ -51,6 +51,17 @@ For the Framework 13 laptops, there are common configuration modules available u
|
||||
including some modules specific to AMD- or Intel-based laptops. By preference, there will already be a specialised
|
||||
module for your model's configuration. Otherwise, it can be added alongside the existing modules.
|
||||
|
||||
## OS integration
|
||||
|
||||
`hardware.framework.enableKmod` enables the [community-created Framework kernel
|
||||
module](https://github.com/DHowett/framework-laptop-kmod) which exposes EC functionality like battery charge limit,
|
||||
privacy switches, and system LEDs as standard driver interfaces. This enables, for example, configuring the charge limit
|
||||
using the KDE settings GUI. The option is enabled by default when NixOS `>= 24.05` and linux kernel version `>= 6.10`.
|
||||
|
||||
On AMD Framework 13 and 16, before kernel 6.10, additional kernel patches are required for the kernel module to function
|
||||
properly. Manually setting `hardware.framework.enableKmod = true` will apply the patches, requiring a kernel
|
||||
recompilation.
|
||||
|
||||
## Support Tools
|
||||
|
||||
### fw-ectool
|
||||
|
||||
+35
-9
@@ -1,17 +1,43 @@
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
options.hardware.framework.enableKmod = lib.mkEnableOption
|
||||
{ config, lib, pkgs, ... }:
|
||||
let
|
||||
kernel_version_compatible = lib.versionAtLeast config.boot.kernelPackages.kernel.version "6.10";
|
||||
in {
|
||||
options.hardware.framework.enableKmod = (lib.mkEnableOption
|
||||
"Enable the community created Framework kernel module that allows interacting with the embedded controller from sysfs."
|
||||
// {
|
||||
# Enable by default if on new enough version of NixOS
|
||||
default = (lib.versionAtLeast (lib.versions.majorMinor lib.version) "24.05");
|
||||
) // {
|
||||
# enable by default on NixOS >= 24.05 and kernel >= 6.10
|
||||
default = lib.and
|
||||
(lib.versionAtLeast (lib.versions.majorMinor lib.version) "24.05")
|
||||
kernel_version_compatible;
|
||||
defaultText = "enabled by default on NixOS >= 24.05 and kernel >= 6.10";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.hardware.framework.enableKmod {
|
||||
boot.extraModulePackages = with config.boot.kernelPackages; [
|
||||
|
||||
config.boot = lib.mkIf config.hardware.framework.enableKmod {
|
||||
extraModulePackages = with config.boot.kernelPackages; [
|
||||
framework-laptop-kmod
|
||||
];
|
||||
|
||||
# https://github.com/DHowett/framework-laptop-kmod?tab=readme-ov-file#usage
|
||||
boot.kernelModules = [ "cros_ec" "cros_ec_lpcs" ];
|
||||
kernelModules = [ "cros_ec" "cros_ec_lpcs" ];
|
||||
|
||||
# add required patch if enabled on kernel <6.10
|
||||
kernelPatches = lib.mkIf (!kernel_version_compatible) [
|
||||
rec {
|
||||
name = "platform/chrome: cros_ec_lpc: add support for AMD Framework Laptops";
|
||||
msgid = "20240403004713.130365-1-dustin@howett.net";
|
||||
version = "3";
|
||||
hash = "sha256-aQSyys8CMzlj9EdNhg8vtp76fg1qEwUVeJL0E+8w5HU=";
|
||||
patch = pkgs.runCommandLocal "patch-${msgid}" {
|
||||
nativeBuildInputs = with pkgs; [ b4 git cacert ];
|
||||
SSL_CERT_FILE = "${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt";
|
||||
|
||||
outputHash = hash;
|
||||
} ''
|
||||
export HOME="$TMP"
|
||||
PYTHONHASHSEED=0 ${pkgs.b4}/bin/b4 -n am -C -T -v ${version} -o- "${msgid}" > "$out"
|
||||
'';
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -6,8 +6,3 @@ bug where the PC will wakeup immediately after going into suspend.
|
||||
## Affects at least
|
||||
|
||||
- Gigabyte B650M Aorus Elite AX (Rev. 1.3) (BIOS Version F32b)
|
||||
- Can not be fixed by modifying enabled entries in /proc/acpi/wakeup.
|
||||
Computer wakes up even if all enabled entries are disabled. Therefore, no
|
||||
fix exist currently.
|
||||
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
# see https://bbs.archlinux.org/viewtopic.php?pid=2227023
|
||||
boot.kernelParams = [
|
||||
"acpi_osi=\"!Windows 2015\""
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
imports = [
|
||||
./b650-fix-suspend.nix
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
{ lib, pkgs, ... }:
|
||||
let inherit (lib) mkIf mkDefault;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
../../common/pc/laptop
|
||||
../../common/pc/laptop/ssd
|
||||
../../common/cpu/amd
|
||||
../../common/cpu/amd/pstate.nix
|
||||
../../common/gpu/amd
|
||||
../../common/hidpi.nix
|
||||
];
|
||||
|
||||
boot = {
|
||||
# As of kernel version 6.6.72, amdgpu throws a fatal error during init, resulting in a barely-working display
|
||||
kernelPackages = mkIf (lib.versionOlder pkgs.linux.version "6.12") pkgs.linuxPackages_latest;
|
||||
|
||||
kernelParams = [
|
||||
# The GPD Pocket 4 uses a tablet LTPS display, that is mounted rotated 90° counter-clockwise
|
||||
"fbcon=rotate:1" "video=eDP-1:panel_orientation=right_side_up"
|
||||
];
|
||||
};
|
||||
|
||||
fonts.fontconfig = {
|
||||
subpixel.rgba = "vbgr"; # Pixel order for rotated screen
|
||||
|
||||
# The display has √(2560² + 1600²) px / 8.8in ≃ 343 dpi
|
||||
# Per the documentation, antialiasing, hinting, etc. have no visible effect at such high pixel densities anyhow.
|
||||
hinting.enable = mkDefault false;
|
||||
};
|
||||
|
||||
# More HiDPI settings
|
||||
services.xserver.dpi = 343;
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
imports = [
|
||||
../../common/cpu/intel/alder-lake
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
{ config, lib, ... }:
|
||||
|
||||
{
|
||||
# https://www.intel.com/content/www/us/en/products/sku/124967/intel-core-i58250u-processor-6m-cache-up-to-3-40-ghz/specifications.html
|
||||
# this one works: https://nixos.wiki/wiki/Accelerated_Video_Playback
|
||||
imports = [
|
||||
../../../common/cpu/intel/kaby-lake
|
||||
../../../common/pc
|
||||
../../../common/pc/laptop
|
||||
../../../common/pc/laptop/ssd
|
||||
];
|
||||
|
||||
config = {
|
||||
services.thermald.enable = lib.mkDefault true;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
# Lenovo IdeaCentre K330
|
||||
|
||||
The specific system I took for reference has the following hardware configuration:
|
||||
|
||||
- Intel Core i7 2600
|
||||
- NVIDIA GeForce GT 545 [Latest supported (proprietary) driver (390.xx)](https://www.nvidia.com/en-us/drivers/details/196213/)
|
||||
- Some SSD (originally had a Seagate Barracuda hard drive)
|
||||
|
||||
This hardware configuration was motivated by #1297
|
||||
|
||||
I recommend enabling xserver instead of trying to use Wayland. As documented in the above linked issue, using Wayland with this rather old hardware lead to the system freezing after a short time of operation.
|
||||
|
||||
```nix
|
||||
{
|
||||
services.xserver.enable = true;
|
||||
}
|
||||
```
|
||||
@@ -0,0 +1,19 @@
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
imports = [
|
||||
../../../common/cpu/intel
|
||||
../../../common/gpu/nvidia # Is it possible/advisable to pin this to the 390.xx driver family in case the user wants to use non-free drivers?
|
||||
../../../common/gpu/amd # The K330 could be bought with AMD GPUs but I don't have that configuration
|
||||
../../../common/pc
|
||||
];
|
||||
|
||||
# On my machine Wayland causes the desktop to freeze after a short time of operation
|
||||
services.displayManager.sddm.wayland.enable = false;
|
||||
|
||||
# Should this be a conditional default in case plasma is activated?
|
||||
# What if somebody installs both plasma AND another DE?
|
||||
# The goal is to prefer x11 over wayland due to compatibility issues with the old hardware
|
||||
|
||||
|
||||
services.displayManager.defaultSession = lib.mkIf config.services.xserver.desktopManager.plasma6.enable (lib.mkDefault "plasmax11");
|
||||
}
|
||||
@@ -9,6 +9,12 @@ When using more than one drive, the value of `hardware.nvidia.prime.amdgpuBusId`
|
||||
|
||||
Make sure you override this default in your personal configuration. For two drives, it should be `PCI:6:0:0`.
|
||||
|
||||
## Using and troubleshooting power profiles (hybrid-only)
|
||||
|
||||
Power profile support (cycled via Fn + Q) is provided by `nvidia-powerd`.
|
||||
Should you encounter issues with the `nvidia-powerd` daemon,
|
||||
override the value of `hardware.nvidia.dynamicBoost.enable` to `false` in your personal configuration (and consider creating an issue if one does not exist).
|
||||
|
||||
## Setup at the time of testing
|
||||
```
|
||||
$ nix-info -m
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
nvidia = {
|
||||
modesetting.enable = lib.mkDefault true;
|
||||
powerManagement.enable = lib.mkDefault true;
|
||||
dynamicBoost.enable = lib.mkDefault true;
|
||||
|
||||
prime = {
|
||||
amdgpuBusId = lib.mkDefault "PCI:5:0:0";
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
{
|
||||
imports = [
|
||||
../.
|
||||
../../../../common/cpu/amd
|
||||
../../../../common/gpu/amd
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
imports = [
|
||||
../.
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
imports = [
|
||||
../.
|
||||
../../../common/pc/laptop/ssd
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{lib, ...}: {
|
||||
imports = [
|
||||
../../../common/cpu/intel
|
||||
../../../common/pc/ssd
|
||||
../.
|
||||
];
|
||||
|
||||
services.throttled.enable = lib.mkDefault true;
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
{ pkgs, lib, ...}:
|
||||
{ pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
@@ -7,10 +7,15 @@
|
||||
|
||||
environment.etc."asound.conf".source = ./asound.conf;
|
||||
|
||||
networking.networkmanager.fccUnlockScripts = [
|
||||
{
|
||||
id = "2c7c:030a";
|
||||
path = "${pkgs.modemmanager}/share/ModemManager/fcc-unlock.available.d/2c7c:030a";
|
||||
}
|
||||
];
|
||||
networking =
|
||||
let
|
||||
fcc_unlock_script = rec {
|
||||
id = "2c7c:030a";
|
||||
path = "${pkgs.modemmanager}/share/ModemManager/fcc-unlock.available.d/${id}";
|
||||
};
|
||||
in
|
||||
if lib.versionOlder lib.version "25.05pre" then
|
||||
{ networkmanager.fccUnlockScripts = [ fcc_unlock_script ]; }
|
||||
else
|
||||
{ modemmanager.fccUnlockScripts = [ fcc_unlock_script ]; };
|
||||
}
|
||||
@@ -7,14 +7,14 @@ let
|
||||
|
||||
cfg = config.microsoft-surface;
|
||||
|
||||
version = "6.12.8";
|
||||
version = "6.12.17";
|
||||
kernelPatches = surfacePatches {
|
||||
inherit version;
|
||||
patchFn = ./patches.nix;
|
||||
};
|
||||
kernelPackages = linuxPackage {
|
||||
inherit version kernelPatches;
|
||||
sha256 = "sha256-IpHaBlygS3Fcie5QNirsPwIadBS8lj8bVnNmgsgSKXk=";
|
||||
sha256 = "sha256-XCBc00+Al05Jc+MhywCPX2iVqKqMJXfwapRIzXfeY7M=";
|
||||
ignoreConfigErrors=true;
|
||||
};
|
||||
|
||||
|
||||
@@ -1,49 +1,57 @@
|
||||
{ pkgs, ... } @ args:
|
||||
{ pkgs, ... }@args:
|
||||
|
||||
with pkgs;
|
||||
|
||||
buildLinux (args // rec {
|
||||
version = "5.15.71";
|
||||
buildLinux (
|
||||
args
|
||||
// rec {
|
||||
version = "5.15.71";
|
||||
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = version;
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = version;
|
||||
|
||||
defconfig = "imx_v8_defconfig";
|
||||
defconfig = "imx_v8_defconfig";
|
||||
|
||||
kernelPatches = [
|
||||
];
|
||||
# https://github.com/NixOS/nixpkgs/pull/366004
|
||||
# introduced a breaking change that if a module is declared but it is not being used it will fail.
|
||||
ignoreConfigErrors = true;
|
||||
|
||||
autoModules = false;
|
||||
kernelPatches = [
|
||||
];
|
||||
|
||||
extraConfig = ''
|
||||
CRYPTO_TLS m
|
||||
TLS y
|
||||
MD_RAID0 m
|
||||
MD_RAID1 m
|
||||
MD_RAID10 m
|
||||
MD_RAID456 m
|
||||
DM_VERITY m
|
||||
LOGO y
|
||||
FRAMEBUFFER_CONSOLE_DEFERRED_TAKEOVER n
|
||||
FB_EFI n
|
||||
EFI_STUB y
|
||||
EFI y
|
||||
VIRTIO y
|
||||
VIRTIO_PCI y
|
||||
VIRTIO_BLK y
|
||||
DRM_VIRTIO_GPU y
|
||||
EXT4_FS y
|
||||
USBIP_CORE m
|
||||
USBIP_VHCI_HCD m
|
||||
USBIP_HOST m
|
||||
USBIP_VUDC m
|
||||
'';
|
||||
autoModules = false;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "nxp-imx";
|
||||
repo = "linux-imx";
|
||||
# tag: refs/tags/lf-5.15.71-2.2.0
|
||||
rev = "3313732e9984cb8a6b10a9085c7e18d58e770d56";
|
||||
sha256 = "sha256-PBRiSgjPOq4keiwPOfNOswf1Zzdbn6YOjpOgv4/Oscc=";
|
||||
};
|
||||
} // (args.argsOverride or { }))
|
||||
extraConfig = ''
|
||||
CRYPTO_TLS m
|
||||
TLS y
|
||||
MD_RAID0 m
|
||||
MD_RAID1 m
|
||||
MD_RAID10 m
|
||||
MD_RAID456 m
|
||||
DM_VERITY m
|
||||
LOGO y
|
||||
FRAMEBUFFER_CONSOLE_DEFERRED_TAKEOVER n
|
||||
FB_EFI n
|
||||
EFI_STUB y
|
||||
EFI y
|
||||
VIRTIO y
|
||||
VIRTIO_PCI y
|
||||
VIRTIO_BLK y
|
||||
DRM_VIRTIO_GPU y
|
||||
EXT4_FS y
|
||||
USBIP_CORE m
|
||||
USBIP_VHCI_HCD m
|
||||
USBIP_HOST m
|
||||
USBIP_VUDC m
|
||||
'';
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "nxp-imx";
|
||||
repo = "linux-imx";
|
||||
# tag: refs/tags/lf-5.15.71-2.2.0
|
||||
rev = "3313732e9984cb8a6b10a9085c7e18d58e770d56";
|
||||
sha256 = "sha256-PBRiSgjPOq4keiwPOfNOswf1Zzdbn6YOjpOgv4/Oscc=";
|
||||
};
|
||||
}
|
||||
// (args.argsOverride or { })
|
||||
)
|
||||
@@ -1,50 +1,56 @@
|
||||
{pkgs, ...} @ args:
|
||||
{ pkgs, ... }@args:
|
||||
with pkgs;
|
||||
buildLinux (args
|
||||
// rec {
|
||||
version = "6.1.55";
|
||||
name = "imx8mp-linux";
|
||||
buildLinux (
|
||||
args
|
||||
// rec {
|
||||
version = "6.1.55";
|
||||
name = "imx8mp-linux";
|
||||
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = version;
|
||||
# modDirVersion needs to be x.y.z, will automatically add .0 if needed
|
||||
modDirVersion = version;
|
||||
|
||||
defconfig = "imx_v8_defconfig";
|
||||
defconfig = "imx_v8_defconfig";
|
||||
|
||||
kernelPatches = [
|
||||
];
|
||||
# https://github.com/NixOS/nixpkgs/pull/366004
|
||||
# introduced a breaking change that if a module is declared but it is not being used it will faill.
|
||||
ignoreConfigErrors = true;
|
||||
|
||||
autoModules = false;
|
||||
kernelPatches = [
|
||||
];
|
||||
|
||||
extraConfig = ''
|
||||
CRYPTO_TLS m
|
||||
TLS y
|
||||
MD_RAID0 m
|
||||
MD_RAID1 m
|
||||
MD_RAID10 m
|
||||
MD_RAID456 m
|
||||
DM_VERITY m
|
||||
LOGO y
|
||||
FRAMEBUFFER_CONSOLE_DEFERRED_TAKEOVER n
|
||||
FB_EFI n
|
||||
EFI_STUB y
|
||||
EFI y
|
||||
VIRTIO y
|
||||
VIRTIO_PCI y
|
||||
VIRTIO_BLK y
|
||||
DRM_VIRTIO_GPU y
|
||||
EXT4_FS y
|
||||
USBIP_CORE m
|
||||
USBIP_VHCI_HCD m
|
||||
USBIP_HOST m
|
||||
USBIP_VUDC m
|
||||
'';
|
||||
autoModules = false;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "nxp-imx";
|
||||
repo = "linux-imx";
|
||||
# tag: lf-6.1.55-2.2.0
|
||||
rev = "770c5fe2c1d1529fae21b7043911cd50c6cf087e";
|
||||
sha256 = "sha256-tIWt75RUrjB6KmUuAYBVyAC1dmVGSUAgqV5ROJh3xU0=";
|
||||
};
|
||||
}
|
||||
// (args.argsOverride or {}))
|
||||
extraConfig = ''
|
||||
CRYPTO_TLS m
|
||||
TLS y
|
||||
MD_RAID0 m
|
||||
MD_RAID1 m
|
||||
MD_RAID10 m
|
||||
MD_RAID456 m
|
||||
DM_VERITY m
|
||||
LOGO y
|
||||
FRAMEBUFFER_CONSOLE_DEFERRED_TAKEOVER n
|
||||
FB_EFI n
|
||||
EFI_STUB y
|
||||
EFI y
|
||||
VIRTIO y
|
||||
VIRTIO_PCI y
|
||||
VIRTIO_BLK y
|
||||
DRM_VIRTIO_GPU y
|
||||
EXT4_FS y
|
||||
USBIP_CORE m
|
||||
USBIP_VHCI_HCD m
|
||||
USBIP_HOST m
|
||||
USBIP_VUDC m
|
||||
'';
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "nxp-imx";
|
||||
repo = "linux-imx";
|
||||
# tag: lf-6.1.55-2.2.0
|
||||
rev = "770c5fe2c1d1529fae21b7043911cd50c6cf087e";
|
||||
sha256 = "sha256-tIWt75RUrjB6KmUuAYBVyAC1dmVGSUAgqV5ROJh3xU0=";
|
||||
};
|
||||
}
|
||||
// (args.argsOverride or { })
|
||||
)
|
||||
@@ -10,6 +10,10 @@ with pkgs;
|
||||
|
||||
defconfig = "imx_v8_defconfig";
|
||||
|
||||
# https://github.com/NixOS/nixpkgs/pull/366004
|
||||
# introduced a breaking change that if a module is declared but it is not being used it will faill.
|
||||
ignoreConfigErrors = true;
|
||||
|
||||
kernelPatches = [
|
||||
];
|
||||
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
# HP Omen 15-ce002ns
|
||||
|
||||
Profile for the following laptop: https://support.hp.com/us-en/document/c05552952
|
||||
|
||||
```bash
|
||||
$ lspci -nn
|
||||
00:00.0 Host bridge [0600]: Intel Corporation Xeon E3-1200 v6/7th Gen Core Processor Host Bridge/DRAM Registers [8086:5910] (rev 05)
|
||||
00:01.0 PCI bridge [0604]: Intel Corporation 6th-10th Gen Core Processor PCIe Controller (x16) [8086:1901] (rev 05)
|
||||
00:04.0 Signal processing controller [1180]: Intel Corporation Xeon E3-1200 v5/E3-1500 v5/6th Gen Core Processor Thermal Subsystem [8086:1903] (rev 05)
|
||||
00:14.0 USB controller [0c03]: Intel Corporation 100 Series/C230 Series Chipset Family USB 3.0 xHCI Controller [8086:a12f] (rev 31)
|
||||
00:14.2 Signal processing controller [1180]: Intel Corporation 100 Series/C230 Series Chipset Family Thermal Subsystem [8086:a131] (rev 31)
|
||||
00:15.0 Signal processing controller [1180]: Intel Corporation 100 Series/C230 Series Chipset Family Serial IO I2C Controller #0 [8086:a160] (rev 31)
|
||||
00:16.0 Communication controller [0780]: Intel Corporation 100 Series/C230 Series Chipset Family MEI Controller #1 [8086:a13a] (rev 31)
|
||||
00:17.0 SATA controller [0106]: Intel Corporation HM170/QM170 Chipset SATA Controller [AHCI Mode] [8086:a103] (rev 31)
|
||||
00:1c.0 PCI bridge [0604]: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #1 [8086:a110] (rev f1)
|
||||
00:1c.4 PCI bridge [0604]: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #5 [8086:a114] (rev f1)
|
||||
00:1c.5 PCI bridge [0604]: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #6 [8086:a115] (rev f1)
|
||||
00:1c.6 PCI bridge [0604]: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #7 [8086:a116] (rev f1)
|
||||
00:1d.0 PCI bridge [0604]: Intel Corporation 100 Series/C230 Series Chipset Family PCI Express Root Port #9 [8086:a118] (rev f1)
|
||||
00:1f.0 ISA bridge [0601]: Intel Corporation HM175 Chipset LPC/eSPI Controller [8086:a152] (rev 31)
|
||||
00:1f.2 Memory controller [0580]: Intel Corporation 100 Series/C230 Series Chipset Family Power Management Controller [8086:a121] (rev 31)
|
||||
00:1f.3 Audio device [0403]: Intel Corporation CM238 HD Audio Controller [8086:a171] (rev 31)
|
||||
00:1f.4 SMBus [0c05]: Intel Corporation 100 Series/C230 Series Chipset Family SMBus [8086:a123] (rev 31)
|
||||
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GP106BM [GeForce GTX 1060 Mobile 6GB] [10de:1c60] (rev a1)
|
||||
01:00.1 Audio device [0403]: NVIDIA Corporation GP106 High Definition Audio Controller [10de:10f1] (rev a1)
|
||||
3b:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL8111/8168/8211/8411 PCI Express Gigabit Ethernet Controller [10ec:8168] (rev 16)
|
||||
3c:00.0 Network controller [0280]: Intel Corporation Wireless 7265 [8086:095a] (rev 61)
|
||||
3d:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS522A PCI Express Card Reader [10ec:522a] (rev 01)
|
||||
3e:00.0 Non-Volatile memory controller [0108]: Samsung Electronics Co Ltd NVMe SSD Controller SM961/PM961/SM963 [144d:a804]
|
||||
```
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
{ lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../common/cpu/intel/kaby-lake
|
||||
../../common/gpu/nvidia/pascal
|
||||
../../common/pc/laptop
|
||||
../../common/pc/laptop/ssd
|
||||
../../common/pc/laptop/hdd
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
--- orig.patch 2025-01-23 19:34:37.216154507 +0100
|
||||
+++ updated-6.12.patch 2025-01-23 19:36:28.316333973 +0100
|
||||
@@ -11,10 +11,10 @@
|
||||
#define MT_QUIRK_NOT_SEEN_MEANS_UP BIT(0)
|
||||
#define MT_QUIRK_SLOT_IS_CONTACTID BIT(1)
|
||||
@@ -70,6 +73,7 @@
|
||||
- #define MT_QUIRK_WIN8_PTP_BUTTONS BIT(18)
|
||||
- #define MT_QUIRK_SEPARATE_APP_REPORT BIT(19)
|
||||
#define MT_QUIRK_FORCE_MULTI_INPUT BIT(20)
|
||||
-+#define MT_QUIRK_NON_MT_PEN BIT(21)
|
||||
+ #define MT_QUIRK_DISABLE_WAKEUP BIT(21)
|
||||
+ #define MT_QUIRK_ORIENTATION_INVERT BIT(22)
|
||||
++#define MT_QUIRK_NON_MT_PEN BIT(23)
|
||||
|
||||
#define MT_INPUTMODE_TOUCHSCREEN 0x02
|
||||
#define MT_INPUTMODE_TOUCHPAD 0x03
|
||||
@@ -41,9 +41,9 @@
|
||||
#define MT_CLS_RAZER_BLADE_STEALTH 0x0112
|
||||
#define MT_CLS_SMART_TECH 0x0113
|
||||
+#define MT_CLS_NON_MT_PEN 0x0114
|
||||
+ #define MT_CLS_SIS 0x0457
|
||||
|
||||
#define MT_DEFAULT_MAXCONTACT 10
|
||||
- #define MT_MAX_MAXCONTACT 250
|
||||
@@ -374,6 +383,9 @@
|
||||
MT_QUIRK_CONTACT_CNT_ACCURATE |
|
||||
MT_QUIRK_SEPARATE_APP_REPORT,
|
||||
@@ -18,8 +18,16 @@ let
|
||||
cat ${patch1_original} > $out
|
||||
${patch}/bin/patch $out < ${./6.1.patch.patch}
|
||||
'';
|
||||
patch1_updated_6_12 = runCommand
|
||||
"goodix-stylus-mastykin-1-pen-support-6.12.patch" {}
|
||||
''
|
||||
cat ${patch1_original} > $out
|
||||
${patch}/bin/patch $out < ${./6.12.patch.patch}
|
||||
'';
|
||||
patch1 =
|
||||
if (lib.versionAtLeast kernel.version "6.1") then
|
||||
if (lib.versionAtLeast kernel.version "6.12") then
|
||||
patch1_updated_6_12
|
||||
else if (lib.versionAtLeast kernel.version "6.1") then
|
||||
patch1_updated_6_1
|
||||
else if (lib.versionAtLeast kernel.version "5.12.12") then
|
||||
patch1_updated_5_12_12
|
||||
|
||||
+40
-17
@@ -1,18 +1,41 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
{
|
||||
config = lib.mkIf config.hardware.librem5.audio {
|
||||
assertions = [{
|
||||
assertion = config.hardware.pulseaudio.enable;
|
||||
message = "Call audio on Librem5 requires pulse audio to be enabled through `hardware.pulseaudio.enable`.";
|
||||
}];
|
||||
hardware.pulseaudio = {
|
||||
enable = true;
|
||||
# this is required to correctly configure the modem as PA source/sink
|
||||
extraConfig = ''
|
||||
.include ${config.hardware.librem5.package}/etc/pulse/librem5.pa
|
||||
'';
|
||||
};
|
||||
|
||||
services.dbus.packages = [ pkgs.callaudiod ];
|
||||
};
|
||||
{ config
|
||||
, lib
|
||||
, pkgs
|
||||
, ...
|
||||
}: {
|
||||
config =
|
||||
lib.mkIf config.hardware.librem5.audio
|
||||
{
|
||||
services.dbus.packages = [ pkgs.callaudiod ];
|
||||
}
|
||||
// (
|
||||
let
|
||||
paConfig = {
|
||||
enable = true;
|
||||
# this is required to correctly configure the modem as PA source/sink
|
||||
extraConfig = ''
|
||||
.include ${config.hardware.librem5.package}/etc/pulse/librem5.pa
|
||||
'';
|
||||
};
|
||||
in
|
||||
if lib.versionOlder (lib.versions.majorMinor lib.version) "25.05"
|
||||
then {
|
||||
assertions = [
|
||||
{
|
||||
assertion = config.hardware.pulseaudio.enable;
|
||||
message = "Call audio on Librem5 requires pulse audio to be enabled through `hardware.pulseaudio.enable`.";
|
||||
}
|
||||
];
|
||||
hardware.pulseaudio = paConfig;
|
||||
}
|
||||
else {
|
||||
assertions = [
|
||||
{
|
||||
assertion = config.services.pulseaudio.enable;
|
||||
message = "Call audio on Librem5 requires pulse audio to be enabled through `services.pulseaudio.enable`.";
|
||||
}
|
||||
];
|
||||
services.pulseaudio = paConfig;
|
||||
}
|
||||
);
|
||||
}
|
||||
@@ -6,16 +6,19 @@
|
||||
buildLinux (args
|
||||
// rec {
|
||||
defconfig = "librem5_defconfig";
|
||||
version = "6.6.29-librem5";
|
||||
version = "6.6.74-librem5";
|
||||
modDirVersion = version;
|
||||
src = fetchFromGitLab {
|
||||
domain = "source.puri.sm";
|
||||
owner = "Librem5";
|
||||
repo = "linux";
|
||||
rev = "pureos/6.6.29pureos1";
|
||||
hash = "sha256-i8HSAJ1/Z2Ux2s3Srse+L0S1Zd/70ldpGBhIgEZ6nBw=";
|
||||
rev = "pureos/6.6.74pureos1";
|
||||
hash = "sha256-qUPY+2fHVu7SFc+Uf8U7QtkQJJsE/4I1SavpLqJ/34c=";
|
||||
};
|
||||
kernelPatches = [ ];
|
||||
# see https://github.com/NixOS/nixpkgs/pull/366004
|
||||
ignoreConfigErrors = true;
|
||||
|
||||
structuredExtraConfig = with lib.kernel; {
|
||||
# buildLinux overrides this and defaults to 32, so go back to the value defined librem5_defconfig
|
||||
# this is required for millipixels to take photos, otherwise the VIDIOC_REQ_BUFS ioctl returns ENOMEM
|
||||
|
||||
+112
@@ -0,0 +1,112 @@
|
||||
# NixOS support for Radxa devices
|
||||
|
||||
Radxa provides the NixOS implementation in the form of `nixos-hardware` modules
|
||||
for advanced users.
|
||||
|
||||
Our goals are:
|
||||
|
||||
* Only use `nixpkgs` provided packages.
|
||||
* Provide a consistent and simple experience to use our NixOS module.
|
||||
* Targetted audiences are advanced users who care mostly about CPU compute, storage, and network.
|
||||
* No support guarantee. We are not here to teach people how to use NixOS.
|
||||
|
||||
We explicitly want to avoid packaging the entire vendor SDK bootloader and kernel
|
||||
in Nix. Those are not going to be accepted in `nixpkgs`, and our targetted audiences
|
||||
like homelabbers generally ignore the additional hardware features.
|
||||
|
||||
This also aligns with [NixOS on ARM](https://wiki.nixos.org/wiki/NixOS_on_ARM)'s
|
||||
definition of "support":
|
||||
|
||||
> Support for those board assumes as much is supported as Mainline Linux supports.
|
||||
|
||||
## Characteristic of the default profiles
|
||||
|
||||
* Using `linuxPackages_latest`
|
||||
* `bcachefs` rootfs with zstd compression and password-less encryption enabled
|
||||
* EFI boot chain provided by `systemd-boot`
|
||||
* Default serial console enabled with baud rate matches the platform firmware
|
||||
* No automatic partition expansion, as the module is only focusing on hardware
|
||||
|
||||
## Common Nix flake pattern
|
||||
|
||||
Below is an annoated flake example to create the initial boot image.
|
||||
|
||||
```
|
||||
{
|
||||
description = "Example NixOS configurations for Radxa product";
|
||||
# To build, run `nix build .#nixosConfigurations.radxa.config.system.build.diskoImages`
|
||||
|
||||
inputs = {
|
||||
disko.url = "github:nix-community/disko";
|
||||
disko.inputs.nixpkgs.follows = "nixpkgs";
|
||||
nixos-hardware.url = "github:NixOS/nixos-hardware";
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.11";
|
||||
nixpkgs-unfree.url = "github:numtide/nixpkgs-unfree/nixos-unstable";
|
||||
};
|
||||
|
||||
outputs = inputs@{
|
||||
self,
|
||||
disko,
|
||||
nixos-hardware,
|
||||
nixpkgs,
|
||||
nixpkgs-unfree,
|
||||
}: {
|
||||
nixosConfigurations = {
|
||||
radxa = nixpkgs.lib.nixosSystem {
|
||||
specialArgs = { inherit inputs; };
|
||||
system = "aarch64-linux";
|
||||
modules = [
|
||||
nixos-hardware.nixosModules.rock-4c-plus # Update the system according to your device.
|
||||
|
||||
# Or, if the default platform firmware is not available in the NixOS version you are using:
|
||||
# (import nixos-hardware.nixosModules.rock-pi-e {
|
||||
# lib = nixpkgs-unfree.lib;
|
||||
# config = nixpkgs-unfree.config;
|
||||
# pkgs = nixpkgs-unfree.legacyPackages.aarch64-linux;
|
||||
# })
|
||||
|
||||
disko.nixosModules.disko # disko usage is optional in the running system, but we need it to generate the initial boot image.
|
||||
"${nixos-hardware}/radxa/disko.nix" # Common Radxa Disko profile. It is system-agnostic.
|
||||
{
|
||||
disko = {
|
||||
imageBuilder = {
|
||||
# Avoid double emulation to significantly speed up image building process.
|
||||
# Update the system according to your host system.
|
||||
# See https://github.com/nix-community/disko/issues/856
|
||||
qemu = nixpkgs.legacyPackages.x86_64-linux.qemu + "/bin/qemu-system-aarch64 -M virt -cpu cortex-a57";
|
||||
};
|
||||
# Default image size is 2G for a small basic CLI system.
|
||||
# devices.disk.main.imageSize = "2G";
|
||||
};
|
||||
|
||||
# Override the default bootloader with a cross built one.
|
||||
# Use this if you do not have binfmt configured on your system.
|
||||
# For NixOS, please add `boot.binfmt.emulatedSystems = [ "aarch64-linux" ];` to your system configuration.
|
||||
# Read the device module to see how it was configured.
|
||||
# hardware.rockchip.platformFirmware = nixpkgs-unfree.legacyPackages.x86_64-linux.pkgsCross.aarch64-multiplatform.ubootRock4CPlus;
|
||||
|
||||
users.users.radxa = {
|
||||
isNormalUser = true;
|
||||
initialPassword = "radxa";
|
||||
extraGroups = [ "wheel" ];
|
||||
};
|
||||
services.openssh.enable = true;
|
||||
networking.hostName = "radxa";
|
||||
system.stateVersion = "24.11";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
```
|
||||
|
||||
For most of the supported products, you only need to change the device module (
|
||||
i.e. `nixos-hardware.nixosModules.rock-4c-plus`) to match the one you are using.
|
||||
|
||||
## Known issues
|
||||
|
||||
* Currently, the `hardware.radxa` module and Radxa-maintained SoC vendor modules
|
||||
(eg. `hardware.rockchip`) are tightly coupled and not intended for end-user to
|
||||
use. Those options are currently used internally for hardware enablement, and
|
||||
end-user should not need to modify them. Consider those interfaces **unstable**.
|
||||
@@ -0,0 +1,23 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
cfg = config.hardware.radxa;
|
||||
in {
|
||||
options.hardware.radxa = {
|
||||
enable = lib.mkEnableOption "Radxa system support";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
boot = {
|
||||
# Currently enable bcachefs automatically set
|
||||
# kernelPackages = lib.mkDefault pkgs.linuxPackages_latest;
|
||||
# TODO: Consider removing this line once, we get an LTS kernel that is newer than 6.12
|
||||
kernelPackages = lib.mkOverride 990 pkgs.linuxPackages_latest;
|
||||
supportedFilesystems = [ "bcachefs" ];
|
||||
loader.systemd-boot.enable = lib.mkDefault true;
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
cfg = config.hardware.radxa;
|
||||
in {
|
||||
imports = [
|
||||
../rockchip/disko.nix
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}: {
|
||||
imports = [
|
||||
../.
|
||||
../../rockchip
|
||||
];
|
||||
|
||||
config = {
|
||||
hardware = {
|
||||
radxa.enable = true;
|
||||
rockchip = {
|
||||
rk3399.enable = true;
|
||||
platformFirmware = lib.mkDefault pkgs.ubootRock4CPlus;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}: {
|
||||
imports = [
|
||||
../.
|
||||
../../rockchip
|
||||
];
|
||||
|
||||
config = {
|
||||
hardware = {
|
||||
radxa.enable = true;
|
||||
rockchip = {
|
||||
rk3588.enable = true;
|
||||
platformFirmware = lib.mkDefault pkgs.ubootRock5ModelB;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}: {
|
||||
imports = [
|
||||
../.
|
||||
../../rockchip
|
||||
];
|
||||
|
||||
config = {
|
||||
hardware = {
|
||||
radxa.enable = true;
|
||||
rockchip = {
|
||||
rk3399.enable = true;
|
||||
platformFirmware = lib.mkDefault pkgs.ubootRockPi4;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}: {
|
||||
imports = [
|
||||
../.
|
||||
../../rockchip
|
||||
];
|
||||
|
||||
config = {
|
||||
hardware = {
|
||||
radxa.enable = true;
|
||||
rockchip = {
|
||||
rk3328.enable = true;
|
||||
platformFirmware = lib.mkDefault pkgs.ubootRockPiE;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -13,10 +13,7 @@
|
||||
loader = {
|
||||
grub.enable = lib.mkDefault false;
|
||||
generationsDir.enable = lib.mkDefault false;
|
||||
raspberryPi = {
|
||||
enable = lib.mkDefault true;
|
||||
version = lib.mkDefault 2;
|
||||
};
|
||||
generic-extlinux-compatible.enable = lib.mkDefault true;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ in {
|
||||
|
||||
hardware.deviceTree = {
|
||||
overlays = [
|
||||
# Equivalent to: https://github.com/raspberrypi/linux/blob/rpi-6.1.y/arch/arm/boot/dts/overlays/rpi-poe-overlay.dts
|
||||
# Equivalent to: https://github.com/raspberrypi/linux/blob/rpi-6.6.y/arch/arm/boot/dts/overlays/rpi-poe-overlay.dts
|
||||
{
|
||||
name = "rpi-poe-overlay";
|
||||
dtsText = ''
|
||||
@@ -38,7 +38,7 @@ in {
|
||||
compatible = "pwm-fan";
|
||||
cooling-levels = <0 1 10 100 255>;
|
||||
#cooling-cells = <2>;
|
||||
pwms = <&fwpwm 0 80000>;
|
||||
pwms = <&fwpwm 0 80000 0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -19,8 +19,8 @@ in {
|
||||
hardware.deviceTree = {
|
||||
overlays = [
|
||||
# Combined equivalent to:
|
||||
# * https://github.com/raspberrypi/linux/blob/rpi-6.1.y/arch/arm/boot/dts/overlays/rpi-poe-overlay.dts
|
||||
# * https://github.com/raspberrypi/linux/blob/rpi-6.1.y/arch/arm/boot/dts/overlays/rpi-poe-plus-overlay.dts
|
||||
# * https://github.com/raspberrypi/linux/blob/rpi-6.6.y/arch/arm/boot/dts/overlays/rpi-poe-overlay.dts
|
||||
# * https://github.com/raspberrypi/linux/blob/rpi-6.6.y/arch/arm/boot/dts/overlays/rpi-poe-plus-overlay.dts
|
||||
{
|
||||
name = "rpi-poe-plus-overlay";
|
||||
dtsText = ''
|
||||
@@ -40,7 +40,7 @@ in {
|
||||
compatible = "pwm-fan";
|
||||
cooling-levels = <0 1 10 100 255>;
|
||||
#cooling-cells = <2>;
|
||||
pwms = <&fwpwm 0 80000>;
|
||||
pwms = <&fwpwm 0 80000 0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
cfg = config.hardware.rockchip;
|
||||
in {
|
||||
imports = [
|
||||
./rk3328
|
||||
./rk3399
|
||||
./rk3588
|
||||
];
|
||||
|
||||
options.hardware.rockchip = {
|
||||
enable = lib.mkEnableOption "Rockchip SoC support";
|
||||
diskoImageName = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "main.raw";
|
||||
description = ''
|
||||
The output image name of Disko.
|
||||
You need to match this value with the real image name. Setting it alone
|
||||
won't change the output image name, as it is controlled by Disko module.
|
||||
|
||||
Can be used in diskoExtraPostVM.
|
||||
'';
|
||||
};
|
||||
platformFirmware = lib.mkPackageOption pkgs "platform firmware" {
|
||||
default = null;
|
||||
};
|
||||
diskoExtraPostVM = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = ''
|
||||
${lib.getExe' pkgs.coreutils "dd"} conv=notrunc,fsync if=${config.hardware.rockchip.platformFirmware}/idbloader.img of=$out/${config.hardware.rockchip.diskoImageName} bs=512 seek=64
|
||||
${lib.getExe' pkgs.coreutils "dd"} conv=notrunc,fsync if=${config.hardware.rockchip.platformFirmware}/u-boot.itb of=$out/${config.hardware.rockchip.diskoImageName} bs=512 seek=16384
|
||||
'';
|
||||
defaultText = lib.literalExpression ''
|
||||
${lib.getExe' pkgs.coreutils "dd"} conv=notrunc,fsync if=${config.hardware.rockchip.platformFirmware}/idbloader.img of=$out/${config.hardware.rockchip.diskoImageName} bs=512 seek=64
|
||||
${lib.getExe' pkgs.coreutils "dd"} conv=notrunc,fsync if=${config.hardware.rockchip.platformFirmware}/u-boot.itb of=$out/${config.hardware.rockchip.diskoImageName} bs=512 seek=16384
|
||||
'';
|
||||
description = ''
|
||||
The post VM hook for Disko's Image Builder.
|
||||
Can be used to install platform firmware like U-Boot.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
boot = {
|
||||
kernelParams = [ "console=ttyS2,1500000n8" ];
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,62 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
cfg = config.hardware.rockchip;
|
||||
in {
|
||||
imports = [
|
||||
rk3399/disko.nix
|
||||
];
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
disko = {
|
||||
imageBuilder = {
|
||||
extraRootModules = [ "bcachefs" ];
|
||||
extraPostVM = cfg.diskoExtraPostVM;
|
||||
};
|
||||
memSize = lib.mkDefault 4096; # Default 1024 MB will throw "Cannot allocate memory" error
|
||||
devices.disk.main = {
|
||||
type = "disk";
|
||||
imageSize = lib.mkDefault "2G";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
ESP = {
|
||||
type = "EF00";
|
||||
# Firmware backoff
|
||||
start = "16M";
|
||||
size = "500M";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
mountOptions = [ "umask=0022" ];
|
||||
};
|
||||
};
|
||||
root = {
|
||||
size = "100%";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "bcachefs";
|
||||
mountpoint = "/";
|
||||
extraArgs = [
|
||||
"--metadata_checksum=xxhash"
|
||||
"--data_checksum=xxhash"
|
||||
"--compression=zstd"
|
||||
"--background_compression=zstd"
|
||||
"--str_hash=siphash"
|
||||
"--wide_macs"
|
||||
"--encrypted"
|
||||
"--no_passphrase"
|
||||
"--discard"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
cfg = config.hardware.rockchip.rk3328;
|
||||
in {
|
||||
options.hardware.rockchip.rk3328 = {
|
||||
enable = lib.mkEnableOption "Rockchip RK3328 support";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
hardware.rockchip.enable = true;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
cfg = config.hardware.rockchip.rk3399;
|
||||
in {
|
||||
options.hardware.rockchip.rk3399 = {
|
||||
enable = lib.mkEnableOption "Rockchip RK3399 support";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
hardware.rockchip.enable = true;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
cfg = config.hardware.rockchip.rk3399;
|
||||
in {
|
||||
config = lib.mkIf cfg.enable {
|
||||
nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [
|
||||
"arm-trusted-firmware-rk3399"
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, config
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
cfg = config.hardware.rockchip.rk3588;
|
||||
in {
|
||||
options.hardware.rockchip.rk3588 = {
|
||||
enable = lib.mkEnableOption "Rockchip RK3588 support";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
hardware.rockchip.enable = true;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,123 @@
|
||||
# [Slimbook HERO](https://slimbook.com/en/shop/product/hero-intel-i7-13620h-1115)
|
||||
|
||||
This configuration is for the Slimbook Hero with an i7-13620H and an RTX 4060.
|
||||
Model name: SLIMBOOK HERO-RPL-RTX.
|
||||
|
||||
To run software on your Nvidia GPU, use the `nvidia-offload` command. For example:
|
||||
```bash
|
||||
nvidia-offload `nix-shell -p glxinfo --run 'glxgears'`
|
||||
```
|
||||
For more information, visit: https://wiki.nixos.org/wiki/NVIDIA#Offload_mode
|
||||
|
||||
<details><summary>System information</summary>
|
||||
|
||||
```bash
|
||||
>neofetch
|
||||
OS: NixOS 24.11.20241216.3945713 (Vicuna) x86_64
|
||||
Host: SLIMBOOK HERO-RPL-RTX
|
||||
Kernel: 6.6.66
|
||||
Uptime: 37 mins
|
||||
Packages: 1296 (nix-system), 893 (nix-user), 2 (nix-default), 9 (flatpak)
|
||||
Shell: bash 5.2.37
|
||||
Resolution: 2560x1440
|
||||
DE: GNOME 47.1 (Wayland)
|
||||
WM: Mutter
|
||||
WM Theme: Adwaita
|
||||
Theme: Adwaita [GTK2/3]
|
||||
Icons: Adwaita [GTK2/3]
|
||||
Terminal: kgx
|
||||
CPU: 13th Gen Intel i7-13620H (16) @ 4.700GHz
|
||||
GPU: Intel Raptor Lake-P [UHD Graphics]
|
||||
GPU: NVIDIA GeForce RTX 4060 Max-Q / Mobile
|
||||
Memory: 4448MiB / 15734MiB
|
||||
|
||||
$ lspci -nn
|
||||
00:00.0 Host bridge [0600]: Intel Corporation Device [8086:a715]
|
||||
00:01.0 PCI bridge [0604]: Intel Corporation Raptor Lake PCI Express 5.0 Graphics Port (PEG010) [8086:a70d]
|
||||
00:02.0 VGA compatible controller [0300]: Intel Corporation Raptor Lake-P [UHD Graphics] [8086:a7a8] (rev 04)
|
||||
00:04.0 Signal processing controller [1180]: Intel Corporation Raptor Lake Dynamic Platform and Thermal Framework Processor Participant [8086:a71d]
|
||||
00:06.0 PCI bridge [0604]: Intel Corporation Raptor Lake PCIe 4.0 Graphics Port [8086:a74d]
|
||||
00:06.2 PCI bridge [0604]: Intel Corporation Device [8086:a73d]
|
||||
00:08.0 System peripheral [0880]: Intel Corporation GNA Scoring Accelerator module [8086:a74f]
|
||||
00:0a.0 Signal processing controller [1180]: Intel Corporation Raptor Lake Crashlog and Telemetry [8086:a77d] (rev 01)
|
||||
00:14.0 USB controller [0c03]: Intel Corporation Alder Lake PCH USB 3.2 xHCI Host Controller [8086:51ed] (rev 01)
|
||||
00:14.2 RAM memory [0500]: Intel Corporation Alder Lake PCH Shared SRAM [8086:51ef] (rev 01)
|
||||
00:14.3 Network controller [0280]: Intel Corporation Raptor Lake PCH CNVi WiFi [8086:51f1] (rev 01)
|
||||
00:15.0 Serial bus controller [0c80]: Intel Corporation Alder Lake PCH Serial IO I2C Controller #0 [8086:51e8] (rev 01)
|
||||
00:16.0 Communication controller [0780]: Intel Corporation Alder Lake PCH HECI Controller [8086:51e0] (rev 01)
|
||||
00:1c.0 PCI bridge [0604]: Intel Corporation Alder Lake PCH-P PCI Express Root Port #9 [8086:51bf] (rev 01)
|
||||
00:1f.0 ISA bridge [0601]: Intel Corporation Raptor Lake LPC/eSPI Controller [8086:519d] (rev 01)
|
||||
00:1f.3 Audio device [0403]: Intel Corporation Raptor Lake-P/U/H cAVS [8086:51ca] (rev 01)
|
||||
00:1f.4 SMBus [0c05]: Intel Corporation Alder Lake PCH-P SMBus Host Controller [8086:51a3] (rev 01)
|
||||
00:1f.5 Serial bus controller [0c80]: Intel Corporation Alder Lake-P PCH SPI Controller [8086:51a4] (rev 01)
|
||||
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation AD107M [GeForce RTX 4060 Max-Q / Mobile] [10de:28a0] (rev a1)
|
||||
01:00.1 Audio device [0403]: NVIDIA Corporation Device [10de:22be] (rev a1)
|
||||
02:00.0 Non-Volatile memory controller [0108]: MAXIO Technology (Hangzhou) Ltd. NVMe SSD Controller MAP1202 (DRAM-less) [1e4b:1202] (rev 01)
|
||||
03:00.0 Non-Volatile memory controller [0108]: Micron Technology Inc 2550 NVMe SSD (DRAM-less) [1344:5416] (rev 01)
|
||||
04:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL8111/8168/8211/8411 PCI Express Gigabit Ethernet Controller [10ec:8168] (rev 15)
|
||||
```
|
||||
|
||||
</details>
|
||||
|
||||
## Power Management
|
||||
My testing shows suspend issues (tested in GNOME) when using `hardware.nvidia.powerManagement.enabled = true`, regardless of the value of `hardware.nvidia.powerManagement.finegrained`.
|
||||
This seems related to this [issue](https://github.com/NixOS/nixpkgs/issues/336723), which is offered a solution in [this discouse thread](https://discourse.nixos.org/t/suspend-resume-cycling-on-system-resume/32322/12) with this config:
|
||||
|
||||
<details>
|
||||
|
||||
```nix
|
||||
systemd = {
|
||||
services."gnome-suspend" = {
|
||||
description = "suspend gnome shell";
|
||||
before = [
|
||||
"systemd-suspend.service"
|
||||
"systemd-hibernate.service"
|
||||
"nvidia-suspend.service"
|
||||
"nvidia-hibernate.service"
|
||||
];
|
||||
wantedBy = [
|
||||
"systemd-suspend.service"
|
||||
"systemd-hibernate.service"
|
||||
];
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
ExecStart = ''${pkgs.procps}/bin/pkill -f -STOP ${pkgs.gnome-shell}/bin/gnome-shell'';
|
||||
};
|
||||
};
|
||||
services."gnome-resume" = {
|
||||
description = "resume gnome shell";
|
||||
after = [
|
||||
"systemd-suspend.service"
|
||||
"systemd-hibernate.service"
|
||||
"nvidia-resume.service"
|
||||
];
|
||||
wantedBy = [
|
||||
"systemd-suspend.service"
|
||||
"systemd-hibernate.service"
|
||||
];
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
ExecStart = ''${pkgs.procps}/bin/pkill -f -CONT ${pkgs.gnome-shell}/bin/gnome-shell'';
|
||||
};
|
||||
};
|
||||
};
|
||||
```
|
||||
|
||||
</details>
|
||||
|
||||
At the same time, the Nvidia driver reports power management to still be working even with `nvidia.powerManagement.enable = false`:
|
||||
```bash
|
||||
>cat /proc/driver/nvidia/gpus/0000:01:00.0/power
|
||||
Runtime D3 status: Enabled (fine-grained)
|
||||
Video Memory: Off
|
||||
|
||||
GPU Hardware Support:
|
||||
Video Memory Self Refresh: Supported
|
||||
Video Memory Off: Supported
|
||||
|
||||
S0ix Power Management:
|
||||
Platform Support: Supported
|
||||
Status: Disabled
|
||||
```
|
||||
|
||||
For more information see the [Nvidia documentation](https://download.nvidia.com/XFree86/Linux-x86_64/565.77/README/powermanagement.html), chapters 21 and 22.
|
||||
@@ -0,0 +1,34 @@
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
imports = [
|
||||
../../../common/cpu/intel
|
||||
../../../common/gpu/intel
|
||||
../../../common/gpu/nvidia/ada-lovelace
|
||||
../../../common/gpu/nvidia/prime.nix
|
||||
../../../common/pc/laptop
|
||||
../../../common/pc/laptop/ssd
|
||||
];
|
||||
|
||||
hardware = {
|
||||
graphics = {
|
||||
enable = lib.mkDefault true;
|
||||
enable32Bit = lib.mkDefault true;
|
||||
};
|
||||
nvidia = {
|
||||
prime = {
|
||||
intelBusId = lib.mkDefault "PCI:0:2:0";
|
||||
nvidiaBusId = lib.mkDefault "PCI:1:0:0";
|
||||
};
|
||||
powerManagement = {
|
||||
enable = lib.mkDefault false; # Causes sleep issues. See README for more information
|
||||
finegrained = lib.mkDefault false;
|
||||
};
|
||||
dynamicBoost.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
fwupd.enable = lib.mkDefault true;
|
||||
thermald.enable = lib.mkDefault true;
|
||||
};
|
||||
}
|
||||
@@ -4,7 +4,7 @@
|
||||
profile
|
||||
({ config, lib, ... }: {
|
||||
nixpkgs.pkgs = pkgs;
|
||||
boot.loader.systemd-boot.enable = !config.boot.loader.generic-extlinux-compatible.enable && !config.boot.loader.raspberryPi.enable;
|
||||
boot.loader.systemd-boot.enable = !config.boot.loader.generic-extlinux-compatible.enable;
|
||||
# we forcefully disable grub here just for testing purposes, even though some profiles might still use grub in the end.
|
||||
boot.loader.grub.enable = false;
|
||||
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
{ lib, ... }:
|
||||
{
|
||||
# Required fix to allow booting NixOS on certain Xiaomi laptops
|
||||
# https://discourse.nixos.org/t/system-wont-boot-path-efi-stub/29212/12
|
||||
boot.kernelPatches = lib.singleton {
|
||||
name = "Fix boot";
|
||||
patch = null;
|
||||
extraStructuredConfig = with lib.kernel; {
|
||||
ACPI_DEBUG = yes;
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
# Xiaomi Redmibook 16 Pro (2024)
|
||||
|
||||
Note that the boot fix requires building the kernel. As such, you might run out
|
||||
of space during nixos-rebuild if you mount tmpfs on `/tmp`.
|
||||
|
||||
## Tested Hardware
|
||||
|
||||
```shellsession
|
||||
$ lspci -nn
|
||||
00:00.0 Host bridge [0600]: Intel Corporation Device [8086:7d14] (rev 04)
|
||||
00:01.0 PCI bridge [0604]: Intel Corporation Device [8086:7ecc] (rev 10)
|
||||
00:02.0 VGA compatible controller [0300]: Intel Corporation Meteor Lake-P [Intel Arc Graphics] [8086:7d55] (rev 08)
|
||||
00:04.0 Signal processing controller [1180]: Intel Corporation Meteor Lake-P Dynamic Tuning Technology [8086:7d03] (rev 04)
|
||||
00:06.0 PCI bridge [0604]: Intel Corporation Device [8086:7e4d] (rev 20)
|
||||
00:07.0 PCI bridge [0604]: Intel Corporation Meteor Lake-P Thunderbolt 4 PCI Express Root Port #1 [8086:7ec5] (rev 10)
|
||||
00:08.0 System peripheral [0880]: Intel Corporation Meteor Lake-P Gaussian & Neural-Network Accelerator [8086:7e4c] (rev 20)
|
||||
00:0a.0 Signal processing controller [1180]: Intel Corporation Meteor Lake-P Platform Monitoring Technology [8086:7d0d] (rev 01)
|
||||
00:0b.0 Processing accelerators [1200]: Intel Corporation Meteor Lake NPU [8086:7d1d] (rev 04)
|
||||
00:0d.0 USB controller [0c03]: Intel Corporation Meteor Lake-P Thunderbolt 4 USB Controller [8086:7ec0] (rev 10)
|
||||
00:0d.2 USB controller [0c03]: Intel Corporation Meteor Lake-P Thunderbolt 4 NHI #0 [8086:7ec2] (rev 10)
|
||||
00:12.0 Serial controller [0700]: Intel Corporation Meteor Lake-P Integrated Sensor Hub [8086:7e45] (rev 20)
|
||||
00:14.0 USB controller [0c03]: Intel Corporation Meteor Lake-P USB 3.2 Gen 2x1 xHCI Host Controller [8086:7e7d] (rev 20)
|
||||
00:14.2 RAM memory [0500]: Intel Corporation Device [8086:7e7f] (rev 20)
|
||||
00:14.3 Network controller [0280]: Intel Corporation Meteor Lake PCH CNVi WiFi [8086:7e40] (rev 20)
|
||||
00:15.0 Serial bus controller [0c80]: Intel Corporation Meteor Lake-P Serial IO I2C Controller #0 [8086:7e78] (rev 20)
|
||||
00:16.0 Communication controller [0780]: Intel Corporation Meteor Lake-P CSME HECI #1 [8086:7e70] (rev 20)
|
||||
00:1f.0 ISA bridge [0601]: Intel Corporation Device [8086:7e02] (rev 20)
|
||||
00:1f.3 Multimedia audio controller [0401]: Intel Corporation Meteor Lake-P HD Audio Controller [8086:7e28] (rev 20)
|
||||
00:1f.4 SMBus [0c05]: Intel Corporation Meteor Lake-P SMBus Controller [8086:7e22] (rev 20)
|
||||
00:1f.5 Serial bus controller [0c80]: Intel Corporation Meteor Lake-P SPI Controller [8086:7e23] (rev 20)
|
||||
01:00.0 Non-Volatile memory controller [0108]: SK hynix BC511 NVMe SSD [1c5c:1339]
|
||||
02:00.0 Non-Volatile memory controller [0108]: Yangtze Memory Technologies Co.,Ltd PC300 NVMe SSD (DRAM-less) [1e49:1033] (rev 03)
|
||||
```
|
||||
|
||||
## Extra Configuration
|
||||
|
||||
### Bluetooth
|
||||
|
||||
To enable bluetooth support, set `hardware.bluetooth.enable = true;`.
|
||||
@@ -0,0 +1,13 @@
|
||||
{ lib, ... }:
|
||||
{
|
||||
imports = [
|
||||
../../fix-boot-quirk.nix
|
||||
../../../common/cpu/intel
|
||||
../../../common/pc/laptop
|
||||
../../../common/pc/laptop/ssd
|
||||
];
|
||||
|
||||
hardware.enableRedistributableFirmware = lib.mkDefault true;
|
||||
|
||||
services.thermald.enable = lib.mkDefault true;
|
||||
}
|
||||
Reference in new issue
Block a user