Quellcode durchsuchen

net: dsa: Remove redundant NULL dst check

tag_lan9303.c does check for a NULL dst but that's already checked by
dsa_switch_rcv() one layer above.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Acked-by: Juergen Borleis <jbe@pengutronix.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Florian Fainelli vor 8 Jahren
Ursprung
Commit
8e6c1812e6
1 geänderte Dateien mit 0 neuen und 5 gelöschten Zeilen
  1. 0 5
      net/dsa/tag_lan9303.c

+ 0 - 5
net/dsa/tag_lan9303.c

@@ -79,11 +79,6 @@ static struct sk_buff *lan9303_rcv(struct sk_buff *skb, struct net_device *dev,
 	struct dsa_switch *ds;
 	struct dsa_switch *ds;
 	unsigned int source_port;
 	unsigned int source_port;
 
 
-	if (unlikely(!dst)) {
-		dev_warn_ratelimited(&dev->dev, "Dropping packet, due to missing switch tree device\n");
-		return NULL;
-	}
-
 	ds = dst->ds[0];
 	ds = dst->ds[0];
 
 
 	if (unlikely(!ds)) {
 	if (unlikely(!ds)) {