Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 484240 - >=sys-kernel/gentoo-sources-3.11.0 - rt2800pci: tx fails after brief use on certain APs
Summary: >=sys-kernel/gentoo-sources-3.11.0 - rt2800pci: tx fails after brief use on c...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo Kernel Bug Wranglers and Kernel Maintainers
URL: https://bugzilla.kernel.org/show_bug....
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-09-08 14:27 UTC by Robin Bankhead
Modified: 2014-05-01 17:45 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robin Bankhead 2013-09-08 14:27:43 UTC
Ùpgraded from gentoo-sources-3.10.0 to 3.11.0 and found wireless transmission fails as soon as any sustained throughput is attempted. No de-association from the AP, just no traffic, and this output:

-------------
[ 2931.627539] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 0 failed to flush
[ 2931.737640] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 2 failed to flush
[ 2932.136000] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 0 failed to flush
[ 2932.246103] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 2 failed to flush
[ 2932.249994] cfg80211: Calling CRDA to update world regulatory domain
[ 2932.457302] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 0 failed to flush
[ 2932.567399] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 2 failed to flush
[ 2932.677502] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 0 failed to flush
[ 2932.787601] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 2 failed to flush
[ 2933.921635] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 0 failed to flush
[ 2934.031733] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 2 failed to flush
[ 2934.121054] cfg80211: World regulatory domain updated:
[ 2934.121070] cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
[ 2934.121078] cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[ 2934.121085] cfg80211:   (2457000 KHz - 2482000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[ 2934.121091] cfg80211:   (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
[ 2934.121097] cfg80211:   (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[ 2934.121104] cfg80211:   (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[ 2938.930211] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 0 failed to flush
[ 2939.040310] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 2 failed to flush
[ 2939.150411] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 0 failed to flush
[ 2939.260513] ieee80211 phy0: rt2x00queue_flush_queue: Warning - Queue 2 failed to flush
-------------------------

I turned on debugging for rt2x00 but I'm not getting any more than that still.

Hardware seems to vary: so far I've only had this problem with my home router (Netgear DG834PN with Atheros chipset, using ath_pci (old MadWifi) driver).

My card is
02:00.0 Network controller: Ralink corp. RT3290 Wireless 802.11n 1T/1R PCIe

Found these links which may be related:
https://patchwork.kernel.org/patch/2705091/
http://rt2x00.serialmonkey.com/pipermail/users_rt2x00.serialmonkey.com/2013-August/006353.html

emerge --info:
Portage 2.1.13.1 (default/linux/amd64/13.0/desktop/kde, gcc-4.6.3, glibc-2.17, 3.11.0-gentoo x86_64)
=================================================================
System uname: Linux-3.11.0-gentoo-x86_64-AMD_E2-1800_APU_with_Radeon-tm-_HD_Graphics-with-gentoo-2.2
KiB Mem:     3626992 total,   2487096 free
KiB Swap:    9047036 total,   9047036 free
Timestamp of tree: Sat, 07 Sep 2013 19:15:01 +0000
ld GNU ld (GNU Binutils) 2.23.1
distcc 3.1 x86_64-pc-linux-gnu [enabled]
ccache version 3.1.9 [enabled]
app-shells/bash:          4.2_p45
dev-java/java-config:     2.2.0
dev-lang/python:          2.7.5-r1, 3.2.5-r1, 3.3.2-r1
dev-util/ccache:          3.1.9
dev-util/cmake:           2.8.11.1
dev-util/pkgconfig:       0.28
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.11.8
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.10.3, 1.11.6, 1.12.6, 1.13.4, 1.14
sys-devel/binutils:       2.23.1
sys-devel/gcc:            4.6.3
sys-devel/gcc-config:     1.8
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r4
sys-kernel/linux-headers: 3.9 (virtual/os-headers)
sys-libs/glibc:           2.17
Repositories: gentoo
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -fomit-frame-pointer -march=amdfam10 -mcx16 -msahf -mpopcnt --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=512 -mtune=amdfam10"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/themes/oxygen-gtk/gtk-2.0"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.5/ext-active/ /etc/php/cgi-php5.5/ext-active/ /etc/php/cli-php5.5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe -fomit-frame-pointer -march=amdfam10 -mcx16 -msahf -mpopcnt --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=512 -mtune=amdfam10"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--nospinner --quiet-build=n"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs ccache distcc distlocks ebuild-locks fail-clean fixlafiles merge-sync news preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://www.mirrorservice.org/sites/www.ibiblio.org/gentoo/"
LANG="en_GB.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j20 -l2.6"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/tmp"
PORTDIR="/usr/local/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://hazel/gentoo-portage"
USE="X a52 aac acl acpi alsa amd64 bash-completion berkdb bluetooth branding bzip2 cairo cdda cddb cdr cli consolekit cracklib crypt css cups cxx dbus declarative dga djvu dri dts dvd dvdr emboss encode exif fam fbcon ffmpeg firefox flac fortran ftp gd gdbm geoip gif gimp gmp gnutls gphoto2 gpm graphviz gtk handbook hddtemp iconv imagemagick imap inotify java javascript jit jpeg kde kipi lame latex lcms ldap libkms libnotify lm_sensors lzma lzo mad maildir matroska mbox mmap mmx mmxext mng modules mp3 mp4 mpeg mplayer mtp mudflap multilib musicbrainz mysql ncurses nls nptl ocamlopt offensive ofx ogg opengl openmp pam pango pcre pda pdf perl phonon php plasma png policykit posix postscript ppds qt3support qt4 quicktime radius raw readline rss samba scanner sdl session sharedmem smp snmp sockets socks5 sound spell sqlite sqlite3 sse sse2 ssl ssse3 startup-notification subversion svg syslog tcpd theora threads tidy tiff tk tokenizer truetype udev udisks unicode upnp upnp-av upower usb v4l vcd vdpau vhosts vnc vorbis wifi wmf wxwidgets x264 xa xcb xcomposite xft xine xinerama xml xpm xscreensaver xv xvid xvmc zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" GRUB_PLATFORMS="efi-64 multiboot" INPUT_DEVICES="keyboard mouse evdev synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en_GB" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_2" RUBY_TARGETS="ruby19 ruby18" SANE_BACKENDS="hp net" USERLAND="GNU" VIDEO_CARDS="radeon" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 1 Tom Wijsman (TomWij) (RETIRED) gentoo-dev 2013-09-13 16:59:27 UTC
(In reply to Robin Bankhead from comment #0)
> https://patchwork.kernel.org/patch/2705091/

This one is present in v3.10 v3.10-rc1 v3.10-rc2 v3.10-rc3 v3.10-rc4 v3.10-rc5 v3.10-rc6 v3.10-rc7 v3.10.1 v3.10.10 v3.10.11 v3.10.2 v3.10.3 v3.10.4 v3.10.5 v3.10.6 v3.10.7 v3.10.8 v3.10.9 v3.11 v3.11-rc1 v3.11-rc2 v3.11-rc3 v3.11-rc4 v3.11-rc5 v3.11-rc6 v3.11-rc7 v3.8 v3.8-rc1 v3.8-rc2 v3.8-rc3 v3.8-rc4 v3.8-rc5 v3.8-rc6 v3.8-rc7 v3.8.1 v3.8.10 v3.8.11 v3.8.12 v3.8.13 v3.8.2 v3.8.3 v3.8.4 v3.8.5 v3.8.6 v3.8.7 v3.8.8 v3.8.9 v3.9 v3.9-rc1 v3.9-rc2 v3.9-rc3 v3.9-rc4 v3.9-rc5 v3.9-rc6 v3.9-rc7 v3.9-rc8 v3.9.1 v3.9.10 v3.9.11 v3.9.2 v3.9.3 v3.9.4 v3.9.5 v3.9.6 v3.9.7 v3.9.8 v3.9.9 so it is unlikely that this patch will still fix anything; or, is it the actual cause maybe?

> http://rt2x00.serialmonkey.com/pipermail/users_rt2x00.serialmonkey.com/2013-
> August/006353.html

Seems this one looks new and isn't in stable yet, let's follow that one up to see if it progresses towards the stable kernel; can you please try to apply this patch to see if it will fix things?

You can put it in /etc/portage/patches/sys-kernel/gentoo-sources/

If that does not fix it, we might want to file this upstream (under Drivers -> Network) at https://bugzilla.kernel.org
Comment 2 Robin Bankhead 2013-09-13 22:53:05 UTC
Thanks Tom, will try as soon as I can.

Meanwhile, two updates:

1. Has now happened on a different AP (BT Business Hub)

2. May also be causing panics: I've had a few, but not (thus far) while rt2800pci is blacklisted.
Comment 3 Robin Bankhead 2013-09-14 08:53:28 UTC
Patched; no change I'm afraid. 

Anecdotally, it took longer than before (about 30min) to fail, but I wasn't making as much traffic during that time,  so in bytes-transmitted-before-failure terms, might be about the same.
Comment 4 Robin Bankhead 2013-09-24 19:18:01 UTC
Still occurring on 3.11.1.

The panics I mentioned appear to be unrelated, as they've now happened with rt2800pci blacklisted.

I was about to test some of the 3.10.* iterations I'd skipped, to check if the issue appeared earlier, then realised I'd cleverly unmerged 3.10.0 including its .config, so I may have a problem there.  Is there any way of doing a "reverse make oldconfig" using my 3.11.0 config?

I've turned on all debugging I can, so more output (hopefully) to follow.
Comment 5 Robin Bankhead 2013-10-22 13:04:10 UTC
OK, a kernel bug[1] (regression caused by adding MSI support) has materialised in the meantime, and its patch[2] is working pretty good so far here.  Been up about an hour, sustained throughput, no dropouts, and only one missed-beacon message in the log. Looks good!

[1] https://bugzilla.kernel.org/show_bug.cgi?id=61621
[2] http://marc.info/?l=linux-wireless&m=137992749815360&w=2
Comment 6 Robin Bankhead 2013-10-23 12:17:43 UTC
Spoke too soon.  I went and visited the other aforementioned AP for a bit of torture-testing, and after an hour or so got kicked with similar output.

The patch definitely helps a lot, and it's possible the signal just isn't good enough there -- my ar5523 backup dongle doesn't work at all there, and the rt3290 had been known to drop-out occasionally there too -- but I definitely see a decline, and (although maybe I just wasn't patient enough) it seemed to need reloading the rt2800pci module before it could reconnect.

With the improvement, my focus returns to catching up on actually using the machine, but I'm still ready to help debug as directed, just let me know.
Comment 7 Mike Pagano gentoo-dev 2013-11-08 00:16:55 UTC
I believe this might be addressed with:

http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/drivers/net/wireless/rt2x00/rt2x00pci.c?id=dfb6b7c109a7f98d324a759599d1b4616f02c79f

Which is in vanilla 3.12.0 and gentoo-sources-3.12.0.

Can you test with that, please.
Comment 8 Robin Bankhead 2013-11-08 08:45:01 UTC
Yup, that's the patch I mentioned in comment #5. Thanks for the heads-up, will upgrade as soon as time allows.

As per comment #6 there is still a minor issue of similar character, but certainly the situation has much improved.
Comment 9 Robin Bankhead 2013-11-12 02:02:20 UTC
OK, so 3.12.0 gets us better than unpatched 3.11.*, but still poorer than 3.10.* and, on early impressions, worse still than patched 3.11.*.

Commentary on the kernel bug seems to agree with this assessment. Not sure where to look now, maybe something higher-level?
Comment 10 Mike Pagano gentoo-dev 2014-01-30 17:37:56 UTC
Any changes with the latest kernel at this time?
Comment 11 Robin Bankhead 2014-02-01 10:52:57 UTC
(In reply to Mike Pagano from comment #10)
> Any changes with the latest kernel at this time?

A bit hard to answer at home, because upgrading to gentoo-sources-3.13.0-r1 coincided with replacing my router with an 802.11n model, so there was an improvement but I attributed it to that.  That said, the "Queue X failed to flush" message floods have dried up.

Reviewing the logs, I do still see those messages on occasion, but I can identify those as times I was on the public AP mentioned above, and only when I was positioned farther away from the AP (where dropouts did occasionally occur even on 3.10.* and below), and they were much fewer in number (two bursts of half-a-dozen messages each, ~20 minutes apart).

Anecdotally, I didn't get a dropout at that location, although I was experiencing some veeeery long web page load times/timeouts (a few minutes). Could be issues with the AP's WAN connection, of course.

With some caution, I'd say we are back in pre-3.11 levels of performance/reliability.

Were there any particularly significant changes to the driver in 3.13? Nothing mentioned on the upstream bug.
Comment 12 Mike Pagano gentoo-dev 2014-05-01 17:45:08 UTC
Not that I'm aware of, but thanks for responding. Please feel free to comment you are still having issues.