On Sat, Jul 07, 2012 at 04:35:46PM +0200, Stefan Sperling wrote: > rt2560 is selecting antennas before initialising the baseband > processor (BBP), however initialising antennas involves tweaking > of BBP registers. > > The diff below (taken from dragonfly, written by sephe) ensures > antennas are selected after the BBP has been initialised. > > Part of this diff was committed in r1.26 of rt2560.c and subsequently > backed out because it caused problems. Apparently the missing piece was > a busy-wait loop before reading in rt2560_bbp_read(), which has since > been added to dragonfly: > > commit dd8ea05f8d30bd38ecd334718e4263d8c56ce67a > Author: Sepherosa Ziehau <se...@dragonflybsd.org> > Date: Thu Apr 12 12:54:07 2007 +0000 > > When read BBP registers, avoid writing to BBPCSR until it is no longer > busy. > After this bug fixing, TX/RX antenna setup can be safely put after BBP > initialization, which is a correct place for it, since BBP initialization > will overwrite RX antenna BBP register with default value. Before this bug > fixing, putting TX/RX antenna setup after BBP initailization always results > in strange TX/RX problems, which I experienced when I fiddled with my ASUS > WL-107G; and some OpenBSD folks had this problems too, before Damien > reverted > related changes in OpenBSD. > > Tested with an RT2560 cardbus ral which still seems happy. > > Any testers/oks?
I had posted a diff for this and a few other bug fixes here.. http://marc.info/?l=openbsd-tech&m=124139607313719&w=2 -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.