2024-04-28 15:54:53 +00:00
|
|
|
# Surface Pro 9
|
2024-05-03 21:32:27 +00:00
|
|
|
{ config, lib, pkgs, modulesPath, ... }: {
|
2024-04-28 00:19:59 +00:00
|
|
|
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
|
|
|
|
2024-04-23 18:46:17 +00:00
|
|
|
boot = {
|
|
|
|
initrd = {
|
2024-04-28 00:19:59 +00:00
|
|
|
availableKernelModules = [ "surface_aggregator" "surface_aggregator_registry" "surface_aggregator_hub" "surface_hid_core" "hid_multitouch" "8250_dw" "intel_lpss" "intel_lpss_pci" "tpm_crb" "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" "surface_kbd" "pinctrl_tigerlake" ];
|
|
|
|
kernelModules = [ "tpm_crb" "surface_aggregator" "surface_aggregator_registry" "surface_aggregator_hub" "surface_hid_core" "surface_hid" "hid_multitouch" "8250_dw" "intel_lpss" "intel_lpss_pci" "surface_kbd" "pinctrl_tigerlake" ];
|
|
|
|
|
|
|
|
luks.devices."luks-bd1fe396-6740-4e7d-af2c-26ca9a3031f1" = {
|
|
|
|
device = "/dev/disk/by-uuid/bd1fe396-6740-4e7d-af2c-26ca9a3031f1";
|
|
|
|
crypttabExtraOpts = [ "tpm2-device=auto" ];
|
|
|
|
};
|
2024-04-23 18:46:17 +00:00
|
|
|
};
|
|
|
|
|
2024-04-28 00:19:59 +00:00
|
|
|
kernelModules = [ "kvm-intel" "tpm_crb" "surface_aggregator" "surface_aggregator_registry" "surface_aggregator_hub" "surface_hid_core" "surface_hid" "hid_multitouch" "8250_dw" "intel_lpss" "intel_lpss_pci" "surface_kbd" "pinctrl_tigerlake" ];
|
2024-04-23 18:46:17 +00:00
|
|
|
extraModulePackages = [ ];
|
|
|
|
};
|
|
|
|
|
|
|
|
fileSystems = {
|
|
|
|
"/" = {
|
2024-04-28 00:19:59 +00:00
|
|
|
device = "/dev/disk/by-uuid/b34afd29-94ff-421b-bb96-8497951abf58";
|
2024-04-23 18:46:17 +00:00
|
|
|
fsType = "btrfs";
|
2024-04-28 15:54:53 +00:00
|
|
|
options = [ "subvol=@,compress=zstd" ];
|
2024-04-23 18:46:17 +00:00
|
|
|
};
|
2024-04-28 00:19:59 +00:00
|
|
|
|
2024-04-23 18:46:17 +00:00
|
|
|
"/boot" = {
|
2024-04-28 00:19:59 +00:00
|
|
|
device = "/dev/disk/by-uuid/DD2A-9C83";
|
2024-04-23 18:46:17 +00:00
|
|
|
fsType = "vfat";
|
|
|
|
};
|
|
|
|
};
|
2024-04-28 00:19:59 +00:00
|
|
|
|
|
|
|
swapDevices = [
|
|
|
|
{ device = "/dev/disk/by-uuid/8c2519d9-3e47-4aa1-908d-98b1aa8b909d"; }
|
|
|
|
];
|
2024-04-23 18:46:17 +00:00
|
|
|
|
|
|
|
networking = {
|
|
|
|
useDHCP = lib.mkDefault true;
|
|
|
|
hostName = "Khanda";
|
|
|
|
};
|
|
|
|
|
|
|
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
|
|
|
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
2024-04-28 15:54:53 +00:00
|
|
|
|
|
|
|
# Install/configure additional drivers, particularly for touch
|
|
|
|
environment.systemPackages = with pkgs; [
|
|
|
|
libwacom-surface
|
|
|
|
];
|
|
|
|
microsoft-surface = {
|
|
|
|
ipts.enable = true;
|
|
|
|
surface-control.enable = true;
|
|
|
|
};
|
2024-04-29 17:17:24 +00:00
|
|
|
|
|
|
|
# FIXME: Use default kernel to avoid full kernel rebuilds
|
2024-04-30 20:44:48 +00:00
|
|
|
# boot.kernelPackages = lib.mkForce pkgs.linuxPackages_latest;
|
2024-04-23 18:46:17 +00:00
|
|
|
}
|