mirror of
https://github.com/NixOS/nixos-hardware
synced 2024-06-02 11:03:33 +02:00
Merge branch 'master' into master
This commit is contained in:
commit
a266ccc4cf
|
@ -146,7 +146,7 @@ See code for all available configurations.
|
||||||
| [Framework 12th Gen Intel Core](framework/13-inch/12th-gen-intel) | `<nixos-hardware/framework/13-inch/12th-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>` |
|
| [Framework 13th Gen Intel Core](framework/13-inch/13th-gen-intel) | `<nixos-hardware/framework/13-inch/13th-gen-intel>` |
|
||||||
| [Framework 13 AMD Ryzen 7040 Series](framework/13-inch/7040-amd) | `<nixos-hardware/framework/13-inch/7040-amd>` |
|
| [Framework 13 AMD Ryzen 7040 Series](framework/13-inch/7040-amd) | `<nixos-hardware/framework/13-inch/7040-amd>` |
|
||||||
| [Framework 16 AMD Ryzen 7040 Series](framework/16-inch/cpu/7040-amd) | `<nixos-hardware/framework/16-inch/cpu/7040-amd>` |
|
| [Framework 16 AMD Ryzen 7040 Series](framework/16-inch/7040-amd) | `<nixos-hardware/framework/16-inch/7040-amd>` |
|
||||||
| [FriendlyARM NanoPC-T4](friendlyarm/nanopc-t4) | `<nixos-hardware/friendlyarm/nanopc-t4>` |
|
| [FriendlyARM NanoPC-T4](friendlyarm/nanopc-t4) | `<nixos-hardware/friendlyarm/nanopc-t4>` |
|
||||||
| [FriendlyARM NanoPi R5s](friendlyarm/nanopi-r5s) | `<nixos-hardware/friendlyarm/nanopi-r5s>` |
|
| [FriendlyARM NanoPi R5s](friendlyarm/nanopi-r5s) | `<nixos-hardware/friendlyarm/nanopi-r5s>` |
|
||||||
| [Focus M2 Gen 1](focus/m2/gen1) | `<nixos-hardware/focus/m2/gen1>` |
|
| [Focus M2 Gen 1](focus/m2/gen1) | `<nixos-hardware/focus/m2/gen1>` |
|
||||||
|
@ -188,6 +188,7 @@ See code for all available configurations.
|
||||||
| [Lenovo ThinkPad L13](lenovo/thinkpad/l13) | `<nixos-hardware/lenovo/thinkpad/l13>` |
|
| [Lenovo ThinkPad L13](lenovo/thinkpad/l13) | `<nixos-hardware/lenovo/thinkpad/l13>` |
|
||||||
| [Lenovo ThinkPad L14 (AMD)](lenovo/thinkpad/l14/amd) | `<nixos-hardware/lenovo/thinkpad/l14/amd>` |
|
| [Lenovo ThinkPad L14 (AMD)](lenovo/thinkpad/l14/amd) | `<nixos-hardware/lenovo/thinkpad/l14/amd>` |
|
||||||
| [Lenovo ThinkPad L14 (Intel)](lenovo/thinkpad/l14/intel) | `<nixos-hardware/lenovo/thinkpad/l14/intel>` |
|
| [Lenovo ThinkPad L14 (Intel)](lenovo/thinkpad/l14/intel) | `<nixos-hardware/lenovo/thinkpad/l14/intel>` |
|
||||||
|
| [Lenovo ThinkPad L480](lenovo/thinkpad/l480) | `<nixos-hardware/lenovo/thinkpad/l480>` |
|
||||||
| [Lenovo ThinkPad P1 Gen 3](lenovo/thinkpad/p1/3th-gen) | `<nixos-hardware/lenovo/thinkpad/p1/3th-gen>` |
|
| [Lenovo ThinkPad P1 Gen 3](lenovo/thinkpad/p1/3th-gen) | `<nixos-hardware/lenovo/thinkpad/p1/3th-gen>` |
|
||||||
| [Lenovo ThinkPad P14s AMD Gen 2](lenovo/thinkpad/p14s/amd/gen2) | `<nixos-hardware/lenovo/thinkpad/p14s/amd/gen2>` |
|
| [Lenovo ThinkPad P14s AMD Gen 2](lenovo/thinkpad/p14s/amd/gen2) | `<nixos-hardware/lenovo/thinkpad/p14s/amd/gen2>` |
|
||||||
| [Lenovo ThinkPad P16s AMD Gen 1](lenovo/thinkpad/p16s/amd/gen1) | `<nixos-hardware/lenovo/thinkpad/p16s/amd/gen1>` |
|
| [Lenovo ThinkPad P16s AMD Gen 1](lenovo/thinkpad/p16s/amd/gen1) | `<nixos-hardware/lenovo/thinkpad/p16s/amd/gen1>` |
|
||||||
|
@ -281,6 +282,7 @@ See code for all available configurations.
|
||||||
| [Purism Librem 5r4](purism/librem/5r4) | `<nixos-hardware/purism/librem/5r4>` |
|
| [Purism Librem 5r4](purism/librem/5r4) | `<nixos-hardware/purism/librem/5r4>` |
|
||||||
| [Raspberry Pi 2](raspberry-pi/2) | `<nixos-hardware/raspberry-pi/2>` |
|
| [Raspberry Pi 2](raspberry-pi/2) | `<nixos-hardware/raspberry-pi/2>` |
|
||||||
| [Raspberry Pi 4](raspberry-pi/4) | `<nixos-hardware/raspberry-pi/4>` |
|
| [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>` |
|
| [Samsung Series 9 NP900X3C](samsung/np900x3c) | `<nixos-hardware/samsung/np900x3c>` |
|
||||||
| [StarFive VisionFive v1](starfive/visionfive/v1) | `<nixos-hardware/starfive/visionfive/v1>` |
|
| [StarFive VisionFive v1](starfive/visionfive/v1) | `<nixos-hardware/starfive/visionfive/v1>` |
|
||||||
| [StarFive VisionFive 2](starfive/visionfive/v2) | `<nixos-hardware/starfive/visionfive/v2>` |
|
| [StarFive VisionFive 2](starfive/visionfive/v2) | `<nixos-hardware/starfive/visionfive/v2>` |
|
||||||
|
|
|
@ -79,7 +79,7 @@
|
||||||
framework-12th-gen-intel = import ./framework/13-inch/12th-gen-intel;
|
framework-12th-gen-intel = import ./framework/13-inch/12th-gen-intel;
|
||||||
framework-13th-gen-intel = import ./framework/13-inch/13th-gen-intel;
|
framework-13th-gen-intel = import ./framework/13-inch/13th-gen-intel;
|
||||||
framework-13-7040-amd = import ./framework/13-inch/7040-amd;
|
framework-13-7040-amd = import ./framework/13-inch/7040-amd;
|
||||||
framework-16-7040-amd = import ./framework/16-inch/cpu/7040-amd;
|
framework-16-7040-amd = import ./framework/16-inch/7040-amd;
|
||||||
friendlyarm-nanopc-t4 = import ./friendlyarm/nanopc-t4;
|
friendlyarm-nanopc-t4 = import ./friendlyarm/nanopc-t4;
|
||||||
friendlyarm-nanopi-r5s = import ./friendlyarm/nanopi-r5s;
|
friendlyarm-nanopi-r5s = import ./friendlyarm/nanopi-r5s;
|
||||||
focus-m2-gen1 = import ./focus/m2/gen1;
|
focus-m2-gen1 = import ./focus/m2/gen1;
|
||||||
|
@ -122,6 +122,7 @@
|
||||||
lenovo-thinkpad-l13-yoga = import ./lenovo/thinkpad/l13/yoga;
|
lenovo-thinkpad-l13-yoga = import ./lenovo/thinkpad/l13/yoga;
|
||||||
lenovo-thinkpad-l14-amd = import ./lenovo/thinkpad/l14/amd;
|
lenovo-thinkpad-l14-amd = import ./lenovo/thinkpad/l14/amd;
|
||||||
lenovo-thinkpad-l14-intel = import ./lenovo/thinkpad/l14/intel;
|
lenovo-thinkpad-l14-intel = import ./lenovo/thinkpad/l14/intel;
|
||||||
|
lenovo-thinkpad-l480 = import ./lenovo/thinkpad/l480;
|
||||||
lenovo-thinkpad-p1 = import ./lenovo/thinkpad/p1;
|
lenovo-thinkpad-p1 = import ./lenovo/thinkpad/p1;
|
||||||
lenovo-thinkpad-p1-gen3 = import ./lenovo/thinkpad/p1/3th-gen;
|
lenovo-thinkpad-p1-gen3 = import ./lenovo/thinkpad/p1/3th-gen;
|
||||||
lenovo-thinkpad-p14s-amd-gen2 = import ./lenovo/thinkpad/p14s/amd/gen2;
|
lenovo-thinkpad-p14s-amd-gen2 = import ./lenovo/thinkpad/p14s/amd/gen2;
|
||||||
|
@ -220,6 +221,7 @@
|
||||||
purism-librem-5r4 = import ./purism/librem/5r4;
|
purism-librem-5r4 = import ./purism/librem/5r4;
|
||||||
raspberry-pi-2 = import ./raspberry-pi/2;
|
raspberry-pi-2 = import ./raspberry-pi/2;
|
||||||
raspberry-pi-4 = import ./raspberry-pi/4;
|
raspberry-pi-4 = import ./raspberry-pi/4;
|
||||||
|
raspberry-pi-5 = import ./raspberry-pi/5;
|
||||||
kobol-helios4 = import ./kobol/helios4;
|
kobol-helios4 = import ./kobol/helios4;
|
||||||
samsung-np900x3c = import ./samsung/np900x3c;
|
samsung-np900x3c = import ./samsung/np900x3c;
|
||||||
starfive-visionfive-v1 = import ./starfive/visionfive/v1;
|
starfive-visionfive-v1 = import ./starfive/visionfive/v1;
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
../../../common/pc/laptop
|
../../../common/pc/laptop
|
||||||
../../../common/pc/laptop/ssd
|
../../../common/pc/laptop/ssd
|
||||||
../../kmod.nix
|
../../kmod.nix
|
||||||
|
../../framework-tool.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
# Fix TRRS headphones missing a mic
|
# Fix TRRS headphones missing a mic
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
imports = [
|
imports = [
|
||||||
../common
|
../common
|
||||||
../common/amd.nix
|
../common/amd.nix
|
||||||
../../../../common/cpu/amd/raphael/igpu.nix
|
../../../common/cpu/amd/raphael/igpu.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
}
|
}
|
|
@ -1,8 +1,8 @@
|
||||||
{ lib, config, ... }: {
|
{ lib, config, ... }: {
|
||||||
imports = [
|
imports = [
|
||||||
../../../../common/cpu/amd
|
../../../common/cpu/amd
|
||||||
../../../../common/cpu/amd/pstate.nix
|
../../../common/cpu/amd/pstate.nix
|
||||||
../../../../common/gpu/amd
|
../../../common/gpu/amd
|
||||||
];
|
];
|
||||||
|
|
||||||
# Workaround for SuspendThenHibernate: https://lore.kernel.org/linux-kernel/20231106162310.85711-1-mario.limonciello@amd.com/
|
# Workaround for SuspendThenHibernate: https://lore.kernel.org/linux-kernel/20231106162310.85711-1-mario.limonciello@amd.com/
|
|
@ -1,7 +1,8 @@
|
||||||
{ lib, pkgs, ... }: {
|
{ lib, pkgs, ... }: {
|
||||||
imports = [
|
imports = [
|
||||||
../../../../common/pc/laptop
|
../../../common/pc/laptop
|
||||||
../../../../common/pc/laptop/ssd
|
../../../common/pc/laptop/ssd
|
||||||
|
../../framework-tool.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
# Fix TRRS headphones missing a mic
|
# Fix TRRS headphones missing a mic
|
3
framework/framework-tool.nix
Normal file
3
framework/framework-tool.nix
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
{ pkgs, ... }: {
|
||||||
|
environment.systemPackages = [ pkgs.framework-tool ];
|
||||||
|
}
|
|
@ -18,4 +18,14 @@ in
|
||||||
|
|
||||||
# √(2560² + 1600²) px / 16 in ≃ 189 dpi
|
# √(2560² + 1600²) px / 16 in ≃ 189 dpi
|
||||||
services.xserver.dpi = 189;
|
services.xserver.dpi = 189;
|
||||||
|
|
||||||
|
# Enable fingerprint reader
|
||||||
|
services.fprintd = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.fprintd-tod;
|
||||||
|
tod = {
|
||||||
|
enable = true;
|
||||||
|
driver = pkgs.libfprint-2-tod1-elan;
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
12
lenovo/thinkpad/l480/default.nix
Normal file
12
lenovo/thinkpad/l480/default.nix
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
{ lib, ... }:
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
../.
|
||||||
|
../../../common/cpu/intel/kaby-lake
|
||||||
|
../../../common/pc/laptop/ssd
|
||||||
|
];
|
||||||
|
|
||||||
|
# available cpufreq governors: performance powersave
|
||||||
|
# The powersave mode locks the cpu to 700Mhz which is not really usable
|
||||||
|
powerManagement.cpuFreqGovernor = lib.mkDefault "performance";
|
||||||
|
}
|
|
@ -7,14 +7,14 @@ let
|
||||||
|
|
||||||
cfg = config.microsoft-surface;
|
cfg = config.microsoft-surface;
|
||||||
|
|
||||||
version = "6.8.6";
|
version = "6.8.9";
|
||||||
kernelPatches = surfacePatches {
|
kernelPatches = surfacePatches {
|
||||||
inherit version;
|
inherit version;
|
||||||
patchFn = ./patches.nix;
|
patchFn = ./patches.nix;
|
||||||
};
|
};
|
||||||
kernelPackages = linuxPackage {
|
kernelPackages = linuxPackage {
|
||||||
inherit version kernelPatches;
|
inherit version kernelPatches;
|
||||||
sha256 = "sha256-nnIyMtYDq0Xr8EPDRxTEjyd6sZXCmry4Ry8qTDpaGZU=";
|
sha256 = "sha256-+QXxI46nqOhTFLrPKDMC6AlwBgENJfzqcm0N4OpbybY=";
|
||||||
ignoreConfigErrors=true;
|
ignoreConfigErrors=true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
35
raspberry-pi/5/default.nix
Normal file
35
raspberry-pi/5/default.nix
Normal file
|
@ -0,0 +1,35 @@
|
||||||
|
{ lib, pkgs, config, ... }:
|
||||||
|
let
|
||||||
|
linux_rpi5 = pkgs.linux_rpi4.override {
|
||||||
|
rpiVersion = 5;
|
||||||
|
argsOverride.defconfig = "bcm2712_defconfig";
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
boot = {
|
||||||
|
kernelPackages = lib.mkDefault (pkgs.linuxPackagesFor linux_rpi5);
|
||||||
|
initrd.availableKernelModules = [
|
||||||
|
"nvme"
|
||||||
|
"usbhid"
|
||||||
|
"usb_storage"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
# Needed for Xorg to start (https://github.com/raspberrypi-ui/gldriver-test/blob/master/usr/lib/systemd/scripts/rp1_test.sh)
|
||||||
|
# This won't work for displays connected to the RP1 (DPI/composite/MIPI DSI), since I don't have one to test.
|
||||||
|
services.xserver.extraConfig = ''
|
||||||
|
Section "OutputClass"
|
||||||
|
Identifier "vc4"
|
||||||
|
MatchDriver "vc4"
|
||||||
|
Driver "modesetting"
|
||||||
|
Option "PrimaryGPU" "true"
|
||||||
|
EndSection
|
||||||
|
'';
|
||||||
|
|
||||||
|
assertions = [
|
||||||
|
{
|
||||||
|
assertion = (lib.versionAtLeast config.boot.kernelPackages.kernel.version "6.1.54");
|
||||||
|
message = "The Raspberry Pi 5 requires a newer kernel version (>=6.1.54). Please upgrade nixpkgs for this system.";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
|
@ -81,7 +81,7 @@ def write_eval_test(f: IO[str], profiles: list[str]) -> None:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
system = "x86_64-linux"
|
system = "x86_64-linux"
|
||||||
if "raspberry-pi/4" == profile:
|
if "raspberry-pi/4" == profile or "raspberry-pi/5" == profile:
|
||||||
system = "aarch64-linux"
|
system = "aarch64-linux"
|
||||||
|
|
||||||
f.write(
|
f.write(
|
||||||
|
|
Loading…
Reference in New Issue
Block a user