1
0
Fork 0
mirror of https://github.com/NixOS/nixos-hardware synced 2024-11-26 21:09:42 +01:00

add raspberry-pi 0 and 3

Based off of 2.
This commit is contained in:
Matthew Bauer 2019-01-08 17:33:50 -06:00
parent a9033dcc5f
commit 9160873c16
2 changed files with 62 additions and 0 deletions

View file

@ -0,0 +1,32 @@
{ lib, pkgs, ...}:
{
boot = {
consoleLogLevel = lib.mkDefault 7;
extraTTYs = [ "ttyAMA0" ];
kernelPackages = lib.mkDefault pkgs.linuxPackages_rpi;
kernelParams = [
"dwc_otg.lpm_enable=0"
"console=ttyAMA0,115200"
"rootwait"
"elevator=deadline"
];
loader = {
grub.enable = lib.mkDefault false;
generationsDir.enable = lib.mkDefault false;
raspberryPi = {
enable = lib.mkDefault true;
version = lib.mkDefault 1;
};
};
};
nix.buildCores = 1;
nixpkgs.config.platform = lib.systems.platforms.raspberrypi;
# cpufrequtils doesn't build on ARM
powerManagement.enable = lib.mkDefault false;
services.openssh.enable = lib.mkDefault true;
}

View file

@ -0,0 +1,30 @@
{ lib, pkgs, ...}:
{
boot = {
consoleLogLevel = lib.mkDefault 7;
extraTTYs = [ "ttyAMA0" ];
kernelPackages = lib.mkDefault pkgs.linuxPackages_rpi;
kernelParams = [
"dwc_otg.lpm_enable=0"
"console=ttyAMA0,115200"
"rootwait"
"elevator=deadline"
"cma=32M"
];
loader = {
grub.enable = lib.mkDefault false;
generationsDir.enable = lib.mkDefault false;
raspberryPi = {
enable = lib.mkDefault true;
version = lib.mkDefault 3;
};
};
};
nix.buildCores = 4;
nixpkgs.config.platform = lib.systems.platforms.aarch64-multiplatform;
services.openssh.enable = lib.mkDefault true;
}