diff options
Diffstat (limited to 'nixpkgs/nixos/modules/hardware/usb-wwan.nix')
-rw-r--r-- | nixpkgs/nixos/modules/hardware/usb-wwan.nix | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/nixpkgs/nixos/modules/hardware/usb-wwan.nix b/nixpkgs/nixos/modules/hardware/usb-wwan.nix new file mode 100644 index 00000000000..2d20421586a --- /dev/null +++ b/nixpkgs/nixos/modules/hardware/usb-wwan.nix @@ -0,0 +1,26 @@ +{ config, lib, pkgs, ... }: + +with lib; + +{ + ###### interface + + options = { + + hardware.usbWwan = { + enable = mkOption { + type = types.bool; + default = false; + description = '' + Enable this option to support USB WWAN adapters. + ''; + }; + }; + }; + + ###### implementation + + config = mkIf config.hardware.usbWwan.enable { + services.udev.packages = with pkgs; [ usb-modeswitch-data ]; + }; +} |