mirror of
https://github.com/alyraffauf/nixcfg.git
synced 2024-11-25 15:51:54 -05:00
update dhardware configs
This commit is contained in:
parent
881e25b777
commit
e176d95550
|
@ -14,16 +14,6 @@
|
||||||
services.xserver = {
|
services.xserver = {
|
||||||
# Prevent system sleep after reboot to login screen.
|
# Prevent system sleep after reboot to login screen.
|
||||||
displayManager.gdm.autoSuspend = false;
|
displayManager.gdm.autoSuspend = false;
|
||||||
# Add AMDGPU driver.
|
|
||||||
videoDrivers = [ "amdgpu" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
hardware.opengl = {
|
|
||||||
# Add ROCM annd AMD Vulkan driver.
|
|
||||||
extraPackages = with pkgs; [ rocmPackages.clr.icd amdvlk ];
|
|
||||||
# Add support for 32bit apps.
|
|
||||||
driSupport32Bit = true;
|
|
||||||
extraPackages32 = with pkgs; [ driversi686Linux.amdvlk ];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
systemConfig = {
|
systemConfig = {
|
||||||
|
|
|
@ -1,6 +1,3 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
|
||||||
# and may be overwritten by future invocations. Please make changes
|
|
||||||
# to /etc/nixos/configuration.nix instead.
|
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
|
@ -9,9 +6,23 @@
|
||||||
boot.initrd.availableKernelModules =
|
boot.initrd.availableKernelModules =
|
||||||
[ "xhci_pci" "ahci" "nvme" "usbhid" "sd_mod" ];
|
[ "xhci_pci" "ahci" "nvme" "usbhid" "sd_mod" ];
|
||||||
boot.initrd.kernelModules = [ ];
|
boot.initrd.kernelModules = [ ];
|
||||||
boot.kernelModules = [ "kvm-amd" ];
|
boot.kernelModules = [ "kvm-amd" "amdgpu"];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
services.xserver = {
|
||||||
|
# Add AMDGPU driver.
|
||||||
|
videoDrivers = [ "amdgpu" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
hardware.opengl = {
|
||||||
|
enable = true;
|
||||||
|
# Add ROCM annd AMD Vulkan driver.
|
||||||
|
extraPackages = with pkgs; [ rocmPackages.clr.icd amdvlk ];
|
||||||
|
# Add support for 32bit apps.
|
||||||
|
driSupport32Bit = true;
|
||||||
|
extraPackages32 = with pkgs; [ driversi686Linux.amdvlk ];
|
||||||
|
};
|
||||||
|
|
||||||
fileSystems."/" = {
|
fileSystems."/" = {
|
||||||
device = "/dev/disk/by-uuid/c4217c88-3101-434b-8321-58e2ac89527c";
|
device = "/dev/disk/by-uuid/c4217c88-3101-434b-8321-58e2ac89527c";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
|
|
|
@ -68,11 +68,6 @@ in {
|
||||||
|
|
||||||
networking.hostName = "petalburg"; # Define your hostname.
|
networking.hostName = "petalburg"; # Define your hostname.
|
||||||
|
|
||||||
hardware.sensor.iio.enable = true;
|
|
||||||
|
|
||||||
powerManagement.powertop.enable = true;
|
|
||||||
services.thermald.enable = true;
|
|
||||||
|
|
||||||
environment.systemPackages = [ cs-adjuster cs-adjuster-plasma pp-adjuster ];
|
environment.systemPackages = [ cs-adjuster cs-adjuster-plasma pp-adjuster ];
|
||||||
|
|
||||||
desktopConfig = {
|
desktopConfig = {
|
||||||
|
|
|
@ -1,6 +1,3 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
|
||||||
# and may be overwritten by future invocations. Please make changes
|
|
||||||
# to /etc/nixos/configuration.nix instead.
|
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
|
@ -12,6 +9,33 @@
|
||||||
boot.kernelModules = [ "kvm-intel" ];
|
boot.kernelModules = [ "kvm-intel" ];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
|
||||||
|
# Intel drivers with accelerated video playback support.
|
||||||
|
nixpkgs.config.packageOverrides = pkgs: {
|
||||||
|
intel-vaapi-driver =
|
||||||
|
pkgs.intel-vaapi-driver.override { enableHybridCodec = true; };
|
||||||
|
};
|
||||||
|
|
||||||
|
hardware.opengl = {
|
||||||
|
enable = true;
|
||||||
|
extraPackages = with pkgs; [
|
||||||
|
intel-media-driver # LIBVA_DRIVER_NAME=iHD
|
||||||
|
intel-vaapi-driver # LIBVA_DRIVER_NAME=i965 (older but works better for Firefox/Chromium)
|
||||||
|
libvdpau-va-gl
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.sessionVariables = {
|
||||||
|
LIBVA_DRIVER_NAME = "iHD";
|
||||||
|
}; # Force intel-media-driver
|
||||||
|
|
||||||
|
# Enable auto-rotate and tablet mode.
|
||||||
|
hardware.sensor.iio.enable = true;
|
||||||
|
|
||||||
|
# Save power/better manage heat & fans.
|
||||||
|
powerManagement.powertop.enable = true;
|
||||||
|
services.thermald.enable = true;
|
||||||
|
|
||||||
fileSystems."/" = {
|
fileSystems."/" = {
|
||||||
device = "/dev/disk/by-uuid/ed744c02-8854-4f1a-8e75-ed15f02775e3";
|
device = "/dev/disk/by-uuid/ed744c02-8854-4f1a-8e75-ed15f02775e3";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
|
|
|
@ -42,8 +42,6 @@
|
||||||
|
|
||||||
networking.hostName = "rustboro"; # Define your hostname.
|
networking.hostName = "rustboro"; # Define your hostname.
|
||||||
|
|
||||||
powerManagement.cpuFreqGovernor = "ondemand";
|
|
||||||
|
|
||||||
systemConfig = {
|
systemConfig = {
|
||||||
plymouth.enable = true;
|
plymouth.enable = true;
|
||||||
zramSwap = {
|
zramSwap = {
|
||||||
|
|
|
@ -1,6 +1,3 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
|
||||||
# and may be overwritten by future invocations. Please make changes
|
|
||||||
# to /etc/nixos/configuration.nix instead.
|
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
|
@ -21,6 +18,28 @@
|
||||||
|
|
||||||
fileSystems."/persist" = { neededForBoot = true; };
|
fileSystems."/persist" = { neededForBoot = true; };
|
||||||
|
|
||||||
|
# Otherwise, CPU doesn't automatically clock down.
|
||||||
|
powerManagement.cpuFreqGovernor = "ondemand";
|
||||||
|
|
||||||
|
# Intel drivers with accelerated video playback support.
|
||||||
|
nixpkgs.config.packageOverrides = pkgs: {
|
||||||
|
intel-vaapi-driver =
|
||||||
|
pkgs.intel-vaapi-driver.override { enableHybridCodec = true; };
|
||||||
|
};
|
||||||
|
|
||||||
|
hardware.opengl = {
|
||||||
|
enable = true;
|
||||||
|
extraPackages = with pkgs; [
|
||||||
|
intel-media-driver # LIBVA_DRIVER_NAME=iHD
|
||||||
|
intel-vaapi-driver # LIBVA_DRIVER_NAME=i965 (older but works better for Firefox/Chromium)
|
||||||
|
libvdpau-va-gl
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.sessionVariables = {
|
||||||
|
LIBVA_DRIVER_NAME = "iHD";
|
||||||
|
}; # Force intel-media-driver
|
||||||
|
|
||||||
networking.useDHCP = lib.mkDefault true;
|
networking.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
|
|
Loading…
Reference in a new issue