letting it auto run pretty much, god i don't know how to program anymore. This is kinda a joke
This commit is contained in:
39
modules/hardware/intel.nix
Normal file
39
modules/hardware/intel.nix
Normal file
@@ -0,0 +1,39 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
{
|
||||
options.hardware.intel.enable = mkEnableOption "Intel graphics support";
|
||||
|
||||
config = mkIf config.hardware.intel.enable {
|
||||
# Intel driver configuration
|
||||
services.xserver.videoDrivers = [ "modesetting" ];
|
||||
|
||||
# Enable Intel GPU support
|
||||
boot.initrd.kernelModules = [ "i915" ];
|
||||
|
||||
# Intel GPU early loading
|
||||
boot.kernelParams = [ "i915.enable_guc=2" ];
|
||||
|
||||
# Intel specific packages
|
||||
environment.systemPackages = with pkgs; [
|
||||
intel-gpu-tools
|
||||
nvtopPackages.intel
|
||||
];
|
||||
|
||||
# OpenGL packages for Intel (already configured in default.nix)
|
||||
hardware.opengl.extraPackages = with pkgs; [
|
||||
intel-media-driver
|
||||
vaapiIntel
|
||||
intel-compute-runtime
|
||||
intel-ocl
|
||||
];
|
||||
|
||||
hardware.opengl.extraPackages32 = with pkgs.pkgsi686Linux; [
|
||||
vaapiIntel
|
||||
];
|
||||
|
||||
# Intel GPU power management
|
||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user