]> git.baikalelectronics.ru Git - kernel.git/commit
s390: use free_netdev(netdev) instead of kfree()
authorVasiliy Kulikov <segooon@gmail.com>
Mon, 27 Sep 2010 01:56:06 +0000 (18:56 -0700)
committerDavid S. Miller <davem@davemloft.net>
Mon, 27 Sep 2010 01:56:06 +0000 (18:56 -0700)
commitaaca7b70ad487badc0d9621a750759ce2c28d029
treeb2f78691199167967e694dccec273afa29ba0a0c
parentd4509a24900bdf2467a8ef4415c54d58e7f5b858
s390: use free_netdev(netdev) instead of kfree()

Freeing netdev without free_netdev() leads to net, tx leaks.
I might lead to dereferencing freed pointer.

The semantic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

@@
struct net_device* dev;
@@

-kfree(dev)
+free_netdev(dev)

Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/s390/net/ctcm_main.c