On Mon, May 9, 2011 at 9:15 PM, Tony Houghton <h...@realh.co.uk> wrote: > [Recap: my Compaq/HP 311c Mini netbook with AR9285 locks up when the > wifi connection is shut down for any reason, since kernel 2.6.35] > > On Mon, 21 Mar 2011 20:20:23 +0530 > Mohammed Shafi <shafi.wirel...@gmail.com> wrote: > >> I got a compaq machine, i will try to reproduce the issue now, most >> probable i will hit it. > > I guess you haven't been able to reproduce it? > > Yesterday I fetched wireless-testing from git and added some printk > calls. I tested it by logging all kernel messages to the console and > running rmmod ath9k. The freeze is in ath9k_hw_set_power_awake during > the for() loop when it calls > REG_SET_BIT(ah, AR_RTC_FORCE_WAKE, > AR_RTC_FORCE_WAKE_EN);
instead of adding printk's please increase the udelay(50) to some higher value > > On my most recent test, val (from > val = REG_READ(ah, AR_RTC_STATUS) & AR_RTC_STATUS_M; > ) was 15 and i (the loop iterator) was 199 ie it happened on the second > iteration. Unfortunately I neglected to note what happened at this > point: value 15 does not seems to be correct. it looks all the bits of RTC_STATUS are set bit 0 - shutdown bit 1- ON bit 2 - sleep BIT 3 -wake up bit 4 -cold reset. for me I am getting RTC status as 0X2(ON). > > /* Set Bits 14 and 17 of AR_WA before powering on the chip. */ > if (AR_SREV_9300_20_OR_LATER(ah)) { > REG_WRITE(ah, AR_WA, ah->WARegVal); > udelay(10); > } > > Could that be critical? > > On one try, after adding printk statements inside the loop, I could not > reproduce the crash for several attempts in a row, so I surmised that > the chip can't cope with the FORCE_WAKE bit being set so rapidly and the > printks had slowed it down sufficiently, but on a subsequent run it did > crash again with those printks in the loop. > > I wonder if it's incorrect to try to set the power mode to AWAKE during > shutdown? It doesn't seem right to me. It does this after setting the > mode to ATH9K_PM_FULL_SLEEP. > > I hope you will be able to work out what the problem is and fix it soon. > Please do not hesitate to ask me if you need more information from > debugging. > _______________________________________________ ath9k-devel mailing list ath9k-devel@lists.ath9k.org https://lists.ath9k.org/mailman/listinfo/ath9k-devel