3
0
Fork 0
forked from mirrors/nixpkgs

Add module for b43 firmware

This commit is contained in:
Shea Levy 2012-07-13 23:54:41 -04:00
parent 57d74e6f4f
commit e3337c7f05
2 changed files with 31 additions and 0 deletions

View file

@ -0,0 +1,30 @@
{pkgs, config, ...}:
let kernelVersion = config.boot.kernelPackages.kernel.version; in
{
###### interface
options = {
networking.enableB43Firmware = pkgs.lib.mkOption {
default = false;
type = pkgs.lib.types.bool;
description = ''
Turn on this option if you want firmware for the NICs supported by the b43 module.
'';
};
};
###### implementation
config = pkgs.lib.mkIf config.networking.enableB43Firmware {
hardware.firmware = if builtins.lessThan (builtins.compareVersions kernelVersion "3.2") 0 then
throw "b43 firmware for kernels older than 3.2 not packaged yet!" else
[ pkgs.b43Firmware_5_1_138 ];
};
}

View file

@ -15,6 +15,7 @@
./config/unix-odbc-drivers.nix
./config/users-groups.nix
./hardware/cpu/intel-microcode.nix
./hardware/network/b43.nix
./hardware/network/intel-2100bg.nix
./hardware/network/intel-2200bg.nix
./hardware/network/intel-3945abg.nix