-
-
Notifications
You must be signed in to change notification settings - Fork 662
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lenovo/yoga/7/14IAH7: add profile for 14IAH7 (Lenovo Yoga Slim 7i Pro X)
There is already a profile for the AMD version of this device, being the Lenovo `14ARH7` (Lenovo Yoga Slim 7 Pro X) under `lenovo/yoga/7/14IAH7`. I opted to make an entirely separate profile, rather than sharing with it, since I don't have that device to confirm that unintended changes aren't introduced. - Add profile for `14IAH7` - Update `README.md` - Update `flake.nix`
- Loading branch information
Showing
5 changed files
with
94 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/* | ||
* `lenovo-yoga-7-14IAH7-hybrid`: | ||
* | ||
* This is a hybrid profile that enables the NVIDIA | ||
* driver and PRIME offload mode for making use of both | ||
* integrated and dedicated graphics. Use this profile if | ||
* you want to use the NVIDIA GeForce RTX 3050 Mobile. | ||
* Read about PRIME offload mode here: | ||
* <https://wiki.nixos.org/wiki/NVIDIA#Offload_mode> | ||
* | ||
* The `lenovo-yoga-7-14IAH7-integrated` profile only | ||
* has the integrated Intel GPU enabled. The dedicated | ||
* NVIDIA GPU is disabled entirely. Use that profile | ||
* instead if you want to only use integrated graphics. | ||
* | ||
* `nouveau` wasn't added to any profiles since it | ||
* is known to cause freezes for this device. | ||
* `nouveau` is blacklisted by default when enabling this: | ||
* <https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/hardware/video/nvidia.nix> | ||
*/ | ||
{ lib, ... }: | ||
{ | ||
imports = [ | ||
../shared.nix | ||
../../../../../common/gpu/nvidia/ampere | ||
../../../../../common/gpu/nvidia/prime.nix | ||
]; | ||
|
||
hardware.nvidia = { | ||
# Info: <https://wiki.nixos.org/wiki/NVIDIA#Common_setup> | ||
prime = { | ||
intelBusId = "PCI:0:2:0"; | ||
nvidiaBusId = "PCI:1:0:0"; | ||
}; | ||
|
||
# Info: <https://download.nvidia.com/XFree86/Linux-x86_64/460.73.01/README/dynamicpowermanagement.html> | ||
powerManagement.enable = lib.mkDefault true; | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
/* | ||
* `lenovo-yoga-7-14IAH7-integrated`: | ||
* | ||
* This profile only has the integrated Intel GPU | ||
* enabled. The dedicated NVIDIA GPU is disabled | ||
* entirely. Use this profile if you want to only | ||
* use the integrated GPU. | ||
* | ||
* It is recommended to use this profile to disable | ||
* dedicated graphics, rather than doing it through | ||
* the BIOS, since that method causes issues with | ||
* the integrated graphics drivers. Doing it | ||
* through blacklisting achieves the same result | ||
* with no side-effects. | ||
* | ||
* The `lenovo-yoga-7-14IAH7-hybrid` hybrid profile | ||
* enables the NVIDIA driver and PRIME offload mode | ||
* for making use of both GPUs. Use that profile | ||
* instead if you want to use the NVIDIA GPU. | ||
* Read about PRIME offload mode here: | ||
* <https://wiki.nixos.org/wiki/NVIDIA#Offload_mode> | ||
*/ | ||
{ | ||
imports = [ | ||
../shared.nix | ||
../../../../../common/gpu/nvidia/disable.nix | ||
]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
/* | ||
* Here are configurations for the | ||
* Intel Core i7-12700H CPU, along | ||
* with a few others. | ||
*/ | ||
{ | ||
imports = [ | ||
../../../../common/cpu/intel/alder-lake | ||
../../../../common/gpu/intel/alder-lake | ||
../../../../common/pc/laptop | ||
../../../../common/pc/ssd | ||
]; | ||
|
||
boot = { | ||
kernelModules = [ "kvm-intel" ]; | ||
kernelParams = [ | ||
# Info: <https://lore.kernel.org/linux-acpi/[email protected]/> | ||
"acpi.prefer_microsoft_dsm_guid=1" | ||
# Info: <https://wiki.archlinux.org/title/Power_management#Active_State_Power_Management> | ||
"pcie_aspm.policy=powersupersave" | ||
]; | ||
}; | ||
} |