1{ pkgs, lib, config, ... }:
2
3with lib;
4
5let
6 cfg = config.hardware.new-lg4ff;
7 kernelPackages = config.boot.kernelPackages;
8in {
9 options.hardware.new-lg4ff = {
10 enable = mkOption {
11 type = types.bool;
12 default = false;
13 description = ''
14 Enables improved Linux module drivers for Logitech driving wheels.
15 This will replace the existing in-kernel hid-logitech modules.
16 Works most notably on the Logitech G25, G27, G29 and Driving Force (GT).
17 '';
18 };
19 };
20
21 config = lib.mkIf cfg.enable {
22 boot = {
23 extraModulePackages = [ kernelPackages.new-lg4ff ];
24 kernelModules = [ "hid-logitech-new" ];
25 };
26 };
27
28 meta.maintainers = with lib.maintainers; [ matthiasbenaets ];
29}