From: Florian Fainelli Date: Thu, 20 Apr 2017 22:47:22 +0000 (-0700) Subject: net: dsa: Remove redundant NULL dst check X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=8e6c1812e632ae3b54a1a9da759cad762f633e11;p=openwrt%2Fstaging%2Fblogic.git 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 Acked-by: Juergen Borleis Signed-off-by: David S. Miller --- diff --git a/net/dsa/tag_lan9303.c b/net/dsa/tag_lan9303.c index 563b6c8fe445..70130ed5c21a 100644 --- a/net/dsa/tag_lan9303.c +++ b/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; 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]; if (unlikely(!ds)) {