Enabled amd-nvidia-hybrid support

Updated install script to support that config

I don't have a system to test with

 On branch main
 Your branch is up to date with 'origin/main'.

 Changes to be committed:
	modified:   CHANGELOG.md
	modified:   flake.nix
	modified:   install-zaneyos.sh
	modified:   modules/drivers/nvidia-amd-hybrid.nix
	renamed:    profiles/amd-hybrid/default.nix -> profiles/amd-nvidia-hybrid/default.nix
This commit is contained in:
Don Williams 2025-12-28 08:21:00 -05:00
commit b1188be273
5 changed files with 20 additions and 12 deletions

View file

@ -7,6 +7,10 @@
# 🚀 **Current Release - ZaneyOS v2.5.6**
#### 📅 **Updated: December 26th, 2025**
- Added initial support for AMD, NVIDIA Hybrid laptops
#### 📅 **Updated: December 21st, 2025**
- Added user systemd service for `noctalia-shell`

View file

@ -72,7 +72,7 @@
amd = mkNixosConfig "amd";
nvidia = mkNixosConfig "nvidia";
nvidia-laptop = mkNixosConfig "nvidia-laptop";
amd-hybrid = mkNixosConfig "amd-hybrid";
amd-nvidia-hybrid = mkNixosConfig "amd-nvidia-hybrid";
intel = mkNixosConfig "intel";
vm = mkNixosConfig "vm";
};

View file

@ -154,8 +154,10 @@ if lspci | grep -qi 'vga\|3d'; then
if $has_vm; then
DETECTED_PROFILE="vm"
elif $has_nvidia && $has_amd; then
DETECTED_PROFILE="amd-nvidia-hybrid"
elif $has_nvidia && $has_intel; then
DETECTED_PROFILE="hybrid"
DETECTED_PROFILE="nvidia-laptop"
elif $has_nvidia; then
DETECTED_PROFILE="nvidia"
elif $has_amd; then
@ -183,9 +185,10 @@ if [ -z "$profile" ]; then
read -rp "Enter Your Hardware Profile (GPU)
Options:
[ amd ]
amd-nvidia-hybrid
intel
nvidia
nvidia-laptop
intel
vm
Please type out your choice: " profile
if [ -z "$profile" ]; then

View file

@ -10,22 +10,23 @@ in {
options.drivers.nvidia-amd-hybrid = {
enable = mkEnableOption "Enable AMD iGPU + NVIDIA dGPU (Prime offload)";
# AMD iGPU Bus ID (e.g., PCI:5:0:0). Expose as option for future host wiring.
amdgpuBusID = mkOption {
amdgpuBusId = mkOption {
type = types.str;
default = "PCI:5:0:0";
description = "PCI Bus ID for AMD iGPU (amdgpuBusId)";
description = "PCI Bus ID for AMD iGPU";
};
# NVIDIA dGPU Bus ID (e.g., PCI:1:0:0)
nvidiaBusID = mkOption {
nvidiaBusId = mkOption {
type = types.str;
default = "PCI:1:0:0";
description = "PCI Bus ID for NVIDIA dGPU (nvidiaBusId)";
description = "PCI Bus ID for NVIDIA dGPU";
};
};
config = mkIf cfg.enable {
# Enforce kernel 6.12 when this hybrid config is selected
boot.kernelPackages = lib.mkForce pkgs.linuxPackages_6_12;
# Not sure this is still neeeded but leaving just in case
# boot.kernelPackages = lib.mkForce pkgs.linuxPackages_6_12;
services.xserver.videoDrivers = ["nvidia"];
@ -47,8 +48,8 @@ in {
};
# Wire from options
amdgpuBusId = cfg.amdgpuBusID;
nvidiaBusId = cfg.nvidiaBusID;
amdgpuBusId = cfg.amdgpuBusId;
nvidiaBusId = cfg.nvidiaBusId;
};
};
};

View file

@ -10,8 +10,8 @@ in {
# Enable AMD+NVIDIA hybrid drivers (Prime offload with AMD as primary)
drivers.nvidia-amd-hybrid = {
enable = true;
amdgpuBusID = "${amdgpuID}";
nvidiaBusID = "${nvidiaID}";
amdgpuBusId = "${amdgpuID}";
nvidiaBusId = "${nvidiaID}";
};
# Ensure other driver toggles are off for this profile