From: Sudip Mukherjee Date: Mon, 3 Nov 2014 12:12:29 +0000 (+0530) Subject: hamradio: 6pack: remove unnecessary check X-Git-Tag: firefly_0821_release~176^2~2717^2~292 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=ec5a0ec1a4b0a065148905340cd5f0e2a4425b6f;p=firefly-linux-kernel-4.4.55.git hamradio: 6pack: remove unnecessary check this is check for dev is unnecessary, as we are already checking dev after allocating it via alloc_netdev, and jumping to label: out if it is NULL. Signed-off-by: Sudip Mukherjee Signed-off-by: David S. Miller --- diff --git a/drivers/net/hamradio/6pack.c b/drivers/net/hamradio/6pack.c index c3c4051a089d..daca0dee88f3 100644 --- a/drivers/net/hamradio/6pack.c +++ b/drivers/net/hamradio/6pack.c @@ -675,8 +675,7 @@ out_free: kfree(xbuff); kfree(rbuff); - if (dev) - free_netdev(dev); + free_netdev(dev); out: return err;