diff options
author | MinerSebas <scherthan_sebastian@web.de> | 2023-07-20 22:20:33 +0200 |
---|---|---|
committer | MinerSebas <scherthan_sebastian@web.de> | 2023-07-25 17:07:00 +0200 |
commit | 7c309898bcac42058a4e80e7f8bb69436cefb265 (patch) | |
tree | dd4b8c26d781bc460cb6336fbd4de56d2a9e4690 /nixos | |
parent | 684c17c429c42515bafb3ad775d2a710947f3d67 (diff) |
nixos/usb-modeswitch: Rename module from usbWwan
Diffstat (limited to 'nixos')
-rw-r--r-- | nixos/modules/hardware/usb-modeswitch.nix (renamed from nixos/modules/hardware/usb-wwan.nix) | 13 | ||||
-rw-r--r-- | nixos/modules/module-list.nix | 2 |
2 files changed, 11 insertions, 4 deletions
diff --git a/nixos/modules/hardware/usb-wwan.nix b/nixos/modules/hardware/usb-modeswitch.nix index 69673872cf9b7..773891b0032f2 100644 --- a/nixos/modules/hardware/usb-wwan.nix +++ b/nixos/modules/hardware/usb-modeswitch.nix @@ -7,12 +7,15 @@ with lib; options = { - hardware.usbWwan = { + hardware.usb-modeswitch = { enable = mkOption { type = types.bool; default = false; description = lib.mdDoc '' - Enable this option to support USB WWAN adapters. + Enable this option to support certain USB WLAN and WWAN adapters. + + These network adapters initial present themselves as Flash Drives containing their drivers. + This option enables automatic switching to the networking mode. ''; }; }; @@ -20,7 +23,11 @@ with lib; ###### implementation - config = mkIf config.hardware.usbWwan.enable { + imports = [ + (mkRenamedOptionModule ["hardware" "usbWwan" ] ["hardware" "usb-modeswitch" ]) + ]; + + config = mkIf config.hardware.usb-modeswitch.enable { # Attaches device specific handlers. services.udev.packages = with pkgs; [ usb-modeswitch-data ]; diff --git a/nixos/modules/module-list.nix b/nixos/modules/module-list.nix index 5510944b21525..95d689fa156b0 100644 --- a/nixos/modules/module-list.nix +++ b/nixos/modules/module-list.nix @@ -93,8 +93,8 @@ ./hardware/tuxedo-keyboard.nix ./hardware/ubertooth.nix ./hardware/uinput.nix + ./hardware/usb-modeswitch.nix ./hardware/usb-storage.nix - ./hardware/usb-wwan.nix ./hardware/video/amdgpu-pro.nix ./hardware/video/bumblebee.nix ./hardware/video/capture/mwprocapture.nix |