[RFC] nl80211: set NLMODE correctly for AP interface

Jouni Malinen j
Mon Mar 2 14:07:48 PST 2015

On Wed, May 14, 2014 at 10:07:45AM +0530, Avinash Patil wrote:
> Please find attached logs for failure case without these changes.

> > On Tue, May 13, 2014 at 03:46:05PM +0530, Avinash Patil wrote:
> >> We add interface manually by "iw dev interface wlan0 add uap0 type
> >> __ap" and then we start AP operations using supplicant.
> >> Typical configuration file would be like this:
> >>
> >> network={
> >>          ssid="supplicant_ap"
> >>          key_mgmt=NONE
> >>          mode=2
> >>          frequency=2432
> >> }
> >>
> >> #wpa_supplicant -Dnl80211 -i uap0 -c ap.conf

This was still in my to-do list to review in more detail.. I think my
earlier comment still applies, i.e.,
wpa_driver_nl80211_finish_drv_init() has no way of knowing (nor should
it known) that the only operation used for this interface is AP mode.

If this is still an issue that you want to get addressed in
wpa_supplicant, it might be possible to address this by allowing
initialization to continue after the station mode configuration fails if
current iftype is NL80211_IFTYPE_AP and mark such an interface with a
new AP-mode-only driver flag. The core wpa_supplicant code would then
need to use that flag to allow only an AP mode operation to be started
on the interface. That said, I'm not really sure this complexity is
justifiable for such a corner case of driver behavior (and something
that really cannot be recommended in general as a reasonable limitation
for an nl80211 driver).

Jouni Malinen                                            PGP id EFC895FA

More information about the Hostap mailing list