[PATCH] nl80211: Do not assume the device is rf-killed before trying to set it up

Tomasz Bursztyka tomasz.bursztyka at linux.intel.com
Mon Apr 28 04:34:13 EDT 2014


Hi Ilan,

>>>> +	if (nlmode == NL80211_IFTYPE_P2P_DEVICE) {
>>>> > >>+		nl80211_get_macaddr(bss);
>>>> > >>+		return ret;
>>> > >Returning here is problematic as the wpa_driver_nl80211_send_rfkill() will
>> >not be called, and the INTERFACE_DISABLED event will not be fired.
>>> > >
>> >
>> >That logic was present before my patch and before Moshe's one.
>> >
>> >So you mean we can continue here? Then there would be no need of ret
>> >variable at all.
>> >
> I mean that for this to work for P2P_DEVICE as well, the following logic needs to be called, otherwise, the wpa_s will not handle rfkill off properly.
>
> if (send_rfkill_event) {
> 		eloop_register_timeout(0, 0, wpa_driver_nl80211_send_rfkill,
> 				       drv, drv->ctx);
> }

Indeed, I will prepare another patch then.

Tomasz


More information about the HostAP mailing list