Skip to contentSkip to conversation

How to request firmware during module init?

DISCUSSION Kalle Valo 3 participants 4 messages Sep 6, 2011

lore
Share & tools
lore

Kalle Valo

author
#0 lore raw

Hi,

ath6kl needs to request the firmware from user space during module init (or to be exact from sdio probe, but it's almost the same thing) and boot hardware to get some settings etc before it registers itself to cfg80211. What's the proper way to handle this?

I noticed that when I compile ath6kl into kernel boot fails on my x86 box as firmware is not available because user space is not ready.

Kalle

#1 lore raw
Quoted 9 lines · Kalle Valo

Hi,

ath6kl needs to request the firmware from user space during module init (or to be exact from sdio probe, but it's almost the same thing) and boot hardware to get some settings etc before it registers itself to cfg80211. What's the proper way to handle this?

I noticed that when I compile ath6kl into kernel boot fails on my x86 box as firmware is not available because user space is not ready.

We do an async request, once it comes back we register with mac80211.

johannes

author
#2 lore raw
Quoted 8 lines · Johannes Berg
Quoted 7 lines · Kalle Valo

Hi,

ath6kl needs to request the firmware from user space during module init (or to be exact from sdio probe, but it's almost the same thing) and boot hardware to get some settings etc before it registers itself to cfg80211. What's the proper way to handle this?

Quoted 4 lines
Quoted 2 lines

I noticed that when I compile ath6kl into kernel boot fails on my x86 box as firmware is not available because user space is not ready.

We do an async request, once it comes back we register with mac80211.

I take it you mean request_firmware_nowait(). I'll use that also.

Thanks!

Kalle

#3 lore raw
In reply to Kalle Valo

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 3 lines · Kalle Valo

I noticed that when I compile ath6kl into kernel boot fails on my x86 box as firmware is not available because user space is not ready.

Provided CONFIG_FIRMWARE_IN_KERNEL=y you could add this firmware to the kernel image with CONFIG_EXTRA_FIRMWARE. That's how I successfully operate monolithic kernels on X86 laptops.
As an example:
CONFIG_FIRMWARE_IN_KERNEL=y CONFIG_EXTRA_FIRMWARE="iwlwifi-6000g2a-5.ucode" CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware"

Regards,
- --
Tony Vroon
UNIX systems administrator
London Internet Exchange Ltd, Trinity Court, Trinity Street, Peterborough, PE1 1DA
Registered in England number 3137929
E-Mail: [email protected]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.18 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk5l3sIACgkQp5vW4rUFj5qIdgCbBD0fzZc+DB8qCxt7UVn4SXYK THoAoKzKOg/hIpDV4+54KXCWRQu/ziPa
=DREw
-----END PGP SIGNATURE-----