Skip to content

Commit cedb27b

Browse files
Mic92mergify[bot]
authored andcommitted
Added config for Huawei Matebook X Pro (2020) (#957)
Created a config file for Huawei Matebook X Pro (2020). This file should work on all versions other than MACHC-WAH9L as that one does not include the Nvidia MX250 dGPU.
1 parent d9e0b26 commit cedb27b

File tree

4 files changed

+33
-0
lines changed

4 files changed

+33
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ See code for all available configurations.
164164
| [HP Elitebook 845g8](hp/elitebook/845/g8) | `<nixos-hardware/hp/elitebook/845/g8>` |
165165
| [HP Elitebook 845g9](hp/elitebook/845/g9) | `<nixos-hardware/hp/elitebook/845/g9>` |
166166
| [HP Notebook 14-df0023](hp/notebook/14-df0023) | `<nixos-hardware/hp/notebook/14-df0023>` |
167+
| [Huawei Matebook X Pro (2020)](huawei/machc-wa) | `<nixos-hardware/huawei/machc-wa>` |
167168
| [i.MX8QuadMax Multisensory Enablement Kit](nxp/imx8qm-mek/) | `<nixos-hardware/nxp/imx8qm-mek>` |
168169
| [Intel NUC 8i7BEH](intel/nuc/8i7beh/) | `<nixos-hardware/intel/nuc/8i7beh>` |
169170
| [Lenovo IdeaPad Gaming 3 15arh05](lenovo/ideapad/15arh05) | `<nixos-hardware/lenovo/ideapad/15arh05>` |

flake.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@
9696
hp-elitebook-845g7 = import ./hp/elitebook/845/g7;
9797
hp-elitebook-845g8 = import ./hp/elitebook/845/g8;
9898
hp-elitebook-845g9 = import ./hp/elitebook/845/g9;
99+
huawei-machc-wa = import ./huawei/machc-wa;
99100
hp-notebook-14-df0023 = import ./hp/notebook/14-df0023;
100101
intel-nuc-8i7beh = import ./intel/nuc/8i7beh;
101102
lenovo-ideapad-15arh05 = import ./lenovo/ideapad/15arh05;

huawei/machc-wa/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Huawei Matebook X Pro (2020)
2+
3+
This is a very standard device that needs little configuration. The module mainly imports the common modules for its CPU, GPU, SSD etc. and enables ppd for power management. Nvidia prime offload is also enabled. This configuration should work with all Matebook X Pro models from 2020 (MACHC-WA*) other than MACHC-WAH9L as it does not contain the Nvidia GPU.

huawei/machc-wa/default.nix

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
{
2+
lib,
3+
pkgs,
4+
config,
5+
...
6+
}: {
7+
imports = [
8+
../../common/cpu/intel
9+
../../common/cpu/intel/comet-lake
10+
../../common/gpu/nvidia
11+
../../common/gpu/nvidia/prime.nix
12+
../../common/hidpi.nix
13+
../../common/pc/laptop
14+
../../common/pc/ssd
15+
];
16+
17+
hardware.nvidia = {
18+
modesetting.enable = lib.mkDefault true;
19+
open = lib.mkDefault false;
20+
nvidiaSettings = lib.mkDefault true;
21+
prime = {
22+
intelBusId = "PCI:0:2:0";
23+
nvidiaBusId = "PCI:1:0:0";
24+
};
25+
};
26+
27+
services.power-profiles-daemon.enable = lib.mkDefault true;
28+
}

0 commit comments

Comments
 (0)