firmware loading

Sepherosa Ziehau sepherosa at gmail.com
Sat May 12 00:04:00 PDT 2007


On 5/12/07, km b <kmb810 at gmail.com> wrote:
On 5/12/07, Sepherosa Ziehau <sepherosa at gmail.com> wrote:

> Add a new ioctl command into driver's ioctl handler, then add a user
> space program to parse the raw ucode, and send the parsed results to
> driver through the newly added ioctl command.  Driver can then load
> the results (e.g. text and data segments) into device.  Take a look at
> iwi(4) and iwicontrol(8) for example.
is it really necessary to do it this way? cause i don't like the idea
of using a user space program for directing the driver to load the
firmware. instead the firmware can be loaded and cached during the
device attach routine.
I generally avoid loading firmware at attaching time, except that you
can't get the MAC address without firmware being loaded.  You can't
change firmware without recompile the module or kernel if it is loaded
at attaching time.  And it may introduce some firmware license
problems too.  And I perfer _not_ to play with filesystem in driver
code, no matter at attaching time or runtime.
the firmware_image_load_file can be the appropriate candidate for such
functionality provided  that it just returns the raw data from the
/etc/xxx firmware file without allocating the dma resources.
We will always need to allocate DMA resources for the firmware loading.

Best Regards,
sephe
--
Live Free or Die




More information about the Kernel mailing list