]> git.baikalelectronics.ru Git - kernel.git/commit
bonding: Clean up resource leaks
authorJay Vosburgh <fubar@us.ibm.com>
Fri, 31 Oct 2008 00:41:15 +0000 (17:41 -0700)
committerJeff Garzik <jgarzik@redhat.com>
Fri, 31 Oct 2008 04:46:04 +0000 (00:46 -0400)
commit463adeed232ee8eedccc03bdebb9b0b2ba3d0e21
treec14f191bafc78a1194815e0e9df5223dd52e8d99
parent3dbdc455f32239e2fa058dc5a1687b4c634b6fdb
bonding: Clean up resource leaks

This patch reworks the resource free logic performed at the time
a bonding device is released.  This (a) closes two resource leaks, one
for workqueues and one for multicast lists, and (b) improves commonality
of code between the "destroy one" and "destroy all" paths by performing
final free activity via destructor instead of explicitly (and differently)
in each path.

"Sean E. Millichamp" <sean@bruenor.org> reported the workqueue
leak, and included a different patch.

Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
drivers/net/bonding/bond_main.c