about summary refs log tree commit diff
path: root/modules/nixos-hardware/lenovo/thinkpad/e470/default.nix
blob: c9bf8331b05061fb53d9d205a038a2c9cff9cd83 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
{ config, lib, pkgs, ... }:

{
  imports = [
    ../.
    ../../../common/cpu/intel/kaby-lake
    ../../../common/gpu/nvidia.nix
  ];

  hardware.nvidia.prime = {
    # Bus ID of the Intel GPU.
    intelBusId = lib.mkDefault "PCI:0:2:0";

    # Bus ID of the NVIDIA GPU.
    nvidiaBusId = lib.mkDefault "PCI:1:0:0";
  };

  boot.kernelPackages = lib.mkIf (lib.versionOlder pkgs.linux.version "5.6") pkgs.linuxPackages_latest;
}