]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
ath5k: remove pointless rx error overlay struct
authorBruno Randolf <br1@einfach.org>
Wed, 16 Jun 2010 10:12:12 +0000 (19:12 +0900)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 16 Jun 2010 18:59:04 +0000 (14:59 -0400)
ath5k_hw_rx_error was only used once, where we could easily just use
ath5k_hw_rx_status as well, so remove it.

Signed-off-by: Bruno Randolf <br1@einfach.org>
Acked-by: Bob Copeland <me@bobcopeland.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath5k/debug.c
drivers/net/wireless/ath/ath5k/desc.c
drivers/net/wireless/ath/ath5k/desc.h

index 02db66e55480ba3434450572a58544de67351a34..8c638865c712c97173eb1ca4fab24a64d32a2090 100644 (file)
@@ -925,7 +925,7 @@ ath5k_debug_printrxbuf(struct ath5k_buf *bf, int done,
                ds, (unsigned long long)bf->daddr,
                ds->ds_link, ds->ds_data,
                rd->rx_ctl.rx_control_0, rd->rx_ctl.rx_control_1,
-               rd->u.rx_stat.rx_status_0, rd->u.rx_stat.rx_status_1,
+               rd->rx_stat.rx_status_0, rd->rx_stat.rx_status_1,
                !done ? ' ' : (rs->rs_status == 0) ? '*' : '!');
 }
 
index 50fc931fd398f5c3b8eeb7fa0d71cbe82d827bfa..eb1427ce6cb57331f64a9640b3a643345785bd4f 100644 (file)
@@ -510,7 +510,7 @@ static int ath5k_hw_proc_5210_rx_status(struct ath5k_hw *ah,
 {
        struct ath5k_hw_rx_status *rx_status;
 
-       rx_status = &desc->ud.ds_rx.u.rx_stat;
+       rx_status = &desc->ud.ds_rx.rx_stat;
 
        /* No frame received / not ready */
        if (unlikely(!(rx_status->rx_status_1 &
@@ -581,12 +581,8 @@ static int ath5k_hw_proc_5212_rx_status(struct ath5k_hw *ah,
                                        struct ath5k_rx_status *rs)
 {
        struct ath5k_hw_rx_status *rx_status;
-       struct ath5k_hw_rx_error *rx_err;
 
-       rx_status = &desc->ud.ds_rx.u.rx_stat;
-
-       /* Overlay on error */
-       rx_err = &desc->ud.ds_rx.u.rx_err;
+       rx_status = &desc->ud.ds_rx.rx_stat;
 
        /* No frame received / not ready */
        if (unlikely(!(rx_status->rx_status_1 &
@@ -632,8 +628,8 @@ static int ath5k_hw_proc_5212_rx_status(struct ath5k_hw *ah,
                if (rx_status->rx_status_1 &
                                AR5K_5212_RX_DESC_STATUS1_PHY_ERROR) {
                        rs->rs_status |= AR5K_RXERR_PHY;
-                       rs->rs_phyerr |= AR5K_REG_MS(rx_err->rx_error_1,
-                                          AR5K_RX_DESC_ERROR1_PHY_ERROR_CODE);
+                       rs->rs_phyerr |= AR5K_REG_MS(rx_status->rx_status_1,
+                               AR5K_5212_RX_DESC_STATUS1_PHY_ERROR_CODE);
                        ath5k_ani_phy_error_report(ah, rs->rs_phyerr);
                }
 
index 64538fbe416732f5353433d32baad77e13039c48..45f26446dbff85b84fb8c6379a92342c35b1cd7e 100644 (file)
@@ -96,21 +96,8 @@ struct ath5k_hw_rx_status {
 #define AR5K_5212_RX_DESC_STATUS1_RECEIVE_TIMESTAMP    0x7fff0000
 #define AR5K_5212_RX_DESC_STATUS1_RECEIVE_TIMESTAMP_S  16
 #define AR5K_5212_RX_DESC_STATUS1_KEY_CACHE_MISS       0x80000000
-
-/*
- * common hardware RX error descriptor
- */
-struct ath5k_hw_rx_error {
-       u32     rx_error_0; /* RX status word 0 */
-       u32     rx_error_1; /* RX status word 1 */
-} __packed;
-
-/* RX error word 0 fields/flags */
-#define AR5K_RX_DESC_ERROR0                    0x00000000
-
-/* RX error word 1 fields/flags */
-#define AR5K_RX_DESC_ERROR1_PHY_ERROR_CODE     0x0000ff00
-#define AR5K_RX_DESC_ERROR1_PHY_ERROR_CODE_S   8
+#define AR5K_5212_RX_DESC_STATUS1_PHY_ERROR_CODE       0x0000ff00
+#define AR5K_5212_RX_DESC_STATUS1_PHY_ERROR_CODE_S     8
 
 /**
  * enum ath5k_phy_error_code - PHY Error codes
@@ -316,11 +303,8 @@ struct ath5k_hw_5212_tx_desc {
  * common hardware RX descriptor
  */
 struct ath5k_hw_all_rx_desc {
-       struct ath5k_hw_rx_ctl                  rx_ctl;
-       union {
-               struct ath5k_hw_rx_status       rx_stat;
-               struct ath5k_hw_rx_error        rx_err;
-       } u;
+       struct ath5k_hw_rx_ctl          rx_ctl;
+       struct ath5k_hw_rx_status       rx_stat;
 } __packed;
 
 /*