From 7d0974ea92f35bc711b881db5b32a7406d056cd5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20R=C3=B6ger?= Date: Thu, 2 Apr 2026 13:08:57 +0200 Subject: [PATCH] System Gen230 @ 2026-04-02-13:08:57 by jonas@comfy-station --- hosts/comfy-station/configuration.nix | 1 + hosts/comfy-station/default.nix | 1 + modules/system/ntsync.nix | 24 ++++++++++++++++++++++++ 3 files changed, 26 insertions(+) create mode 100644 modules/system/ntsync.nix diff --git a/hosts/comfy-station/configuration.nix b/hosts/comfy-station/configuration.nix index 17de184..457bee0 100644 --- a/hosts/comfy-station/configuration.nix +++ b/hosts/comfy-station/configuration.nix @@ -42,6 +42,7 @@ image-raw-processing = true; video-editing-light = true; }; + hive.ntsync.enable = true; # system packages environment.systemPackages = with pkgs; [ diff --git a/hosts/comfy-station/default.nix b/hosts/comfy-station/default.nix index e787f3b..db89514 100644 --- a/hosts/comfy-station/default.nix +++ b/hosts/comfy-station/default.nix @@ -26,6 +26,7 @@ self.nixosModules.openhantek self.nixosModules.firefox self.nixosModules.kdeconnect + self.nixosModules.ntsync ]; }; } diff --git a/modules/system/ntsync.nix b/modules/system/ntsync.nix new file mode 100644 index 0000000..9a86b49 --- /dev/null +++ b/modules/system/ntsync.nix @@ -0,0 +1,24 @@ +{ + flake.nixosModules.ntsync = { + config, + lib, + pkgs, + ... + }: let + current_kernel_pkgs = pkgs.linuxPackages_latest; + current_kernel_version = current_kernel_pkgs.kernel.version; + cfg = config.hive.ntsync; + in { + options.hive.ntsync.enable = lib.mkEnableOption "Enable the nt-sync kernel driver. Enforces a minimum kernel version of 6.14."; + + config = lib.mkIf cfg.enable { + # Require at least 6.14 for the new nt-sync driver + boot.kernelPackages = + if lib.versionAtLeast current_kernel_version "6.14" + then current_kernel_pkgs + else pkgs.linuxPackages_6_14; + + boot.kernelModules = ["ntsync"]; + }; + }; +}