svn commit: r246614 - head/sys/dev/usb/wlan
Hans Petter Selasky
hselasky at c2i.net
Tue Feb 12 08:40:30 UTC 2013
On Tuesday 12 February 2013 09:08:44 Adrian Chadd wrote:
> Well, how are you preventing the detach from running _during_ an ioctl()?
>
> Have you eliminated the race, or just narrowed it?
>
Hi,
This is not handled, like you suggest. I'm not sure what the best approach is,
but probably we need to destroy the cdev calling the ioctl synchronously
first.
Do you agree that we need a 3-step proces?
1) Stop everything
2) Drain the stopping
3) Free
The problem is atomicity and LOR. Some functions which free resources might
have to wait for refcounts to go away, which means blocking operation. I can
stop multiple USB transfers atomically, but can I also stop the network stack
atomically? Else I need to have those checks around ieee80211_input() and I
see btw, that we have to drop the WLAN USB locks to call that function, so it
gets a bit more complicated. I.E. we need to stop and drain USB transfers
first.
There are many USB WLAN drivers, but only one WLAN API. Should these checks be
factored out of USB WLAN and into the WLAN API itself?
--HPS
More information about the svn-src-all
mailing list