staging: wilc1000: remove 'rxq_entries' from 'wilc' struct
authorAjay Singh <ajay.kathat@microchip.com>
Mon, 4 Jun 2018 05:29:09 +0000 (10:59 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 17 Jun 2018 07:05:13 +0000 (09:05 +0200)
Removed unnecessary 'rxq_entries' element from 'wilc' struct, as its
value is not used.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wilc1000/wilc_wfi_netdevice.h
drivers/staging/wilc1000/wilc_wlan.c

index ba57f42755f581959e274dfc58023ccd751c2f00..afba3729634636827a0e070605a7d597918123ac 100644 (file)
@@ -162,7 +162,6 @@ struct wilc {
        int txq_exit;
 
        struct rxq_entry_t rxq_head;
-       int rxq_entries;
        int rxq_exit;
 
        unsigned char eth_src_address[NUM_CONCURRENT_IFC][6];
index 059c5c73ee68e36fdb686aeebc3e2dff238279a5..26252d15f56a85f66bfc5be8bef4bc58213fcc41 100644 (file)
@@ -398,16 +398,14 @@ static struct txq_entry_t *wilc_wlan_txq_get_next(struct wilc *wilc,
        return tqe;
 }
 
-static int wilc_wlan_rxq_add(struct wilc *wilc, struct rxq_entry_t *rqe)
+static void wilc_wlan_rxq_add(struct wilc *wilc, struct rxq_entry_t *rqe)
 {
        if (wilc->quit)
-               return 0;
+               return;
 
        mutex_lock(&wilc->rxq_cs);
        list_add_tail(&rqe->list, &wilc->rxq_head.list);
-       wilc->rxq_entries += 1;
        mutex_unlock(&wilc->rxq_cs);
-       return wilc->rxq_entries;
 }
 
 static struct rxq_entry_t *wilc_wlan_rxq_remove(struct wilc *wilc)
@@ -419,7 +417,6 @@ static struct rxq_entry_t *wilc_wlan_rxq_remove(struct wilc *wilc)
                rqe = list_first_entry(&wilc->rxq_head.list, struct rxq_entry_t,
                                       list);
                list_del(&rqe->list);
-               wilc->rxq_entries -= 1;
        }
        mutex_unlock(&wilc->rxq_cs);
        return rqe;