1
0
Fork 0
mirror of https://github.com/NixOS/nixos-hardware synced 2025-01-25 10:14:59 +01:00
nixos-hardware/lenovo/yoga/6/13ALC6/default.nix

27 lines
658 B
Nix
Raw Normal View History

{ lib, pkgs, ... }:
2022-12-24 02:38:10 +03:00
{
2022-12-28 23:10:35 +03:00
imports = [
../../../thinkpad/yoga.nix
../../../../common/gpu/amd/default.nix
2022-12-24 02:38:10 +03:00
];
2022-12-28 23:10:35 +03:00
boot.initrd.kernelModules = [ "ideapad_laptop" ];
2022-12-24 02:38:10 +03:00
# latest kernel needed to make wifi work
boot.kernelPackages = lib.mkIf (lib.versionOlder pkgs.linux.version "5.16") pkgs.linuxPackages_latest;
2022-12-24 02:38:10 +03:00
2022-12-28 23:10:35 +03:00
# energy savings
boot.kernelParams = [
"mem_sleep_default=deep"
"pcie_aspm.policy=powersupersave"
];
# Fix for unstable wifi connection on Lenovo laptops
boot.extraModprobeConfig = ''
options rtw89_pci disable_clkreq=y disable_aspm_l1=y disable_aspm_l1ss=y
'';
hardware.bluetooth.enable = lib.mkDefault true;
2022-12-24 02:38:10 +03:00
}