diff options
author | Philipp Hortmann <philipp.g.hortmann@gmail.com> | 2023-08-13 08:36:48 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-08-22 15:44:31 +0200 |
commit | 42f9bcfc71e8e7535631ac2fcb8a69700e9b3296 (patch) | |
tree | 8d58604543cc8448d7f8fedd475c330d80959dcc /drivers/staging | |
parent | 31a14cba17532a85f0aedcb38dfc5f15f235fee9 (diff) | |
download | linux-stable-42f9bcfc71e8e7535631ac2fcb8a69700e9b3296.tar.gz linux-stable-42f9bcfc71e8e7535631ac2fcb8a69700e9b3296.tar.bz2 linux-stable-42f9bcfc71e8e7535631ac2fcb8a69700e9b3296.zip |
staging: rtl8192e: Remove unsupported mode IW_MODE_MESH
Tasklet irq_rx_tasklet is scheduled when hw is receiving frames. Function
_rtl92e_irq_rx_tasklet() is then called which calls then
_rtl92e_rx_normal(). In _rtl92e_rx_normal() all frames are processed by
rtllib_rx(). When ieee->iw_mode is IW_MODE_MESH the function returns
0. The calling function then calls: dev_kfree_skb_any() which clears
the skb. So the driver clears all packets received in this mode. Remove
dead code in mode IW_MODE_MESH.
Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/54230361abba9f33827eac9bf5074dd9f62d787b.1691908402.git.philipp.g.hortmann@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r-- | drivers/staging/rtl8192e/rtllib.h | 4 | ||||
-rw-r--r-- | drivers/staging/rtl8192e/rtllib_rx.c | 20 |
2 files changed, 8 insertions, 16 deletions
diff --git a/drivers/staging/rtl8192e/rtllib.h b/drivers/staging/rtl8192e/rtllib.h index 0c812eb02ba6..afde4812a221 100644 --- a/drivers/staging/rtl8192e/rtllib.h +++ b/drivers/staging/rtl8192e/rtllib.h @@ -89,10 +89,6 @@ static inline void *netdev_priv_rsl(struct net_device *dev) #define HIGH_QUEUE 7 #define BEACON_QUEUE 8 -#ifndef IW_MODE_MESH -#define IW_MODE_MESH 7 -#endif - #define IE_CISCO_FLAG_POSITION 0x08 #define SUPPORT_CKIP_MIC 0x08 #define SUPPORT_CKIP_PK 0x10 diff --git a/drivers/staging/rtl8192e/rtllib_rx.c b/drivers/staging/rtl8192e/rtllib_rx.c index 322e603237d4..40e7bbb17c0d 100644 --- a/drivers/staging/rtl8192e/rtllib_rx.c +++ b/drivers/staging/rtl8192e/rtllib_rx.c @@ -1013,17 +1013,15 @@ static int rtllib_rx_data_filter(struct rtllib_device *ieee, u16 fc, } } - if (ieee->iw_mode != IW_MODE_MESH) { - /* packets from our adapter are dropped (echo) */ - if (!memcmp(src, ieee->dev->dev_addr, ETH_ALEN)) - return -1; + /* packets from our adapter are dropped (echo) */ + if (!memcmp(src, ieee->dev->dev_addr, ETH_ALEN)) + return -1; - /* {broad,multi}cast packets to our BSS go through */ - if (is_multicast_ether_addr(dst)) { - if (memcmp(bssid, ieee->current_network.bssid, - ETH_ALEN)) - return -1; - } + /* {broad,multi}cast packets to our BSS go through */ + if (is_multicast_ether_addr(dst)) { + if (memcmp(bssid, ieee->current_network.bssid, + ETH_ALEN)) + return -1; } return 0; } @@ -1499,8 +1497,6 @@ int rtllib_rx(struct rtllib_device *ieee, struct sk_buff *skb, case IW_MODE_MONITOR: ret = rtllib_rx_Monitor(ieee, skb, rx_stats); break; - case IW_MODE_MESH: - break; default: netdev_info(ieee->dev, "%s: ERR iw mode!!!\n", __func__); break; |