aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath9k/rc.c
diff options
context:
space:
mode:
authorLuis R. Rodriguez <lrodriguez@atheros.com>2009-09-14 02:28:00 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-10-07 16:39:30 -0400
commit9680e8a391078a2bfa099b2c59542a6916a023ed (patch)
tree23167a05d19e72826bd35c661bd702b463294789 /drivers/net/wireless/ath/ath9k/rc.c
parente3d01bfc3ea4f17c9e91bb930f10062efb0c86eb (diff)
ath9k: remove driver ASSERT, just use BUG_ON()
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/rc.c')
-rw-r--r--drivers/net/wireless/ath/ath9k/rc.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/wireless/ath/ath9k/rc.c b/drivers/net/wireless/ath/ath9k/rc.c
index 7346649af2d..063936423d8 100644
--- a/drivers/net/wireless/ath/ath9k/rc.c
+++ b/drivers/net/wireless/ath/ath9k/rc.c
@@ -425,7 +425,7 @@ static void ath_rc_init_valid_txmask(struct ath_rate_priv *ath_rc_priv)
425static inline void ath_rc_set_valid_txmask(struct ath_rate_priv *ath_rc_priv, 425static inline void ath_rc_set_valid_txmask(struct ath_rate_priv *ath_rc_priv,
426 u8 index, int valid_tx_rate) 426 u8 index, int valid_tx_rate)
427{ 427{
428 ASSERT(index <= ath_rc_priv->rate_table_size); 428 BUG_ON(index > ath_rc_priv->rate_table_size);
429 ath_rc_priv->valid_rate_index[index] = valid_tx_rate ? 1 : 0; 429 ath_rc_priv->valid_rate_index[index] = valid_tx_rate ? 1 : 0;
430} 430}
431 431
@@ -1243,7 +1243,7 @@ static void ath_rc_init(struct ath_softc *sc,
1243 1243
1244 ath_rc_priv->rate_table_size = hi + 1; 1244 ath_rc_priv->rate_table_size = hi + 1;
1245 ath_rc_priv->rate_max_phy = 0; 1245 ath_rc_priv->rate_max_phy = 0;
1246 ASSERT(ath_rc_priv->rate_table_size <= RATE_TABLE_SIZE); 1246 BUG_ON(ath_rc_priv->rate_table_size > RATE_TABLE_SIZE);
1247 1247
1248 for (i = 0, k = 0; i < WLAN_RC_PHY_MAX; i++) { 1248 for (i = 0, k = 0; i < WLAN_RC_PHY_MAX; i++) {
1249 for (j = 0; j < ath_rc_priv->valid_phy_ratecnt[i]; j++) { 1249 for (j = 0; j < ath_rc_priv->valid_phy_ratecnt[i]; j++) {
@@ -1257,8 +1257,8 @@ static void ath_rc_init(struct ath_softc *sc,
1257 1257
1258 ath_rc_priv->rate_max_phy = ath_rc_priv->valid_phy_rateidx[i][j-1]; 1258 ath_rc_priv->rate_max_phy = ath_rc_priv->valid_phy_rateidx[i][j-1];
1259 } 1259 }
1260 ASSERT(ath_rc_priv->rate_table_size <= RATE_TABLE_SIZE); 1260 BUG_ON(ath_rc_priv->rate_table_size > RATE_TABLE_SIZE);
1261 ASSERT(k <= RATE_TABLE_SIZE); 1261 BUG_ON(k > RATE_TABLE_SIZE);
1262 1262
1263 ath_rc_priv->max_valid_rate = k; 1263 ath_rc_priv->max_valid_rate = k;
1264 ath_rc_sort_validrates(rate_table, ath_rc_priv); 1264 ath_rc_sort_validrates(rate_table, ath_rc_priv);