diff options
author | Ajay Singh <ajay.kathat@microchip.com> | 2022-07-20 18:03:06 +0200 |
---|---|---|
committer | Kalle Valo <kvalo@kernel.org> | 2022-07-27 14:58:11 +0200 |
commit | 4c2742146de06a39d24e91155e3deec278e11932 (patch) | |
tree | 81f1b653286d01cbbb44666ec503c7d7c4cf0e08 /drivers/net/wireless/microchip/wilc1000 | |
parent | wifi: wilc1000: add 'isinit' flag for SDIO bus similar to SPI (diff) | |
download | linux-4c2742146de06a39d24e91155e3deec278e11932.tar.xz linux-4c2742146de06a39d24e91155e3deec278e11932.zip |
wifi: wilc1000: use existing iftype variable to store the interface type
For consistency, use an existing 'iftype' element which was already
having the interface type. Replace 'mode' with 'iftype' as it was used
for the same purpose.
Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220720160302.231516-8-ajay.kathat@microchip.com
Diffstat (limited to 'drivers/net/wireless/microchip/wilc1000')
-rw-r--r-- | drivers/net/wireless/microchip/wilc1000/netdev.c | 6 | ||||
-rw-r--r-- | drivers/net/wireless/microchip/wilc1000/netdev.h | 1 |
2 files changed, 3 insertions, 4 deletions
diff --git a/drivers/net/wireless/microchip/wilc1000/netdev.c b/drivers/net/wireless/microchip/wilc1000/netdev.c index 2de5838a4426..9b319a455b96 100644 --- a/drivers/net/wireless/microchip/wilc1000/netdev.c +++ b/drivers/net/wireless/microchip/wilc1000/netdev.c @@ -97,12 +97,12 @@ static struct net_device *get_if_handler(struct wilc *wilc, u8 *mac_header) struct ieee80211_hdr *h = (struct ieee80211_hdr *)mac_header; list_for_each_entry_rcu(vif, &wilc->vif_list, list) { - if (vif->mode == WILC_STATION_MODE) + if (vif->iftype == WILC_STATION_MODE) if (ether_addr_equal_unaligned(h->addr2, vif->bssid)) { ndev = vif->ndev; goto out; } - if (vif->mode == WILC_AP_MODE) + if (vif->iftype == WILC_AP_MODE) if (ether_addr_equal_unaligned(h->addr1, vif->bssid)) { ndev = vif->ndev; goto out; @@ -122,7 +122,7 @@ void wilc_wlan_set_bssid(struct net_device *wilc_netdev, const u8 *bssid, else eth_zero_addr(vif->bssid); - vif->mode = mode; + vif->iftype = mode; } int wilc_wlan_get_num_conn_ifcs(struct wilc *wilc) diff --git a/drivers/net/wireless/microchip/wilc1000/netdev.h b/drivers/net/wireless/microchip/wilc1000/netdev.h index 822e65d00f53..43c085c74b7a 100644 --- a/drivers/net/wireless/microchip/wilc1000/netdev.h +++ b/drivers/net/wireless/microchip/wilc1000/netdev.h @@ -177,7 +177,6 @@ struct wilc_vif { u8 bssid[ETH_ALEN]; struct host_if_drv *hif_drv; struct net_device *ndev; - u8 mode; struct timer_list during_ip_timer; struct timer_list periodic_rssi; struct rf_info periodic_stat; |