athn bugs: usbd_free_xfer and fail HT-MCS

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

athn bugs: usbd_free_xfer and fail HT-MCS

fogktstv
Hi! Wanted to report some bugs with athn firmware. I know there has been
some updates
recently (thanks mostly to stsp@ and kevlo@), so I'm not sure what I'm
reporting is already known or not. I'm using OpenBSD 6.5, not -current
(let
me know if full dmesg is needed - the hardware is a AMD Ryzen 5). The
adapter
is a TP-Link TL-WN722N (firmware instaled using fw_update):

athn0 at uhub1 port 4 configuration 1 interface 0 "ATHEROS USB2.0 WLAN"
rev 2.00/1.08 addr 4
athn0: AR9271 rev 1 (1T1R), ROM rev 13

While using client mode (not HostAP), this bug happens some times:

usbd_free_xfer: xfer=0xfffffd81e0bd53d0 not free
usbd_free_xfer: xfer=0xfffffd81831163c0 not free
usbd_free_xfer: xfer=0xfffffd81e0c2de18 not free

I'm unable to reconnect the device, it's just not recognized anymore
until next boot.
I'm sure this is not a hardware issue, as it works on other systems.
There was a hypothesis that USB is not sending enough power on 2.0 ports
[1].
So I connected to a standalone 3.0 port, and the same still happens.
kevlo@ reported his device (same as the one I'm using) is working just
fine
in older releases [2].

The second bug is with 11n HT-MCS. It doesn't work at all. The only mode
that
works is 11g OFDM58. But the speed is not great. I know I'm not doing a
proper benchmark
with iperf3, but the difference is very significant between ath9k-open
on debian and openbsd.
The maximum speed I could get on OpenBSD was 1.5MB/s, while on Debian it
gets up to ~6.0MB/s.
I don't expect the same speed and I'm not complaining, just wanted to
point out that this
might be because HT-MCS is not working (at least for me).

Will the new release solve some of these issues? Thanks for all the work
this year!
Looking foward for the next release (bin patches seems great).


[1] https://marc.info/?l=openbsd-bugs&m=153268350614634&w=2
[2] https://marc.info/?l=openbsd-tech&m=151090602510672&w=2

Reply | Threaded
Open this post in threaded view
|

Re: athn bugs: usbd_free_xfer and fail HT-MCS

Stefan Sperling-5
Thanks. These bugs are up for anyone to tackle. I'm already overloaded.

On Fri, Sep 06, 2019 at 06:46:52AM -0300, [hidden email] wrote:

> Hi! Wanted to report some bugs with athn firmware. I know there has been
> some updates
> recently (thanks mostly to stsp@ and kevlo@), so I'm not sure what I'm
> reporting is already known or not. I'm using OpenBSD 6.5, not -current (let
> me know if full dmesg is needed - the hardware is a AMD Ryzen 5). The
> adapter
> is a TP-Link TL-WN722N (firmware instaled using fw_update):
>
> athn0 at uhub1 port 4 configuration 1 interface 0 "ATHEROS USB2.0 WLAN" rev
> 2.00/1.08 addr 4
> athn0: AR9271 rev 1 (1T1R), ROM rev 13
>
> While using client mode (not HostAP), this bug happens some times:
>
> usbd_free_xfer: xfer=0xfffffd81e0bd53d0 not free
> usbd_free_xfer: xfer=0xfffffd81831163c0 not free
> usbd_free_xfer: xfer=0xfffffd81e0c2de18 not free
>
> I'm unable to reconnect the device, it's just not recognized anymore until
> next boot.
> I'm sure this is not a hardware issue, as it works on other systems.
> There was a hypothesis that USB is not sending enough power on 2.0 ports
> [1].
> So I connected to a standalone 3.0 port, and the same still happens.
> kevlo@ reported his device (same as the one I'm using) is working just fine
> in older releases [2].
>
> The second bug is with 11n HT-MCS. It doesn't work at all. The only mode
> that
> works is 11g OFDM58. But the speed is not great. I know I'm not doing a
> proper benchmark
> with iperf3, but the difference is very significant between ath9k-open on
> debian and openbsd.
> The maximum speed I could get on OpenBSD was 1.5MB/s, while on Debian it
> gets up to ~6.0MB/s.
> I don't expect the same speed and I'm not complaining, just wanted to point
> out that this
> might be because HT-MCS is not working (at least for me).
>
> Will the new release solve some of these issues? Thanks for all the work
> this year!
> Looking foward for the next release (bin patches seems great).
>
>
> [1] https://marc.info/?l=openbsd-bugs&m=153268350614634&w=2
> [2] https://marc.info/?l=openbsd-tech&m=151090602510672&w=2
>

Reply | Threaded
Open this post in threaded view
|

Re: athn bugs: usbd_free_xfer and fail HT-MCS

soiahfafh
In reply to this post by fogktstv
New issue prompted today:

athn0: device time out
athn0: firmware command 0x11 timed out
athn0: could not remove station 1 (-address-) from table
athn0: firmware command 0x14 timed out
athn0: firmware command 0x15 timed out

I was unable to reconnect. Solved after physically removing the
usb adapter and restarting the network (sh /etc/network), unlike
the previous issue, which was only solved after rebooting the system.
Sometimes the interface mode keeps changing between OFDM48 and OFDM58,
even though I've forced the mode in hostname.athn0.

Please let me know how I can bring more useful informations (debug)
to solve these issues i athn, hopefully before the new release.

Reply | Threaded
Open this post in threaded view
|

Re: athn bugs: usbd_free_xfer and fail HT-MCS

Stefan Sperling-5
On Mon, Sep 09, 2019 at 03:08:42PM -0300, [hidden email] wrote:

> New issue prompted today:
>
> athn0: device time out
> athn0: firmware command 0x11 timed out
> athn0: could not remove station 1 (-address-) from table
> athn0: firmware command 0x14 timed out
> athn0: firmware command 0x15 timed out
>
> I was unable to reconnect. Solved after physically removing the
> usb adapter and restarting the network (sh /etc/network), unlike
> the previous issue, which was only solved after rebooting the system.
> Sometimes the interface mode keeps changing between OFDM48 and OFDM58,
> even though I've forced the mode in hostname.athn0.
>
> Please let me know how I can bring more useful informations (debug)
> to solve these issues i athn, hopefully before the new release.
>

In cases where you have to reboot the system, I believe you are seeing
effects from bugs in our USB stack, related to management of available
power on the bus.

I don't have time or interest to dig into this, sorry. But this is an area
where we realy need some help. Several USB wifi drivers have had bugs filed
against them that look similar to this, and which tend to disappear when
using such devices on a different machine with a different USB chipset.

Reply | Threaded
Open this post in threaded view
|

Re: athn bugs: usbd_free_xfer and fail HT-MCS

Theo de Raadt-2
Stefan Sperling <[hidden email]> wrote:

> In cases where you have to reboot the system, I believe you are seeing
> effects from bugs in our USB stack, related to management of available
> power on the bus.
>
> I don't have time or interest to dig into this, sorry. But this is an area
> where we realy need some help. Several USB wifi drivers have had bugs filed
> against them that look similar to this, and which tend to disappear when
> using such devices on a different machine with a different USB chipset.

Very true.  Outside wireless also.