How to install the linux-firmware package in Gentoo

The microcode image (a.k.a. firmware) file for a driver can be installed from the distribution’s package manager. For example, in Gentoo the microcode package for the Intel Wireless WiFi 5100AGN, 5300AGN and 5350AGN controllers is named sys-firmware/iwl5000-ucode. However, microcode files are also available in a single package named sys-kernel/linux-firmware and can be installed using that package instead. However, to me at least, it was not obvious how to do this and the elog output when you merge the linux-firmware package is not particularly helpful:

* If you are only interested in particular firmware files, edit the saved
* configfile and remove those that you do not want.
>>> sys-kernel/linux-firmware-20120816 merged.

In other words, I used to enter the following command to install the microcode for the Intel 5300AGN WiFi controller:

emerge sys-firmware/iwl5000-ucode

and that command installed only the microcode files needed for that WiFi controller, but the following command also installed many other microcode files for hardware that my laptop does not have:

emerge sys-kernel/linux-firmware

You can see below what the above command installs in /lib/firmware/ (/lib64/firmware/ if you have a 64-bit installation) in the case of the package linux-firmware-20120816.

# ls /lib/firmware/
3com bnx2 emi26 iwlwifi-4965-2.ucode LICENCE.broadcom_bcm43xx matrox qlogic s2250_loader.fw usbdux
acenic bnx2x emi62 iwlwifi-5000-1.ucode LICENCE.chelsio_firmware mrvl r128 sb16 usbduxfast_firmware.bin
ACX100_USB.bin bnx2x-e1-4.8.53.0.fw ene-ub6250 iwlwifi-5000-2.ucode LICENCE.ene_firmware mts_cdma.fw radeon slicoss usbdux_firmware.bin
adaptec bnx2x-e1-5.2.13.0.fw ess iwlwifi-5000-5.ucode LICENCE.i2400m mts_edge.fw RADIO0d.BIN STLC2500_R4_00_03.ptc usbduxsigma_firmware.bin
advansys bnx2x-e1-5.2.7.0.fw f2255usb.bin iwlwifi-5150-2.ucode LICENCE.iwlwifi_firmware mts_gsm.fw RADIO11.BIN STLC2500_R4_00_06.ssf v4l-cx231xx-avcore-01.fw
af9005.fw bnx2x-e1h-4.8.53.0.fw GPL-3 iwlwifi-6000-4.ucode LICENCE.Marvell mts_mt9234mu.fw RADIO15.BIN STLC2500_R4_02_02_WLAN.ssf v4l-cx23418-apu.fw
agere_ap_fw.bin bnx2x-e1h-5.2.13.0.fw htc_7010.fw iwlwifi-6000g2a-5.ucode LICENCE.mwl8335 mts_mt9234zba.fw README STLC2500_R4_02_04.ptc v4l-cx23418-cpu.fw
agere_sta_fw.bin bnx2x-e1h-5.2.7.0.fw htc_9271.fw iwlwifi-6000g2a-6.ucode LICENCE.myri10ge_firmware mwl8k rt2561.bin sun v4l-cx23418-dig.fw
ar3k brcm i2400m-fw-usb-1.4.sbcf iwlwifi-6000g2b-5.ucode LICENCE.OLPC myri10ge_ethp_z8e.dat rt2561s.bin sxg v4l-cx23885-avcore-01.fw
ar7010_1_1.fw cis i2400m-fw-usb-1.5.sbcf iwlwifi-6000g2b-6.ucode LICENCE.phanfw myri10ge_eth_z8e.dat rt2661.bin TDA7706_OM_v2.5.1_boot.txt v4l-cx23885-enc.fw
ar7010.fw configure i6050-fw-usb-1.5.sbcf iwlwifi-6050-4.ucode LICENCE.qla2xxx myri10ge_rss_ethp_z8e.dat rt2860.bin TDA7706_OM_v3.0.2_boot.txt v4l-cx25840.fw
ar9170-1.fw cpia2 intelliport2.bin iwlwifi-6050-5.ucode LICENCE.ralink-firmware.txt myri10ge_rss_eth_z8e.dat rt2870.bin tehuti vicam
ar9170-2.fw cxgb3 isci kaweth LICENCE.rtlwifi_firmware.txt myricom rt3070.bin ti_3410.fw vntwusb.fw
ar9271.fw cxgb4 iwlwifi-1000-3.ucode keyspan LICENCE.tda7706-firmware.txt ositech rt3071.bin ti_5052.fw vxge
ath3k-1.fw dabusb iwlwifi-1000-5.ucode keyspan_pda LICENCE.ti-connectivity phanfw.bin rt3090.bin TIACX111.BIN WHENCE
ath6k dsp56k iwlwifi-100-5.ucode korg LICENCE.ueagle-atm4-firmware ql2100_fw.bin rt3290.bin ti-connectivity whiteheat.fw
atmsar11.fw dvb-fe-xc5000-1.6.114.fw iwlwifi-105-6.ucode lbtf_usb.bin LICENCE.via_vt6656 ql2200_fw.bin rt73.bin tigon whiteheat_loader.fw
av7110 dvb-usb-dib0700-1.20.fw iwlwifi-135-6.ucode lgs8g75.fw LICENCE.xc5000 ql2300_fw.bin RTL8192E tlg2300_firmware.bin WLANGEN.BIN
BCM2033-FW.bin dvb-usb-terratec-h5-drxk.fw iwlwifi-2000-6.ucode libertas LICENSE.dib0700 ql2322_fw.bin rtl_nic tr_smctr.bin yam
BCM2033-MD.hex e100 iwlwifi-2030-6.ucode LICENCE.agere LICENSE.radeon ql2400_fw.bin rtlwifi ttusb-budget yamaha
BCM-LEGAL.txt edgeport iwlwifi-3945-2.ucode LICENCE.atheros_firmware Makefile ql2500_fw.bin s2250.fw ueagle-atm zd1211

