fix screen flickering and keyboard not working

This commit is contained in:
EdenQwQ 2026-03-23 23:02:16 +08:00
parent 658b24fc7e
commit 9c2386d19e
7 changed files with 74 additions and 51 deletions

View file

@ -1,47 +1,63 @@
# 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,
...
}:
{
imports =
[ (modulesPath + "/hardware/cpu/intel-npu.nix")
(modulesPath + "/installer/scan/not-detected.nix")
];
imports = [
(modulesPath + "/hardware/cpu/intel-npu.nix")
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "usbhid" "sd_mod" ];
boot.initrd.availableKernelModules = [
"xhci_pci"
"thunderbolt"
"nvme"
"usb_storage"
"usbhid"
"sd_mod"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/f6ac48f0-6517-4c80-af9e-f81178d04f94";
fsType = "btrfs";
};
fileSystems."/" = {
device = "/dev/disk/by-uuid/f6ac48f0-6517-4c80-af9e-f81178d04f94";
fsType = "btrfs";
};
fileSystems."/nix" =
{ device = "/dev/disk/by-uuid/f6ac48f0-6517-4c80-af9e-f81178d04f94";
fsType = "btrfs";
options = [ "subvol=nix" ];
};
fileSystems."/nix" = {
device = "/dev/disk/by-uuid/f6ac48f0-6517-4c80-af9e-f81178d04f94";
fsType = "btrfs";
options = [ "subvol=nix" ];
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/D519-CFA4";
fsType = "vfat";
options = [ "fmask=0077" "dmask=0077" ];
};
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/D519-CFA4";
fsType = "vfat";
options = [
"fmask=0077"
"dmask=0077"
];
};
fileSystems."/home" =
{ device = "/dev/disk/by-uuid/4360a1b0-918a-41d7-9bba-31da7e5974ff";
fsType = "btrfs";
};
fileSystems."/home" = {
device = "/dev/disk/by-uuid/4360a1b0-918a-41d7-9bba-31da7e5974ff";
fsType = "btrfs";
};
swapDevices = [
{
device = "/var/lib/swapfile";
size = 16 * 1024;
}
];
];
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.npu.enable = true;

View file

@ -1,6 +1,14 @@
{ host, ... }:
{ host, pkgs, ... }:
{
imports = [ ./hardware-configuration.nix ];
system.stateVersion = "26.05";
networking.hostName = host;
boot.kernelParams = [
"i8042.reset"
"i8042.nomux"
"i8042.nopnp"
"i8042.dumbkbd"
"xe.force_probe=*"
"xe.enable_psr=0"
];
}