[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of regressions introduced between 2.6.28 and 2.6.29. The following bug entry is on the current list of known regressions introduced between 2.6.28 and 2.6.29. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (147 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 http://lkml.org/lkml/2009/4/6/527 Handled-By : Bob Copeland m...@bobcopeland.com Patch : http://patchwork.kernel.org/patch/28210/ -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of regressions introduced between 2.6.28 and 2.6.29. The following bug entry is on the current list of known regressions introduced between 2.6.28 and 2.6.29. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (139 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 http://lkml.org/lkml/2009/4/6/527 Handled-By : Bob Copeland m...@bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of regressions introduced between 2.6.28 and 2.6.29. The following bug entry is on the current list of known regressions introduced between 2.6.28 and 2.6.29. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (133 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 http://lkml.org/lkml/2009/4/6/527 Handled-By : Bob Copeland m...@bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of regressions introduced between 2.6.28 and 2.6.29. The following bug entry is on the current list of known regressions introduced between 2.6.28 and 2.6.29. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (125 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 http://lkml.org/lkml/2009/4/6/527 Handled-By : Bob Copeland m...@bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of regressions introduced between 2.6.28 and 2.6.29. The following bug entry is on the current list of known regressions introduced between 2.6.28 and 2.6.29. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (105 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 http://lkml.org/lkml/2009/4/6/527 Handled-By : Bob Copeland m...@bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [Bug #12490] ath5k related kernel panic in 2.6.29-rc1
Anyway here's a patch to buy some time. Johannes, would this be an acceptable band-aid for now? This is going to make it print two warnings for one occurrence of the problem though. I'd much prefer to put something into minstrel.c to catch when _it_ returns bogus values and in that case return 0, that way at least the bandaid is restricted to the code it patches up. johannes signature.asc Description: This is a digitally signed message part
Re: [Bug #12490] ath5k related kernel panic in 2.6.29-rc1
On Tue, Apr 07, 2009 at 12:03:45PM +0200, Johannes Berg wrote: Anyway here's a patch to buy some time. Johannes, would this be an acceptable band-aid for now? This is going to make it print two warnings for one occurrence of the problem though. I'd much prefer to put something into minstrel.c to catch when _it_ returns bogus values and in that case return 0, that way at least the bandaid is restricted to the code it patches up. Ok, then maybe something like this? I think this covers most of the bases: if the driver is returning crap or the -cb gets corrupted, it'll get caught in tx_status. If minstrel stuffs a -1 in the first slot for any other reason we'll get a warning before get_tx_rate and a hopefully valid index gets substituted. diff --git a/net/mac80211/rc80211_minstrel.c b/net/mac80211/rc80211_minstrel.c index 3824990..1cf7152 100644 --- a/net/mac80211/rc80211_minstrel.c +++ b/net/mac80211/rc80211_minstrel.c @@ -181,6 +181,11 @@ minstrel_tx_status(void *priv, struct ieee80211_supported_band *sband, if (ar[i].idx 0) break; + if (WARN(ar[i].idx = mi-n_rates, + minstrel: invalid rate report %d (n=%d)\n, + ar[i].idx, mi-n_rates)) + break; + ndx = rix_to_ndx(mi, ar[i].idx); mi-r[ndx].attempts += ar[i].count; @@ -328,7 +333,7 @@ minstrel_get_rate(void *priv, struct ieee80211_sta *sta, ar[0].count = mp-max_retry; ar[1].idx = mi-lowest_rix; ar[1].count = mp-max_retry; - return; + goto done; } /* MRR setup */ @@ -346,6 +351,10 @@ minstrel_get_rate(void *priv, struct ieee80211_sta *sta, ar[i].idx = mi-r[mrr_ndx[i - 1]].rix; ar[i].count = mi-r[mrr_ndx[i - 1]].adjusted_retry_count; } + +done: + if (WARN_ON(ar[0].idx 0)) + ar[0].idx = rate_lowest_index(sband, sta); } -- Bob Copeland %% www.bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [Bug #12490] ath5k related kernel panic in 2.6.29-rc1
On Tue, 2009-04-07 at 20:46 -0400, Bob Copeland wrote: On Tue, Apr 07, 2009 at 12:03:45PM +0200, Johannes Berg wrote: Anyway here's a patch to buy some time. Johannes, would this be an acceptable band-aid for now? This is going to make it print two warnings for one occurrence of the problem though. I'd much prefer to put something into minstrel.c to catch when _it_ returns bogus values and in that case return 0, that way at least the bandaid is restricted to the code it patches up. Ok, then maybe something like this? I think this covers most of the bases: if the driver is returning crap or the -cb gets corrupted, it'll get caught in tx_status. If minstrel stuffs a -1 in the first slot for any other reason we'll get a warning before get_tx_rate and a hopefully valid index gets substituted. Yeah, that looks nicer, thanks. diff --git a/net/mac80211/rc80211_minstrel.c b/net/mac80211/rc80211_minstrel.c index 3824990..1cf7152 100644 --- a/net/mac80211/rc80211_minstrel.c +++ b/net/mac80211/rc80211_minstrel.c @@ -181,6 +181,11 @@ minstrel_tx_status(void *priv, struct ieee80211_supported_band *sband, if (ar[i].idx 0) break; + if (WARN(ar[i].idx = mi-n_rates, + minstrel: invalid rate report %d (n=%d)\n, + ar[i].idx, mi-n_rates)) + break; It might be easier to print this in hex -- that way things like 0x6b are more apparent? johannes signature.asc Description: This is a digitally signed message part
Re: [Bug #12490] ath5k related kernel panic in 2.6.29-rc1
On Mon, Apr 06, 2009 at 08:55:05PM +0200, Rafael J. Wysocki wrote: Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date : 2009-01-12 7:38 (85 days old) References: http://marc.info/?l=linux-kernelm=123174591509586w=4 Handled-By: Bob Copeland m...@bobcopeland.com I must admit I still don't have an idea of the root cause on this one. It still looks like some kind of memory corruption to me, but no smoking gun so far. The one patch in 2.6.30 that might have fixed it in the driver didn't help. Anyway here's a patch to buy some time. Johannes, would this be an acceptable band-aid for now? Sergey, can you test this patch? It doesn't fix anything but hopefully makes your system survive the bug. I gave it a quick test by forcing one of the rate indexes to a bad value. From: Bob Copeland m...@bobcopeland.com Date: Mon, 6 Apr 2009 22:04:09 -0400 Subject: [PATCH] mac80211: be more resilient in the face of bad rate indexes If for whatever reason the rate tables contain invalid rates, ieee80211_get_tx_rate will warn and return NULL, causing some drivers to crash. Those that don't will subsequently hit a BUG_ON() in rate.c. Instead, return a valid rate structure from ieee80211_get_tx_rate() and only WARN() in rate_control_get_rate(). Signed-off-by: Bob Copeland m...@bobcopeland.com --- include/net/mac80211.h | 12 +--- net/mac80211/rate.c|2 +- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/include/net/mac80211.h b/include/net/mac80211.h index 3b83a80..4a74f40 100644 --- a/include/net/mac80211.h +++ b/include/net/mac80211.h @@ -1014,13 +1014,19 @@ static inline void SET_IEEE80211_PERM_ADDR(struct ieee80211_hw *hw, u8 *addr) memcpy(hw-wiphy-perm_addr, addr, ETH_ALEN); } +static inline s8 +rate_lowest_index(struct ieee80211_supported_band *sband, + struct ieee80211_sta *sta); + static inline struct ieee80211_rate * ieee80211_get_tx_rate(const struct ieee80211_hw *hw, const struct ieee80211_tx_info *c) { - if (WARN_ON(c-control.rates[0].idx 0)) - return NULL; - return hw-wiphy-bands[c-band]-bitrates[c-control.rates[0].idx]; + s8 idx = c-control.rates[0].idx; + if (WARN_ON(idx 0)) + idx = rate_lowest_index(hw-wiphy-bands[c-band], + c-control.sta); + return hw-wiphy-bands[c-band]-bitrates[idx]; } static inline struct ieee80211_rate * diff --git a/net/mac80211/rate.c b/net/mac80211/rate.c index 4641f00..d8a5d46 100644 --- a/net/mac80211/rate.c +++ b/net/mac80211/rate.c @@ -238,7 +238,7 @@ void rate_control_get_rate(struct ieee80211_sub_if_data *sdata, sdata-max_ratectrl_rateidx); } - BUG_ON(info-control.rates[0].idx 0); + WARN_ON(info-control.rates[0].idx 0); } struct rate_control_ref *rate_control_get(struct rate_control_ref *ref) -- 1.6.0.6 -- Bob Copeland %% www.bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of recent regressions. The following bug entry is on the current list of known regressions from 2.6.28. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (69 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 Handled-By : Bob Copeland m...@bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of recent regressions. The following bug entry is on the current list of known regressions from 2.6.28. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (62 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 Handled-By : Bob Copeland m...@bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [Bug #12490] ath5k related kernel panic in 2.6.29-rc1
On Tuesday 24 February 2009, Bob Copeland wrote: On Mon, Feb 23, 2009 at 10:48:05PM +0100, Rafael J. Wysocki wrote: Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (43 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 Handled-By : Bob Copeland m...@bobcopeland.com Still unsolved, looks like some kind of memory corruption. Thanks for the update. Rafael -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [Bug #12490] ath5k related kernel panic in 2.6.29-rc1
On Mon, Feb 23, 2009 at 10:48:05PM +0100, Rafael J. Wysocki wrote: Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date : 2009-01-12 7:38 (43 days old) References: http://marc.info/?l=linux-kernelm=123174591509586w=4 Handled-By: Bob Copeland m...@bobcopeland.com Still unsolved, looks like some kind of memory corruption. -- Bob Copeland %% www.bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of recent regressions. The following bug entry is on the current list of known regressions from 2.6.28. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (34 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 Handled-By : Bob Copeland m...@bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [Bug #12490] ath5k related kernel panic in 2.6.29-rc1
On Friday 06 February 2009, Bob Copeland wrote: On Wed, 4 Feb 2009 11:23:57 +0100 (CET), Rafael J. Wysocki wrote This message has been generated automatically as a part of a report of recent regressions. The following bug entry is on the current list of known regressions from 2.6.28. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (24 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 Handled-By : Bob Copeland m...@bobcopeland.com Yes, this should still be listed. Seems there is corruption of the rate indexes but I haven't found it yet. Felix Fietkau added to CC in case he has any thoughts. Thanks for the update. Rafael -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of recent regressions. The following bug entry is on the current list of known regressions from 2.6.28. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (24 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 Handled-By : Bob Copeland m...@bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[Bug #12490] ath5k related kernel panic in 2.6.29-rc1
This message has been generated automatically as a part of a report of recent regressions. The following bug entry is on the current list of known regressions from 2.6.28. Please verify if it still should be listed and let me know (either way). Bug-Entry : http://bugzilla.kernel.org/show_bug.cgi?id=12490 Subject : ath5k related kernel panic in 2.6.29-rc1 Submitter : Sergey S. Kostyliov rathamah...@gmail.com Date: 2009-01-12 7:38 (8 days old) References : http://marc.info/?l=linux-kernelm=123174591509586w=4 Handled-By : Bob Copeland m...@bobcopeland.com -- To unsubscribe from this list: send the line unsubscribe kernel-testers in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html