mirror of
https://github.com/torvalds/linux.git
synced 2026-11-26 08:23:17 +00:00
register_memory()/unregister_memory() never gets called with "root". unregister_memory() is accessing kobject_name of the object just freed up. Since no one uses the code, lets take the code out. And also, make register_memory() static. Another bug fix - before calling unregister_memory() remove_memory_block() gets a ref on kobject. unregister_memory() need to drop that ref before calling sysdev_unregister(). Signed-off-by: Badari Pulavarty <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>