From bb5ef8544bfbd29b5e15a569c3aee1524cd65017 Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Thu, 29 Jun 2023 13:37:17 -0600 Subject: [PATCH] [NixOS] Try to fix raspberry pi https://github.com/NixOS/nixos-hardware/issues/631 --- nixos/raspberry-pi.nix | 27 ++++++++++++++++++++++----- 1 file changed, 22 insertions(+), 5 deletions(-) diff --git a/nixos/raspberry-pi.nix b/nixos/raspberry-pi.nix index 0473f33b..f5c945c1 100644 --- a/nixos/raspberry-pi.nix +++ b/nixos/raspberry-pi.nix @@ -1,12 +1,29 @@ { config, pkgs, inputs, ... }: { - imports = [ - inputs.nixos-hardware.nixosModules.raspberry-pi-4 - ]; + # https://github.com/NixOS/nixos-hardware/issues/631 + # imports = [ + # inputs.nixos-hardware.nixosModules.raspberry-pi-4 + # ]; + # hardware.raspberry-pi."4".fkms-3d.enable = true; + # hardware.raspberry-pi."4".audio.enable = true; - hardware.raspberry-pi."4".fkms-3d.enable = true; - hardware.raspberry-pi."4".audio.enable = true; + boot = { + initrd.availableKernelModules = [ + "usbhid" + "usb_storage" + "vc4" + "pcie_brcmstb" # required for the pcie bus to work + "reset-raspberrypi" # required for vl805 firmware to load + ]; + + loader = { + grub.enable = false; + generic-extlinux-compatible.enable = true; + }; + }; + boot.extraModulePackages = [ ]; + boot.kernelParams = [ ]; hardware.enableRedistributableFirmware = true;