aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/ks7010
diff options
context:
space:
mode:
authorTobin C. Harding <me@tobin.cc>2017-04-27 11:25:12 +1000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-04-28 11:45:49 +0200
commit208c66f2fb3d9cd398386785aae116753a27e8c4 (patch)
tree750f6e51d8f20b95aafebbd00791c061b40176f7 /drivers/staging/ks7010
parentstaging: lustre: remove void function return (diff)
downloadlinux-dev-208c66f2fb3d9cd398386785aae116753a27e8c4.tar.xz
linux-dev-208c66f2fb3d9cd398386785aae116753a27e8c4.zip
staging: ks7010: remove unnecessary address check
Currently source and destination ethernet addresses are checked twice, once in hostif_data_indication() and then again in hostif_data_indication_wpa(). The second of these functions is called from the first right after the address check is done. This check is a duplicate and is unnecessary. Remove unnecessary duplicate address check. Signed-off-by: Tobin C. Harding <me@tobin.cc> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/ks7010')
-rw-r--r--drivers/staging/ks7010/ks_hostif.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/staging/ks7010/ks_hostif.c b/drivers/staging/ks7010/ks_hostif.c
index 7151f16e2f9c..2216409bcb3d 100644
--- a/drivers/staging/ks7010/ks_hostif.c
+++ b/drivers/staging/ks7010/ks_hostif.c
@@ -326,10 +326,6 @@ int hostif_data_indication_wpa(struct ks_wlan_private *priv,
eth_hdr = (struct ether_hdr *)(priv->rxp);
eth_proto = ntohs(eth_hdr->h_proto);
- /* source address check */
- if (memcmp(&eth_hdr->h_source[0], &priv->eth_addr[0], ETH_ALEN) == 0)
- return 0;
-
if (eth_hdr->h_dest_snap != eth_hdr->h_source_snap) {
DPRINTK(1, "invalid data format\n");
priv->nstats.rx_errors++;