feat(desktop): do some more settings for better performance.
This commit is contained in:
parent
1afa04235f
commit
d155147165
4 changed files with 38 additions and 2 deletions
|
|
@ -103,11 +103,29 @@
|
||||||
programs.noisetorch.enable = true;
|
programs.noisetorch.enable = true;
|
||||||
|
|
||||||
# Enable sound with pipewire.
|
# Enable sound with pipewire.
|
||||||
services.pulseaudio.enable = false;
|
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
services.pipewire = {
|
services.pipewire = {
|
||||||
enable = true;
|
enable = true;
|
||||||
pulse.enable = true;
|
pulse.enable = true;
|
||||||
|
|
||||||
|
extraConfig.pipewire."92-low-latency" = {
|
||||||
|
"context.properties" = {
|
||||||
|
"default.clock.rate" = 48000;
|
||||||
|
"default.clock.quantum" = 256;
|
||||||
|
"default.clock.min-quantum" = 256;
|
||||||
|
"default.clock.max-quantum" = 256;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
wireplumber.extraConfig = {
|
||||||
|
"10-disable-camera" = {
|
||||||
|
"wireplumber.profiles" = {
|
||||||
|
main = {
|
||||||
|
"monitor.libcamera" = "disabled";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
alsa = {
|
alsa = {
|
||||||
enable = true;
|
enable = true;
|
||||||
support32Bit = true;
|
support32Bit = true;
|
||||||
|
|
@ -175,6 +193,7 @@
|
||||||
crony.sddm.enable = true;
|
crony.sddm.enable = true;
|
||||||
crony.wireguard.enable = true;
|
crony.wireguard.enable = true;
|
||||||
crony.secrets.enable = true;
|
crony.secrets.enable = true;
|
||||||
|
crony.boot.enable = true;
|
||||||
|
|
||||||
# List packages installed in system profile
|
# List packages installed in system profile
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
|
|
|
||||||
16
modules/linux/nixos/boot.nix
Normal file
16
modules/linux/nixos/boot.nix
Normal file
|
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
options = {
|
||||||
|
crony.boot.enable = lib.mkEnableOption "Enable and setup kernel related parameters";
|
||||||
|
};
|
||||||
|
|
||||||
|
config = lib.mkIf config.crony.boot.enable {
|
||||||
|
boot.kernel.sysctl = {
|
||||||
|
"vm.swappiness" = 10;
|
||||||
|
"kernel.nmi_watchdog" = 0;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -25,6 +25,7 @@
|
||||||
./ollama.nix
|
./ollama.nix
|
||||||
./secrets.nix
|
./secrets.nix
|
||||||
./oom.nix
|
./oom.nix
|
||||||
|
./boot.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
crony.bluetooth.enable = lib.mkDefault true;
|
crony.bluetooth.enable = lib.mkDefault true;
|
||||||
|
|
@ -52,4 +53,5 @@
|
||||||
crony.ollama.enable = lib.mkDefault false;
|
crony.ollama.enable = lib.mkDefault false;
|
||||||
crony.secrets.enable = lib.mkDefault false;
|
crony.secrets.enable = lib.mkDefault false;
|
||||||
crony.oom.enable = lib.mkDefault true;
|
crony.oom.enable = lib.mkDefault true;
|
||||||
|
crony.boot.enable = lib.mkDefault false;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,6 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf config.crony.watchdog.disable {
|
config = lib.mkIf config.crony.watchdog.disable {
|
||||||
boot.kernelParams = ["nmi_watchdog=0"];
|
|
||||||
boot.blacklistedKernelModules = ["sp5100_tco"];
|
boot.blacklistedKernelModules = ["sp5100_tco"];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue