]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commit
sh_eth: fix bitbang memory leak
authorSergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Tue, 19 Mar 2013 13:40:23 +0000 (13:40 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 20 Mar 2013 16:17:59 +0000 (12:17 -0400)
commit0582b7d15f8a7ae53dd2128b8eb01567b3fd2277
tree3573e1c8cbbff92617caaf914efa10c36e58cd6e
parent283951f95b067877ca5ea77afaa212bb1e0507b5
sh_eth: fix bitbang memory leak

sh_mdio_init() allocates pointer to 'struct bb_info' but only stores it locally,
so that sh_mdio_release() can't free it on driver unload.  Add the pointer to
'struct bb_info' to 'struct sh_eth_private', so that sh_mdio_init() can save
'bitbang' variable for sh_mdio_release() to be able to free it later...

Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/renesas/sh_eth.c
drivers/net/ethernet/renesas/sh_eth.h