From: Simon Wunderlich <simon.wunderlich@s2003.tu-chemnitz.de>
To: Adrian Chadd <adrian.chadd@gmail.com>
Cc: Mohammed Shafi <shafi.wireless@gmail.com>,
Simon Wunderlich <simon.wunderlich@s2003.tu-chemnitz.de>,
linux-wireless@vger.kernel.org, ath9k-devel@lists.ath9k.org,
openwrt-devel@lists.openwrt.org,
Marek Lindner <lindner_marek@yahoo.de>,
sven@narfation.org, Gabor Juhos <juhosg@openwrt.org>
Subject: Re: AR9330 hornet board stops beaconing after a few days (0xdeadbeef)
Date: Thu, 23 Aug 2012 11:28:31 +0200 [thread overview]
Message-ID: <20120823092831.GA25818@pandem0nium> (raw)
In-Reply-To: <CAJ-VmokN_2PHZinfE8zfx6-8VZ+KenccymfSs+JFWtDtmjExVg@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 3655 bytes --]
Hello Adrian,
thanks for your comments!
On Wed, Aug 22, 2012 at 11:57:04AM -0700, Adrian Chadd wrote:
> Yeah. The deadbeef means "something's turned off."
>
> I'd start with the SoC reset register and see if the MAC/WMAC bits are
> correctly set. Ie, that something hasn't gone and reset the wireless
> bits behind your back.
Sure, but which register would that be? How can I find out? Is it included
in regdump of ath9k debugfs?
>
> You could try hacking up a work around that does a full MAC/WMAC reset
> when you reset the driver.
>
> Ie, when ath9k does a full reset, actually _do_ a full reset by
> resetting the mac/wmac via the SoC lines.
So far, I could resolve the situation by doing ifconfig wlan0 down ; ifconfig
wlan0 up. But I don't know if this problem will be triggered much faster
in "more hostile" environments (wherever this comes from).
>
> It could also be the RTC state. Maybe it's found its way into network
> sleep (ie, the force wake bits aren't set right.) Or something PLL
> related isn't programmed correctly. Dumping the RTC registers would be
> helpful.
I'm not sure which registers you mean exactly, but I have looked through
the regdump, compared to ath9k's reg.h and annotated it a bit (see below).
As I lack the Chip Specification, maybe some QCA/Atheros dev can help me
on that?
BTW, I've uploaded the full dumps in case anyone is interested [1]. node200
is the broken one, node201 is working at that moment (for comparison).
Thanks,
Simon
[1] http://packetmixer.de/ar9330_deadbeef/
#### Some PLL stuff:
#define AR_CH0_BB_DPLL1 0x16180
0x016180 0x08400000
#define AR_CH0_BB_DPLL2 0x16184
0x016184 0x18e90f00
#define AR_CH0_BB_DPLL3 0x16188
0x016188 0x00800000
#define AR_CH0_DDR_DPLL2 0x16244
0x016244 0x18e82f01
#define AR_CH0_DDR_DPLL3 0x16248
0x016248 0x008024d0
0x01624c 0xfc4d78b0
#### RTC Registers, annotated:
0x007000 0x00000002
0x007004 0x00000000
0x007008 0x00000000
0x00700c 0x00000001
0x007010 0x00000022
0x007014 0x0000142c
0x007018 0x00000500
0x00701c 0x00000001
0x007020 0x00000000
0x007024 0x00000000
0x007028 0x00000000
0x00702c 0x00000000
0x007030 0x00000002
#define AR_RTC_KEEP_AWAKE 0x7034
0x007034 0x00000002
0x007038 0x000002f8
0x00703c 0x00e04a3d
#define AR_RTC_RESET ((AR_SREV_9100(ah)) ? (AR_RTC_BASE + 0x0040) : 0x7040
#define AR_RTC_RESET_EN (0x00000001)
0x007040 0x00000001
#define AR_RTC_STATUS ((AR_SREV_9100(ah)) ? (AR_RTC_BASE + 0x0044) : 0x7044)
#define AR_RTC_STATUS_M ((AR_SREV_9100(ah)) ? 0x0000003f : 0x0000000f)
#define AR_RTC_PM_STATUS_M 0x0000000f
#define AR_RTC_STATUS_SHUTDOWN 0x00000001
#define AR_RTC_STATUS_ON 0x00000002
#define AR_RTC_STATUS_SLEEP 0x00000004
#define AR_RTC_STATUS_WAKEUP 0x00000008
0x007044 0x00000002
--> so RTC Status is "on"?
#define AR_RTC_SLEEP_CLK ((AR_SREV_9100(ah)) ? (AR_RTC_BASE + 0x0048) : 0x7048)
#define AR_RTC_FORCE_DERIVED_CLK 0x2
#define AR_RTC_FORCE_SWREG_PRD 0x00000004
0x007048 0x00000002
#define AR_RTC_FORCE_WAKE ((AR_SREV_9100(ah)) ? (AR_RTC_BASE + 0x004c) : 0x704c)
#define AR_RTC_FORCE_WAKE_EN 0x00000001
#define AR_RTC_FORCE_WAKE_ON_INT 0x00000002
0x00704c 0x00000003
--> both on, looks good?
#define AR_RTC_INTR_CAUSE ((AR_SREV_9100(ah)) ? (AR_RTC_BASE + 0x0050) : 0x7050)
0x007050 0x00000000
#define AR_RTC_INTR_ENABLE ((AR_SREV_9100(ah)) ? (AR_RTC_BASE + 0x0054) : 0x7054)
0x007054 0x00000000
#define AR_RTC_INTR_MASK ((AR_SREV_9100(ah)) ? (AR_RTC_BASE + 0x0058) : 0x7058)
0x007058 0x00000000
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
next prev parent reply other threads:[~2012-08-23 9:28 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-13 16:53 AR9330 hornet board stops beaconing after a few days (0xdeadbeef) Simon Wunderlich
2012-08-19 22:04 ` Simon Wunderlich
2012-08-22 5:20 ` Mohammed Shafi
2012-08-22 18:57 ` Adrian Chadd
2012-08-23 9:28 ` Simon Wunderlich [this message]
2012-08-23 17:10 ` Gabor Juhos
2012-08-23 19:26 ` Adrian Chadd
2012-08-23 14:59 ` Mohammed Shafi
2012-08-23 15:19 ` Sven Eckelmann
2012-08-23 15:27 ` Sven Eckelmann
2012-09-02 20:01 ` Simon Wunderlich
2012-09-03 13:53 ` Mohammed Shafi
2012-09-03 14:34 ` Sven Eckelmann
2012-09-04 17:12 ` Simon Wunderlich
2012-09-05 5:12 ` Mohammed Shafi
2012-09-05 14:08 ` Adrian Chadd
2012-09-05 14:20 ` Sven Eckelmann
2012-09-13 16:51 ` Simon Wunderlich
2012-09-13 16:59 ` Adrian Chadd
2012-09-13 17:55 ` [OpenWrt-Devel] " Felix Fietkau
2012-09-14 9:47 ` [RFC] ath9k: Work around complete stuck of hw Sven Eckelmann
2012-09-14 11:33 ` Felix Fietkau
2012-09-23 10:04 ` Sven Eckelmann
2013-11-20 20:57 ` [OpenWrt-Devel] AR9330 hornet board stops beaconing after a few days (0xdeadbeef) Bastian Bittorf
2013-11-20 21:00 ` Sven Eckelmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120823092831.GA25818@pandem0nium \
--to=simon.wunderlich@s2003.tu-chemnitz.de \
--cc=adrian.chadd@gmail.com \
--cc=ath9k-devel@lists.ath9k.org \
--cc=juhosg@openwrt.org \
--cc=lindner_marek@yahoo.de \
--cc=linux-wireless@vger.kernel.org \
--cc=openwrt-devel@lists.openwrt.org \
--cc=shafi.wireless@gmail.com \
--cc=sven@narfation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).