Commit bfb85c9f authored by Randy Dunlap's avatar Randy Dunlap Committed by David S. Miller
Browse files

[ATM]: Fix clip module reload crash.



net/atm/clip.c crashes the kernel if it (module) is loaded, removed,
and then loaded again.  Its exit call to neigh_table_clear()
should destroy the cache after freeing it.

Signed-off-by: default avatarRandy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 33b0c4fe
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -1438,6 +1438,9 @@ int neigh_table_clear(struct neigh_table *tbl)
	free_percpu(tbl->stats);
	tbl->stats = NULL;

	kmem_cache_destroy(tbl->kmem_cachep);
	tbl->kmem_cachep = NULL;

	return 0;
}