Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,7 @@ See code for all available configurations.
| [Purism Librem 5r4](purism/librem/5r4) | `<nixos-hardware/purism/librem/5r4>` |
| [Raspberry Pi 2](raspberry-pi/2) | `<nixos-hardware/raspberry-pi/2>` |
| [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>` |
| [StarFive VisionFive v1](starfive/visionfive/v1) | `<nixos-hardware/starfive/visionfive/v1>` |
| [StarFive VisionFive 2](starfive/visionfive/v2) | `<nixos-hardware/starfive/visionfive/v2>` |
Expand Down
1 change: 1 addition & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,7 @@
purism-librem-5r4 = import ./purism/librem/5r4;
raspberry-pi-2 = import ./raspberry-pi/2;
raspberry-pi-4 = import ./raspberry-pi/4;
raspberry-pi-5 = import ./raspberry-pi/5;
kobol-helios4 = import ./kobol/helios4;
samsung-np900x3c = import ./samsung/np900x3c;
starfive-visionfive-v1 = import ./starfive/visionfive/v1;
Expand Down
35 changes: 35 additions & 0 deletions raspberry-pi/5/default.nix
Original file line number Diff line number Diff line change
@@ -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.";
}
];
}
2 changes: 1 addition & 1 deletion tests/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ def write_eval_test(f: IO[str], profiles: list[str]) -> None:
continue

system = "x86_64-linux"
if "raspberry-pi/4" == profile:
if "raspberry-pi/4" == profile or "raspberry-pi/5" == profile:
system = "aarch64-linux"

f.write(
Expand Down