But I only need the files iwlwifi-5000-*.ucode, not all those other microcode files, so here is what I do:

# emerge linux-firmware
# cp /etc/portage/savedconfig/sys-kernel/linux-firmware-20120816 /home/fitzcarraldo/linux-firmware-20120816.bak
# awk '{ printf "#"; print }' /home/fitzcarraldo/linux-firmware-20120816.bak > /etc/portage/savedconfig/sys-kernel/linux-firmware-20120816
# nano /etc/portage/savedconfig/sys-kernel/linux-firmware-20120816 # Remove the comment symbol from the files I want to install.
# cp /etc/portage/savedconfig/sys-kernel/linux-firmware-20120816 /home/fitzcarraldo/linux-firmware-20120816 # I like to keep a backup of the edited file too.
# USE="savedconfig" emerge linux-firmware

Of course you can add the savedconfig USE flag in /etc/portage/package.use instead, so that you do not have to type USE=”savedconfig” every time:

# echo "sys-kernel/linux-firmware savedconfig" >> /etc/portage/package.use

For example, I edited /etc/portage/savedconfig/sys-kernel/linux-firmware-20120816 so that the lines are commented out for firmware my laptop does not need. I could have deleted the unwanted lines instead, but I preferred to comment out unwanted lines in case I made a mistake. The file now looks like this:

