diff options
author | Markus Elfring <elfring@users.sourceforge.net> | 2019-09-15 19:21:05 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-09-16 21:45:32 +0200 |
commit | 56a4e37ef14f569017131d1cba22da4fcfe28207 (patch) | |
tree | 0d7b95358e418e0c2bf331566823aec0a4342d69 /drivers/s390/net | |
parent | f432c2e30461cfdfde5ee74ad62d9684016f3623 (diff) | |
download | linux-56a4e37ef14f569017131d1cba22da4fcfe28207.tar.gz linux-56a4e37ef14f569017131d1cba22da4fcfe28207.tar.bz2 linux-56a4e37ef14f569017131d1cba22da4fcfe28207.zip |
s390/ctcm: Delete unnecessary checks before the macro call “dev_kfree_skb”
The dev_kfree_skb() function performs also input parameter validation.
Thus the test around the shown calls is not needed.
This issue was detected by using the Coccinelle software.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/s390/net')
-rw-r--r-- | drivers/s390/net/ctcm_main.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/s390/net/ctcm_main.c b/drivers/s390/net/ctcm_main.c index 2117870ed855..437a6d822105 100644 --- a/drivers/s390/net/ctcm_main.c +++ b/drivers/s390/net/ctcm_main.c @@ -1072,10 +1072,8 @@ static void ctcm_free_netdevice(struct net_device *dev) if (grp) { if (grp->fsm) kfree_fsm(grp->fsm); - if (grp->xid_skb) - dev_kfree_skb(grp->xid_skb); - if (grp->rcvd_xid_skb) - dev_kfree_skb(grp->rcvd_xid_skb); + dev_kfree_skb(grp->xid_skb); + dev_kfree_skb(grp->rcvd_xid_skb); tasklet_kill(&grp->mpc_tasklet2); kfree(grp); priv->mpcg = NULL; |