svn commit: r287892 - head/sys/dev/usb/wlan

Adrian Chadd adrian at freebsd.org
Thu Sep 17 07:43:24 UTC 2015


.. I'm likely going to do exactly that as part of "making" if_rsu do
11n and behave correctly. Right now it does neither.

But this is a pretty big design pattern flaw; all of the wifi drivers
use the usb library like this and .. well, unless you look under the
hood, you don't really realise that serialiser lock is being dropped
for you... :(


-a


On 17 September 2015 at 00:41, Hans Petter Selasky <hps at selasky.org> wrote:
> On 09/17/15 09:31, Hans Petter Selasky wrote:
>>
>> On 09/17/15 05:01, Adrian Chadd wrote:
>>>
>>> Author: adrian
>>> Date: Thu Sep 17 03:01:19 2015
>>> New Revision: 287892
>>> URL: https://svnweb.freebsd.org/changeset/base/287892
>>>
>>> Log:
>>>    Use DELAY() rather than usb_pause_mtx() - the latter releases the lock
>>>    before waiting, which prevents the lock from really acting like
>>>    a hardware serialiser.  Sigh.
>>>
>>> Modified:
>>>    head/sys/dev/usb/wlan/if_rsu.c
>>>
>>
>> This cause a lot more CPU to be burnt. Is there no other way to fix
>> this? Using an SX lock?
>>
>> --HPS
>>
>
> This will not help anything, because at every control request the same lock
> is dropped again. You need to add an SX lock there, and should revert this
> pause->DELAY change :-(
>
> --HPS
>


More information about the svn-src-all mailing list