Bug 155100 - [ath] ath driver on busy channel: "stuck beacon"
Summary: [ath] ath driver on busy channel: "stuck beacon"
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: wireless (show other bugs)
Version: Unspecified
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-wireless (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-27 20:50 UTC by Nerius Landys
Modified: 2018-05-28 19:41 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nerius Landys 2011-02-27 20:50:04 UTC
ath0: <Atheros 5212> (in hostap mode)
Exact card: EnGenius EPI-3601S PCI

This problem started happening since upgrading to 7.3 from 7.1 (and still happens when I upgrade to 7.4).  I did not try 7.2, but I am aware that the ath driver underwent a lot of changes in 7.2.

I live in a populated neighborhood where many of the houses next door have wireless routers.

I started getting thousands of these kernel messages since my upgrade to 7.3:

  ath0: stuck beacon; resetting (bmiss count 4)

I narrowed down the problem to a single change that makes the problem go away.

I changed this line in /etc/rc.conf:

  ifconfig_ath0="ssid speedy.i mode 11g mediaopt hostap channel 11 up"

to something like this:

  ifconfig_ath0="ssid speedy.i mode 11g mediaopt hostap channel 2 up"

Yes, that's right, I simply changed the channel.  I found no other way of fixing the problem after trying many things and reading a lot of information on the internet and in man pages.  A "-bgscan" does not fix the problem, and there don't seem to be any sysctl's that address the issue.

It seems that a busy channel will cause these types of beacon errors (see above) to occur.  The come in thousands.  Another symptom is that the entire system will become very sporadic and even wired network interfaces may cease to function or will work very slowly and sporadically.

I posted on the FreeBSD forums regarding this issue:
  http://forums.freebsd.org/showthread.php?t=22112

Since I'm able to consistently reproduce this problem on my end (simply by trying to a channel that currently causes the problem), I'm willing to apply patches to the kernel and test fixes that you may be working on.  I'm willing to assist in any other ways so that this driver bug can be fixed.  I even have 2 of these cards, in case you need one free of charge.

Fix: 

Change the channel of the wireless card in hostap mode until one is found that is not too busy.  This is an unacceptable solution.
How-To-Repeat: I will give you my current files that are relevant.  Note however that when I did my testing and isolated the channel as a problem, I had hostapd turned _off_ (I had a completely unsecured wireless access point).


/etc/rc.conf:

  # -- sysinstall generated deltas -- # Fri Dec 26 04:05:59 2008
  # Created: Fri Dec 26 04:05:59 2008
  # Enable network daemons for user convenience.
  # Please make all changes to this file, not to /etc/defaults/rc.conf.
  # This file now contains just the overrides from /etc/defaults/rc.conf.
  gateway_enable="YES"
  hostname="speedy.i"
  ifconfig_fxp2="DHCP"
  cloned_interfaces="bridge0"
  ifconfig_bridge0="addm fxp0 addm fxp1 addm re0 addm ath0 up"
  ifconfig_fxp0="up"
  ifconfig_fxp1="up"
  ifconfig_re0="up"
  ifconfig_ath0="ssid speedy.i mode 11g mediaopt hostap channel 2 -bgscan up"
  ipv4_addrs_bridge0="192.168.0.254/24"
  ipnat_enable="YES"
  hostapd_enable="YES"
  sshd_enable="YES"
  named_enable="YES"
  ntpdate_enable="YES"
  ntpd_enable="YES"
  linux_enable="YES"
  dhcpd_enable="YES"
  dhcpd_ifaces="bridge0"
  apache22_enable="YES"


/boot/loader.conf:

  autoboot_delay="6"
  loader_logo="beastie"
  password="xoxoxoxo"
  snd_ich_load="YES"
  wlan_xauth_load="YES"


/etc/hostapd.conf:

  interface=ath0
  debug=1
  ctrl_interface=/var/run/hostapd
  ctrl_interface_group=wheel
  ssid=speedy.i
  hw_mode=g
  wpa=3
  wpa_passphrase=7t7t7t7t7t
  wpa_key_mgmt=WPA-PSK
  wpa_pairwise=TKIP CCMP


sysctl -a | grep 'hw\.ath':

  hw.ath.txbuf: 200
  hw.ath.rxbuf: 40
  hw.ath.regdomain: 0
  hw.ath.countrycode: 0
  hw.ath.xchanmode: 1
  hw.ath.outdoor: 1
  hw.ath.calibrate: 30
  hw.ath.hal.swba_backoff: 0
  hw.ath.hal.sw_brt: 10
  hw.ath.hal.dma_brt: 2


dmesg:

  ath0: <Atheros 5212> mem 0xff8f0000-0xff8fffff irq 21 at device 0.0 on pci1
  ath0: [ITHREAD]
  ath0: WARNING: using obsoleted if_watchdog interface
  ath0: Ethernet address: 00:02:6f:61:e6:7d
  ath0: mac 7.9 phy 4.5 radio 5.6


exerpt from /usr/src/UPDATING:

  20090312:
          The open-source Atheros HAL has been merged from HEAD
          to STABLE.
          The kernel compile-time option AH_SUPPORT_AR5416 has been
          added to support certain newer Atheros parts, particularly
          PCI-Express chipsets.
          The following modules are no longer available, and should be
          removed from MODULES_OVERRIDE and/or loader.conf:-
           ath_hal ath_rate_amrr ath_rate_onoe ath_rate_sample
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2011-02-27 21:26:42 UTC
Responsible Changed
From-To: freebsd-bugs->adrian

Over to maintainer.
Comment 2 Adrian Chadd freebsd_committer 2011-04-09 04:01:13 UTC
Responsible Changed
From-To: adrian->freebsd-wireless

bump to mailing list
Comment 3 Eitan Adler freebsd_committer freebsd_triage 2018-05-28 19:41:02 UTC
batch change:

For bugs that match the following
-  Status Is In progress 
AND
- Untouched since 2018-01-01.
AND
- Affects Base System OR Documentation

DO:

Reset to open status.


Note:
I did a quick pass but if you are getting this email it might be worthwhile to double check to see if this bug ought to be closed.