Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 02-25-2008, 09:47 AM   #1
LQ Newbie
Registered: Feb 2008
Posts: 5

Rep: Reputation: 0
Files in /lib/firmware


I have a general question about the files that are stored in the folder "/lib/firmware" (I am using Ubuntu). I have bought a USB device for viewing television and I need to obtain a firmware file for my particular device. But what is this firmware? I only know firmware in the context of uploading firmware into the memory of a hardware device (e.g. updating the firmware in a router). But I have the suspicion that the files in "/lib/firmware" are not uploaded into the hardware. But what are the firmware files good for? I have also read that I need a kernel module along with a firmware file for my device. Is there any relationship between a firmware file and a kernel module for my device?

Old 02-25-2008, 09:56 AM   #2
LQ Guru
Registered: Aug 2003
Distribution: CentOS, OS X
Posts: 5,131

Rep: Reputation: Disabled
Not going to go in-depth here (I'm no professional on this), but let's take an example of a wireless network card, more precisely, Broadcom's BCM4318 (that uses bcm43xx in some kernels as the kernel module/driver; some kernels have newer b43 for that).

Not going to repeat this text for the b43 kernel module, I'll just speak about bcm43xx module below.

The Linux kernel contains a module, or a driver, for Broadcom 43xx cards - the module is called bcm43xx, and is typically loaded if the appropriate hardware is present. However that native Linux driver doesn't (at least with my card) know what to do with the bcm43xx cards, and Broadcom has not released a Linux driver for this chipset - so some folks wrote a driver. But what to do with it if it can't handle the card by itself? Answer: firmware. In other words, it needs some pieces from the driver written for Windows to work. Another solution is to use NDISwrapper which wraps the Windows drivers and then that information can be used to handle the hardware device.

Well, with bcm43xx loaded, a "link" is missing between the kernel module and the real hardware. That "link" is in the Windows drivers (because Broadcom didn't provide a nice complete Linux driver). There's a special program, "fwcutter", that reads in some information from the Windows driver files, "cuts" it off and produces some "firmware files" for your Linux system. Then you copy those firmware files and put them into /lib/firmware, where bcm43xx kernel module finds them. With the "firmware files" the kernel module then knows how to work with the hardware, and from the end-user's point of view it looks like the kernel module, the driver, just works with the card.

I don't have other devices that needed firmware files in /lib/firmware, but that's what they are generally for I guess - to work in cooperation with the kernel module to be able to work with the hardware.
Old 03-01-2008, 09:12 AM   #3
LQ Newbie
Registered: Feb 2008
Posts: 5

Original Poster
Rep: Reputation: 0
Thank you, b0uncer, for your reply.
Old 03-01-2008, 10:53 AM   #4
LQ Guru
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288Reputation: 1288
The firmware need not always be uploaded to a device ROM or similar memory storage. Sometimes it's simply stored on the HDD, why not, nothing wrong with that, data is data wherever it may reside. Typically this happens if there is nowhere to upload the data to, such as when there is no ROM on the device. And, yes the driver needs the firmware to know how to work with the device, and as the firmware is not available on the device ROM (because there is none), it should be stored in '/lib/firmware' where drivers will look for it.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
/lib/firmware... agayer Linux - Hardware 2 12-14-2006 04:35 AM
audacity unable to locate required lib files present in /usr/lib/ adityavpratap Slackware 4 11-30-2006 06:06 AM
where can i get lib files waelali Linux - Software 1 02-20-2005 04:20 PM
Compromised? Files "/usr/lib.hwm", "/usr/lib.pwd", "/usr/lib.pwi" Klaus Pforte Linux - Security 4 09-28-2004 11:33 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:08 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration