Files
nixos-hardware/hp/elitebook/830/g6/default.nix
Sebastián Zavala Villagómez 6267b43af9 hp/elitebook/830/g6: check kernel version through config instead of pkgs
The previous implementation was checking the kernel version through
`pkgs.linux`, which is only representative of the final system if
`boot.kernelPackages` is left as the default value of
`pkgs.linuxPackages`.

You can of course change this to other package sets, such as
`pkgs.linuxPackages_latest`. Instead, we now reference the kernel
through `config.boot.kernelPackages.kernel`.
2025-04-29 19:20:17 +00:00

26 lines
723 B
Nix

{ config, lib, ... }:
{
imports = [
../../../../common/cpu/intel
../../../../common/pc/laptop
../../../../common/pc/laptop/ssd
];
# Needed for wifi
hardware.enableRedistributableFirmware = lib.mkDefault true;
# Cooling management
services.thermald.enable = lib.mkDefault true;
# Allows for updating firmware via `fwupdmgr`.
services.fwupd.enable = lib.mkDefault true;
# Enables ACPI platform profiles
boot = lib.mkIf (lib.versionAtLeast config.boot.kernelPackages.kernel.version "6.1") {
kernelModules = [ "hp-wmi" ];
};
# reduces warnings/errors in boot log, seems to eliminate the ocassional boot hangs described in readme
hardware.enableAllFirmware = lib.mkDefault true;
}