projects
/
platform
/
kernel
/
linux-starfive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1da7382
)
net: dsa: sja1105: Unset port from forwarding mask unconditionally on fdb_del
author
Vladimir Oltean
<olteanv@gmail.com>
Sun, 2 Jun 2019 21:15:54 +0000
(
00:15
+0300)
committer
David S. Miller
<davem@davemloft.net>
Tue, 4 Jun 2019 18:49:20 +0000
(11:49 -0700)
This is a cosmetic patch that simplifies the code by removing a
redundant check. A logical AND-with-zero performed on a zero is still
zero.
Signed-off-by: Vladimir Oltean <olteanv@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/sja1105/sja1105_main.c
patch
|
blob
|
history
diff --git
a/drivers/net/dsa/sja1105/sja1105_main.c
b/drivers/net/dsa/sja1105/sja1105_main.c
index 46e2cc7b9ddc41c03d17cfd0a626c173302b16b3..8343dcf483843b0d0d8a0bd9ec463b6ecb03211e 100644
(file)
--- a/
drivers/net/dsa/sja1105/sja1105_main.c
+++ b/
drivers/net/dsa/sja1105/sja1105_main.c
@@
-903,8
+903,8
@@
int sja1105et_fdb_del(struct dsa_switch *ds, int port,
* need to completely evict the FDB entry.
* Otherwise we just write it back.
*/
- if (l2_lookup.destports & BIT(port))
- l2_lookup.destports &= ~BIT(port);
+ l2_lookup.destports &= ~BIT(port);
+
if (l2_lookup.destports)
keep = true;
else