Move boot.nix to common

This commit is contained in:
2023-04-18 18:30:02 +02:00
committed by Rodrigo Arias Mallo
parent 9e3bdaabb6
commit b043ee3b1d
3 changed files with 1 additions and 1 deletions

29
common/boot.nix Normal file
View File

@@ -0,0 +1,29 @@
{ lib, ... }:
{
# Use the GRUB 2 boot loader.
boot.loader.grub.enable = true;
boot.loader.grub.version = 2;
# Enable GRUB2 serial console
boot.loader.grub.extraConfig = ''
serial --unit=0 --speed=115200 --word=8 --parity=no --stop=1
terminal_input --append serial
terminal_output --append serial
'';
# Enable serial console
boot.kernelParams = [
"console=tty1"
"console=ttyS0,115200"
];
boot.kernelPatches = lib.singleton {
name = "osnoise-tracer";
patch = null;
extraStructuredConfig = with lib.kernel; {
OSNOISE_TRACER = yes;
HWLAT_TRACER = yes;
};
};
}

View File

@@ -2,5 +2,6 @@
{
imports = [
./boot.nix
];
}