No description
Find a file
Tsubajashi bafd15d665 Add AIC8800 USB Wi-Fi driver as a NixOS module
This commit introduces the AIC8800 USB Wi-Fi driver, including firmware installation and configurable udev rules for USB disk ejection and power management. The driver supports kernel versions 6.17 and above, ensuring compatibility with recent changes in the Linux kernel. Documentation is also provided in README.md for usage and configuration.
2025-12-14 04:48:26 +01:00
usr/src/AIC8800 Refactor timer management functions to use rwnx_timer_delete and rwnx_timer_delete_sync for better compatibility with kernel version 6.17.0 and above. This change ensures consistent timer handling across various components in the AIC8800 driver. 2025-11-25 16:58:12 +01:00
aic8800d80fdrvpackage.deb hopes and dreams 2025-11-19 01:52:34 +01:00
AX900 Deb驱动安装教程_Linux_V3.0.pdf hopes and dreams 2025-11-19 01:52:34 +01:00
control.tar.gz hopes and dreams 2025-11-19 01:52:34 +01:00
data.tar.gz hopes and dreams 2025-11-19 01:52:34 +01:00
debian-binary hopes and dreams 2025-11-19 01:52:34 +01:00
flake.nix Add AIC8800 USB Wi-Fi driver as a NixOS module 2025-12-14 04:48:26 +01:00
nixos-module.nix Add AIC8800 USB Wi-Fi driver as a NixOS module 2025-12-14 04:48:26 +01:00
README.md Add AIC8800 USB Wi-Fi driver as a NixOS module 2025-12-14 04:48:26 +01:00

AIC8800 USB Wi-Fi Driver for NixOS

This flake provides the AIC8800 USB Wi-Fi driver (used by UGREEN AX900 and similar adapters) as a NixOS module.

Features

  • Kernel 6.17+ compatibility (includes fixes for timer and cfg80211 API changes)
  • Automatic firmware installation
  • Configurable udev rules for USB disk ejection and power management

Usage

In your flake.nix

{
  inputs = {
    nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
    aic8800 = {
      url = "git+https://git.tvpdev.de/Tsubajashi/alc8800";
      # Or use a local path:
      # url = "path:/path/to/alc8800";
    };
  };

  outputs = { self, nixpkgs, aic8800, ... }: {
    nixosConfigurations.your-host = nixpkgs.lib.nixosSystem {
      system = "x86_64-linux";
      specialArgs = {
        aic8800-src = aic8800;  # Pass the flake source
      };
      modules = [
        aic8800.nixosModules.default
        ./configuration.nix
      ];
    };
  };
}

In your configuration.nix

{
  hardware.aic8800 = {
    enable = true;
    # Optional: enable udev rules (default: true)
    enableUdevRules = true;
  };
}

Alternative: Using as a flake input with specialArgs

If you're already using aic8800-src as a flake input:

{
  inputs = {
    aic8800-src = {
      url = "git+https://git.tvpdev.de/Tsubajashi/alc8800";
      flake = false;
    };
    aic8800 = {
      url = "git+https://git.tvpdev.de/Tsubajashi/alc8800";
    };
  };

  outputs = { self, nixpkgs, aic8800, aic8800-src, ... }: {
    nixosConfigurations.your-host = nixpkgs.lib.nixosSystem {
      system = "x86_64-linux";
      specialArgs = {
        aic8800-src = aic8800-src;  # Use the flake = false input
      };
      modules = [
        aic8800.nixosModules.default
        ./configuration.nix
      ];
    };
  };
}

What it does

When enabled, the module:

  1. Builds the kernel modules (aic_load_fw and aic8800_fdrv) for your kernel version
  2. Installs firmware to /lib/firmware/aic8800D80/
  3. Loads the modules automatically at boot
  4. Configures udev rules to:
    • Automatically eject USB storage devices that appear when the adapter is plugged in (switches to Wi-Fi mode)
    • Keep the Wi-Fi interface awake to avoid autosuspend issues

Kernel Compatibility

The driver includes compatibility fixes for Linux kernel 6.17+:

  • Timer API changes (del_timertimer_delete)
  • cfg80211 API changes (additional parameter for spurious frame handlers)

Troubleshooting

If you get an error about aic8800-src not being found, make sure you're passing it via specialArgs in your flake.nix.