# Remove files that shall not be installed from this list.
#3com/typhoon.bin
#3com/3C359.bin
#acenic/tg1.bin
#acenic/tg2.bin
#adaptec/starfire_rx.bin
#adaptec/starfire_tx.bin
#advansys/3550.bin
#advansys/38C1600.bin
#advansys/38C0800.bin
#advansys/mcode.bin
#agere_ap_fw.bin
#agere_sta_fw.bin
#ar3k/ramps_0x01020201_26.dfu
#ar3k/ramps_0x01020200_40.dfu
#ar3k/AthrBT_0x11020000.dfu
#ar3k/1020201/RamPatch.txt
#ar3k/1020201/PS_ASIC.pst
#ar3k/1020200/RamPatch.txt
#ar3k/1020200/ar3kbdaddr.pst
#ar3k/1020200/PS_ASIC.pst
#ar3k/ramps_0x11020000_40.dfu
#ar3k/AthrBT_0x01020201.dfu
#ar3k/30101/RamPatch.txt
#ar3k/30101/ar3kbdaddr.pst
#ar3k/30101/PS_ASIC.pst
#ar3k/30000/RamPatch.txt
#ar3k/30000/ar3kbdaddr.pst
#ar3k/30000/PS_ASIC.pst
#ar3k/30101coex/PS_ASIC_aclHighPri.pst
#ar3k/30101coex/PS_ASIC_aclLowPri.pst
#ar3k/30101coex/RamPatch.txt
#ar3k/30101coex/ar3kbdaddr.pst
#ar3k/30101coex/PS_ASIC.pst
#ar3k/ramps_0x01020001_26.dfu
#ar3k/AthrBT_0x31010000.dfu
#ar3k/AthrBT_0x01020001.dfu
#ar3k/ramps_0x01020201_40.dfu
#ar3k/ramps_0x01020200_26.dfu
#ar3k/AthrBT_0x01020200.dfu
#ar3k/ramps_0x31010000_40.dfu
#ar7010_1_1.fw
#ar7010.fw
#ar9170-1.fw
#ar9170-2.fw
#ar9271.fw
#ath3k-1.fw
#ath6k/AR6002/athwlan.bin.z77
#ath6k/AR6002/eeprom.bin
#ath6k/AR6002/data.patch.hw2_0.bin
#ath6k/AR6002/eeprom.data
#ath6k/AR6004/hw1.2/bdata.bin
#ath6k/AR6004/hw1.2/fw-2.bin
#ath6k/AR6003.1/hw2.1.1/athwlan.bin
#ath6k/AR6003.1/hw2.1.1/bdata.SD31.bin
#ath6k/AR6003.1/hw2.1.1/data.patch.bin
#ath6k/AR6003.1/hw2.1.1/bdata.WB31.bin
#ath6k/AR6003.1/hw2.1.1/endpointping.bin
#ath6k/AR6003.1/hw2.1.1/otp.bin
#ath6k/AR6003.1/hw2.1.1/bdata.SD32.bin
#ath6k/AR6003/hw1.0/athwlan.bin.z77
#ath6k/AR6003/hw1.0/otp.bin.z77
#ath6k/AR6003/hw1.0/bdata.SD31.bin
#ath6k/AR6003/hw1.0/data.patch.bin
#ath6k/AR6003/hw1.0/bdata.WB31.bin
#ath6k/AR6003/hw1.0/bdata.SD32.bin
#ath6k/AR6003/hw2.0/athwlan.bin.z77
#ath6k/AR6003/hw2.0/otp.bin.z77
#ath6k/AR6003/hw2.0/bdata.SD31.bin
#ath6k/AR6003/hw2.0/data.patch.bin
#ath6k/AR6003/hw2.0/bdata.WB31.bin
#ath6k/AR6003/hw2.0/bdata.SD32.bin
#ath6k/AR6003/hw2.1.1/athwlan.bin
#ath6k/AR6003/hw2.1.1/bdata.SD31.bin
#ath6k/AR6003/hw2.1.1/fw-3.bin
#ath6k/AR6003/hw2.1.1/data.patch.bin
#ath6k/AR6003/hw2.1.1/bdata.WB31.bin
#ath6k/AR6003/hw2.1.1/endpointping.bin
#ath6k/AR6003/hw2.1.1/otp.bin
#ath6k/AR6003/hw2.1.1/fw-2.bin
#ath6k/AR6003/hw2.1.1/bdata.SD32.bin
#atmsar11.fw
#av7110/Boot.S
#av7110/bootcode.bin
#av7110/Makefile
#bnx2/bnx2-rv2p-06-6.0.15.fw
#bnx2/bnx2-rv2p-09-6.0.17.fw
#bnx2/bnx2-rv2p-06-4.6.16.fw
#bnx2/bnx2-rv2p-09-5.0.0.j3.fw
#bnx2/bnx2-rv2p-06-5.0.0.j3.fw
#bnx2/bnx2-mips-09-5.0.0.j15.fw
#bnx2/bnx2-rv2p-09-4.6.15.fw
#bnx2/bnx2-rv2p-09ax-6.0.17.fw
#bnx2/bnx2-mips-06-5.0.0.j3.fw
#bnx2/bnx2-mips-06-6.2.3.fw
#bnx2/bnx2-mips-09-5.0.0.j9.fw
#bnx2/bnx2-rv2p-09-5.0.0.j10.fw
#bnx2/bnx2-mips-09-6.2.1b.fw
#bnx2/bnx2-rv2p-09ax-5.0.0.j3.fw
#bnx2/bnx2-mips-06-6.0.15.fw
#bnx2/bnx2-mips-09-6.2.1.fw
#bnx2/bnx2-mips-09-5.0.0.j3.fw
#bnx2/bnx2-rv2p-09ax-5.0.0.j10.fw
#bnx2/bnx2-mips-06-5.0.0.j6.fw
#bnx2/bnx2-mips-06-4.6.16.fw
#bnx2/bnx2-mips-06-6.2.1.fw
#bnx2/bnx2-mips-09-6.2.1a.fw
#bnx2/bnx2-mips-09-4.6.17.fw
#bnx2/bnx2-mips-09-6.0.17.fw
#bnx2x/bnx2x-e1h-6.2.5.0.fw
#bnx2x/bnx2x-e1-7.2.16.0.fw
#bnx2x/bnx2x-e1h-6.2.9.0.fw
#bnx2x/bnx2x-e2-6.2.5.0.fw
#bnx2x/bnx2x-e2-6.0.34.0.fw
#bnx2x/bnx2x-e2-6.2.9.0.fw
#bnx2x/bnx2x-e1-7.0.23.0.fw
#bnx2x/bnx2x-e1-6.2.9.0.fw
#bnx2x/bnx2x-e1-7.2.51.0.fw
#bnx2x/bnx2x-e1h-7.0.23.0.fw
#bnx2x/bnx2x-e1h-6.0.34.0.fw
#bnx2x/bnx2x-e2-7.0.29.0.fw
#bnx2x/bnx2x-e1h-7.2.51.0.fw
#bnx2x/bnx2x-e1h-7.0.29.0.fw
#bnx2x/bnx2x-e1h-7.2.16.0.fw
#bnx2x/bnx2x-e1-6.2.5.0.fw
#bnx2x/bnx2x-e2-7.0.20.0.fw
#bnx2x/bnx2x-e1-6.0.34.0.fw
#bnx2x/bnx2x-e1-7.0.29.0.fw
#bnx2x/bnx2x-e2-7.2.51.0.fw
#bnx2x/bnx2x-e2-7.0.23.0.fw
#bnx2x/bnx2x-e2-7.2.16.0.fw
#bnx2x/bnx2x-e1h-7.0.20.0.fw
#bnx2x/bnx2x-e1-7.0.20.0.fw
#bnx2x-e1-4.8.53.0.fw
#bnx2x-e1-5.2.13.0.fw
#bnx2x-e1-5.2.7.0.fw
#bnx2x-e1h-4.8.53.0.fw
#bnx2x-e1h-5.2.13.0.fw
#bnx2x-e1h-5.2.7.0.fw
#brcm/bcm43xx-0.fw
#brcm/brcmfmac4329.bin
#brcm/brcmfmac43236b.bin
#brcm/brcmfmac4330.bin
#brcm/brcmfmac4334.bin
#brcm/bcm4329-fullmac-4.bin
#brcm/bcm43xx_hdr-0.fw
#cis/MT5634ZLX.cis
#cis/SW_555_SER.cis
#cis/COMpad2.cis
#cis/SW_7xx_SER.cis
#cis/NE2K.cis
#cis/src/MT5634ZLX.cis
#cis/src/COMpad2.cis
#cis/src/NE2K.cis
#cis/src/DP83903.cis
#cis/src/RS-COM-2P.cis
#cis/src/LA-PCM.cis
#cis/src/COMpad4.cis
#cis/src/PE-200.cis
#cis/src/tamarack.cis
#cis/src/3CCFEM556.cis
#cis/src/PCMLM28.cis
#cis/src/3CXEM556.cis
#cis/src/PE520.cis
#cis/DP83903.cis
#cis/RS-COM-2P.cis
#cis/LA-PCM.cis
#cis/SW_8xx_SER.cis
#cis/COMpad4.cis
#cis/PE-200.cis
#cis/tamarack.cis
#cis/3CCFEM556.cis
#cis/Makefile
#cis/PCMLM28.cis
#cis/3CXEM556.cis
#cis/PE520.cis
configure
#cpia2/stv0672_vp4.bin
#cxgb3/t3b_psram-1.1.0.bin
#cxgb3/ael2005_twx_edc.bin
#cxgb3/t3fw-7.4.0.bin
#cxgb3/t3fw-7.1.0.bin
#cxgb3/t3c_psram-1.1.0.bin
#cxgb3/t3fw-7.12.0.bin
#cxgb3/t3fw-7.10.0.bin
#cxgb3/ael2020_twx_edc.bin
#cxgb3/t3fw-7.0.0.bin
#cxgb3/ael2005_opt_edc.bin
#cxgb4/t4fw.bin
#cxgb4/t4fw-1.4.23.0.bin
#dabusb/bitstream.bin
#dabusb/firmware.fw
#dsp56k/bootstrap.bin
#dsp56k/concat-bootstrap.pl
#dsp56k/bootstrap.asm
#dsp56k/Makefile
#dvb-fe-xc5000-1.6.114.fw
#dvb-usb-dib0700-1.20.fw
#dvb-usb-terratec-h5-drxk.fw
#e100/d101m_ucode.bin
#e100/d102e_ucode.bin
#e100/d101s_ucode.bin
#edgeport/boot.fw
#edgeport/down.fw
#edgeport/down2.fw
#edgeport/down3.bin
#edgeport/boot2.fw
#emi26/bitstream.fw
#emi26/loader.fw
#emi26/firmware.fw
#emi62/bitstream.fw
#emi62/loader.fw
#emi62/spdif.fw
#emi62/midi.fw
#ene-ub6250/msp_rdwr.bin
#ene-ub6250/sd_init1.bin
#ene-ub6250/sd_init2.bin
#ene-ub6250/ms_init.bin
#ene-ub6250/ms_rdwr.bin
#ene-ub6250/sd_rdwr.bin
#ess/maestro3_assp_minisrc.fw
#ess/maestro3_assp_kernel.fw
#f2255usb.bin
GPL-3
#htc_7010.fw
#htc_9271.fw
#i2400m-fw-usb-1.4.sbcf
#i2400m-fw-usb-1.5.sbcf
#i6050-fw-usb-1.5.sbcf
#intelliport2.bin
#isci/create_fw.c
#isci/README
#isci/probe_roms.h
#isci/isci_firmware.bin
#isci/create_fw.h
#isci/Makefile
#iwlwifi-1000-3.ucode
#iwlwifi-1000-5.ucode
#iwlwifi-100-5.ucode
#iwlwifi-105-6.ucode
#iwlwifi-135-6.ucode
#iwlwifi-2000-6.ucode
#iwlwifi-2030-6.ucode
#iwlwifi-3945-2.ucode
#iwlwifi-4965-2.ucode
iwlwifi-5000-1.ucode
iwlwifi-5000-2.ucode
iwlwifi-5000-5.ucode
#iwlwifi-5150-2.ucode
#iwlwifi-6000-4.ucode
#iwlwifi-6000g2a-5.ucode
#iwlwifi-6000g2a-6.ucode
#iwlwifi-6000g2b-5.ucode
#iwlwifi-6000g2b-6.ucode
#iwlwifi-6050-4.ucode
#iwlwifi-6050-5.ucode
#kaweth/trigger_code_fix.bin
#kaweth/new_code.bin
#kaweth/new_code_fix.bin
#kaweth/trigger_code.bin
#keyspan/usa19qi.fw
#keyspan/usa28xb.fw
#keyspan/usa28x.fw
#keyspan/usa49wlc.fw
#keyspan/usa49w.fw
#keyspan/usa19w.fw
#keyspan/usa28xa.fw
#keyspan/usa28.fw
#keyspan/usa19qw.fw
#keyspan/mpr.fw
#keyspan/usa18x.fw
#keyspan/usa19.fw
#keyspan_pda/keyspan_pda.S
#keyspan_pda/xircom_pgs.S
#keyspan_pda/keyspan_pda.fw
#keyspan_pda/xircom_pgs.fw
#keyspan_pda/Makefile
#korg/k1212.dsp
#lbtf_usb.bin
#lgs8g75.fw
#libertas/gspi8682.bin
#libertas/sd8682_helper.bin
#libertas/gspi8688_helper.bin
#libertas/gspi8686_v9.bin
#libertas/cf8385_helper.bin
#libertas/usb8682.bin
#libertas/cf8381_helper.bin
#libertas/usb8388_v9.bin
#libertas/sd8686_v8.bin
#libertas/sd8385_helper.bin
#libertas/sd8686_v9.bin
#libertas/sd8686_v9_helper.bin
#libertas/cf8381.bin
#libertas/gspi8686_v9_helper.bin
#libertas/usb8388_v5.bin
#libertas/gspi8682_helper.bin
#libertas/lbtf_sdio.bin
#libertas/gspi8688.bin
#libertas/sd8385.bin
#libertas/sd8682.bin
#libertas/usb8388_olpc.bin
#libertas/sd8688.bin
#libertas/sd8688_helper.bin
#libertas/sd8686_v8_helper.bin
#libertas/cf8385.bin
#LICENCE.agere
#LICENCE.atheros_firmware
#LICENCE.broadcom_bcm43xx
#LICENCE.chelsio_firmware
#LICENCE.ene_firmware
#LICENCE.i2400m
LICENCE.iwlwifi_firmware
#LICENCE.Marvell
#LICENCE.mwl8335
#LICENCE.myri10ge_firmware
#LICENCE.OLPC
#LICENCE.phanfw
#LICENCE.qla2xxx
#LICENCE.ralink-firmware.txt
#LICENCE.rtlwifi_firmware.txt
#LICENCE.tda7706-firmware.txt
#LICENCE.ti-connectivity
#LICENCE.ueagle-atm4-firmware
#LICENCE.via_vt6656
#LICENCE.xc5000
#LICENSE.dib0700
LICENSE.radeon
Makefile
#matrox/g400_warp.fw
#matrox/g200_warp.fw
#mrvl/sd8787_uapsta.bin
#mts_cdma.fw
#mts_edge.fw
#mts_gsm.fw
#mts_mt9234mu.fw
#mts_mt9234zba.fw
#mwl8k/fmimage_8366.fw
#mwl8k/helper_8366.fw
#mwl8k/fmimage_8366_ap-2.fw
#mwl8k/fmimage_8366_ap-1.fw
#mwl8k/fmimage_8687.fw
#mwl8k/helper_8687.fw
#myri10ge_ethp_z8e.dat
#myri10ge_eth_z8e.dat
#myri10ge_rss_ethp_z8e.dat
#myri10ge_rss_eth_z8e.dat
#myricom/lanai.bin
#ositech/Xilinx7OD.bin
#phanfw.bin
#ql2100_fw.bin
#ql2200_fw.bin
#ql2300_fw.bin
#ql2322_fw.bin
#ql2400_fw.bin
#ql2500_fw.bin
#qlogic/12160.bin
#qlogic/isp1000.bin
#qlogic/sd7220.fw
#qlogic/1280.bin
#qlogic/1040.bin
#r128/r128_cce.bin
#radeon/R600_pfp.bin
#radeon/RV770_pfp.bin
#radeon/RS780_me.bin
#radeon/CEDAR_me.bin
#radeon/TURKS_me.bin
#radeon/R600_me.bin
#radeon/RS600_cp.bin
#radeon/SUMO_me.bin
#radeon/CAYMAN_pfp.bin
#radeon/CYPRESS_me.bin
#radeon/CAICOS_pfp.bin
#radeon/R520_cp.bin
#radeon/VERDE_ce.bin
#radeon/RV630_me.bin
#radeon/R700_rlc.bin
#radeon/RV610_pfp.bin
#radeon/JUNIPER_me.bin
#radeon/RV710_pfp.bin
#radeon/RS690_cp.bin
#radeon/CYPRESS_pfp.bin
#radeon/SUMO2_me.bin
#radeon/VERDE_mc.bin
#radeon/BARTS_mc.bin
#radeon/CAICOS_mc.bin
#radeon/ARUBA_pfp.bin
#radeon/RV635_pfp.bin
#radeon/R420_cp.bin
#radeon/R600_rlc.bin
#radeon/RV630_pfp.bin
#radeon/RV635_me.bin
#radeon/PITCAIRN_ce.bin
#radeon/RV730_pfp.bin
radeon/REDWOOD_me.bin
#radeon/PALM_me.bin
#radeon/BTC_rlc.bin
#radeon/BARTS_pfp.bin
#radeon/SUMO_rlc.bin
radeon/REDWOOD_rlc.bin
#radeon/JUNIPER_rlc.bin
#radeon/R100_cp.bin
#radeon/VERDE_pfp.bin
#radeon/RV610_me.bin
#radeon/TAHITI_mc.bin
#radeon/CAYMAN_mc.bin
#radeon/RS780_pfp.bin
#radeon/VERDE_rlc.bin
radeon/REDWOOD_pfp.bin
#radeon/TAHITI_pfp.bin
#radeon/RV670_me.bin
#radeon/RV770_me.bin
#radeon/RV730_me.bin
#radeon/PITCAIRN_mc.bin
#radeon/CEDAR_pfp.bin
#radeon/CAICOS_me.bin
#radeon/BARTS_me.bin
#radeon/CYPRESS_rlc.bin
#radeon/TAHITI_ce.bin
#radeon/CAYMAN_rlc.bin
#radeon/CAYMAN_me.bin
#radeon/ARUBA_rlc.bin
#radeon/PALM_pfp.bin
#radeon/ARUBA_me.bin
#radeon/RV710_me.bin
#radeon/RV620_pfp.bin
#radeon/VERDE_me.bin
#radeon/TAHITI_rlc.bin
#radeon/RV670_pfp.bin
#radeon/TURKS_mc.bin
#radeon/TURKS_pfp.bin
#radeon/TAHITI_me.bin
#radeon/PITCAIRN_me.bin
#radeon/RV620_me.bin
#radeon/PITCAIRN_pfp.bin
#radeon/JUNIPER_pfp.bin
#radeon/SUMO_pfp.bin
#radeon/R300_cp.bin
#radeon/PITCAIRN_rlc.bin
#radeon/R200_cp.bin
#radeon/CEDAR_rlc.bin
#radeon/SUMO2_pfp.bin
README
#rt2561.bin
#rt2561s.bin
#rt2661.bin
#rt2860.bin
#rt2870.bin
#rt3070.bin
#rt3071.bin
#rt3090.bin
#rt3290.bin
#rt73.bin
#RTL8192E/data.img
#RTL8192E/main.img
#RTL8192E/boot.img
#rtl_nic/rtl8105e-1.fw
#rtl_nic/rtl8168e-2.fw
#rtl_nic/rtl8168f-2.fw
#rtl_nic/rtl8168e-1.fw
#rtl_nic/rtl8411-1.fw
#rtl_nic/rtl8168d-2.fw
#rtl_nic/rtl8168g-1.fw
#rtl_nic/rtl8168f-1.fw
#rtl_nic/rtl8168e-3.fw
#rtl_nic/rtl8168d-1.fw
#rtl_nic/rtl8106e-1.fw
#rtl_nic/rtl8402-1.fw
#rtlwifi/rtl8192cufw.bin
#rtlwifi/rtl8192sefw.bin
#rtlwifi/rtl8192cfw.bin
#rtlwifi/rtl8192defw.bin
#rtlwifi/rtl8712u.bin
#rtlwifi/rtl8192cfwU_B.bin
#rtlwifi/rtl8192cfwU.bin
#s2250.fw
#s2250_loader.fw
#sb16/ima_adpcm_capture.csp
#sb16/alaw_main.csp
#sb16/ima_adpcm_init.csp
#sb16/ima_adpcm_playback.csp
#sb16/mulaw_main.csp
#slicoss/oasisdbgdownload.sys
#slicoss/gbrcvucode.sys
#slicoss/oasisdownload.sys
#slicoss/oasisrcvucode.sys
#slicoss/gbdownload.sys
#sun/cassini.bin
#sxg/saharadbgdownloadB.sys
#sxg/saharadownloadB.sys
#TDA7706_OM_v2.5.1_boot.txt
#TDA7706_OM_v3.0.2_boot.txt
#tehuti/bdx.bin
#ti_3410.fw
#ti_5052.fw
#ti-connectivity/wl128x-fw-ap.bin
#ti-connectivity/wl1271-fw-ap.bin
#ti-connectivity/wl128x-fw-4-mr.bin
#ti-connectivity/wl128x-fw-4-sr.bin
#ti-connectivity/wl127x-fw-5-sr.bin
#ti-connectivity/wl128x-nvs.bin
#ti-connectivity/wl127x-fw-3.bin
#ti-connectivity/wl1271-nvs.bin
#ti-connectivity/wl127x-fw-5-plt.bin
#ti-connectivity/wl1271-fw-2.bin
#ti-connectivity/wl1271-fw.bin
#ti-connectivity/wl128x-fw-5-sr.bin
#ti-connectivity/wl128x-fw.bin
#ti-connectivity/wl127x-fw-plt-3.bin
#ti-connectivity/wl127x-nvs.bin
#ti-connectivity/wl12xx-nvs.bin
#ti-connectivity/wl128x-fw-4-plt.bin
#ti-connectivity/wl128x-fw-5-plt.bin
#ti-connectivity/wl127x-fw-4-plt.bin
#ti-connectivity/wl127x-fw-5-mr.bin
#ti-connectivity/wl128x-fw-3.bin
#ti-connectivity/TIInit_7.2.31.bts
#ti-connectivity/wl128x-fw-5-mr.bin
#ti-connectivity/wl127x-fw-4-mr.bin
#ti-connectivity/wl128x-fw-plt-3.bin
#ti-connectivity/wl18xx-fw.bin
#ti-connectivity/wl127x-fw-4-sr.bin
#tigon/tg3_tso5.bin
#tigon/tg3.bin
#tigon/tg3_tso.bin
#tlg2300_firmware.bin
#tr_smctr.bin
#ttusb-budget/dspbootcode.bin
#ueagle-atm/eagleIII.fw
#ueagle-atm/CMVep.bin
#ueagle-atm/DSPei.bin
#ueagle-atm/CMVepFR04.bin
#ueagle-atm/eagleI.fw
#ueagle-atm/930-fpga.bin
#ueagle-atm/CMV4p.bin.v2
#ueagle-atm/CMV9p.bin
#ueagle-atm/CMVepES03.bin
#ueagle-atm/CMVepIT.bin
#ueagle-atm/eagleII.fw
#ueagle-atm/CMVepFR.bin
#ueagle-atm/eagleIV.fw
#ueagle-atm/CMVepWO.bin
#ueagle-atm/CMVepFR10.bin
#ueagle-atm/CMVepES.bin
#ueagle-atm/CMVeiWO.bin
#ueagle-atm/CMVei.bin
#ueagle-atm/adi930.fw
#ueagle-atm/CMV9i.bin
#ueagle-atm/DSPep.bin
#ueagle-atm/DSP4p.bin
#ueagle-atm/DSP9i.bin
#ueagle-atm/DSP9p.bin
#usbdux/fx2-include.asm
#usbdux/Makefile_dux
#usbdux/usbduxsigma_firmware.asm
#usbdux/README.dux
#usbdux/usbduxfast_firmware.asm
#usbdux/usbdux_firmware.asm
#usbduxfast_firmware.bin
#usbdux_firmware.bin
#usbduxsigma_firmware.bin
#v4l-cx231xx-avcore-01.fw
#v4l-cx23418-apu.fw
#v4l-cx23418-cpu.fw
#v4l-cx23418-dig.fw
#v4l-cx23885-avcore-01.fw
#v4l-cx23885-enc.fw
#v4l-cx25840.fw
#vicam/firmware.fw
#vntwusb.fw
#vxge/X3fw.ncf
#vxge/X3fw-pxe.ncf
WHENCE
#whiteheat.fw
#whiteheat_loader.fw
#yam/9600.bin
#yam/1200.bin
#yamaha/yss225_registers.bin
#yamaha/ds1_ctrl.fw
#yamaha/ds1_dsp.fw
#yamaha/ds1e_ctrl.fw

and the resulting files in /lib64/firmware/ after re-merging linux-firmware are now:

# ls /lib/firmware/
ACX100_USB.bin BCM2033-FW.bin BCM-LEGAL.txt GPL-3 iwlwifi-5000-2.ucode LICENCE.iwlwifi_firmware Makefile RADIO0d.BIN RADIO15.BIN STLC2500_R4_00_03.ptc STLC2500_R4_02_02_WLAN.ssf TIACX111.BIN WLANGEN.BIN
af9005.fw BCM2033-MD.hex configure iwlwifi-5000-1.ucode iwlwifi-5000-5.ucode LICENSE.radeon radeon RADIO11.BIN README STLC2500_R4_00_06.ssf STLC2500_R4_02_04.ptc WHENCE zd1211
# ls /lib/firmware/radeon
REDWOOD_me.bin REDWOOD_pfp.bin REDWOOD_rlc.bin

Compare that with the contents of /lib/firmware/ I listed earlier. Much tidier, isn’t it? I’ve saved quite a bit of wasted disk space.

I hope this post is helpful to others, as I searched unsucessfully for instructions on how to install the linux-firmware package so that only the necessary firmware files are installed. Don’t worry though: you could simply go ahead and install linux-firmware without editing the file in /etc/portage/savedconfig/sys-kernel/ if you don’t mind having unecessary files in /lib/firmware/ in addition to the firmware files you need.

About these ads

About Fitzcarraldo
A Linux user with an interest in all things technical.

2 Responses to How to install the linux-firmware package in Gentoo

  1. Alexandre says:

    Helpful :-) Thank you !

  2. Robi says:

    Just what I was looking for! Thanks.
    P.S. I was reading the “WiFi” article at Gentoo Wiki which mentions the use of sys-kernel/linux-firmware for some devices: I think it would be useful to merge this post (or at least mention the “savedconfig” USE flag) with this article → http://wiki.gentoo.org/wiki/Wifi

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

Join 49 other followers

%d bloggers like this: