From: Sergey Senozhatsky Date: Sat, 13 Dec 2014 00:56:56 +0000 (-0800) Subject: zsmalloc: fix zs_init cpu notifier error handling X-Git-Tag: omap-for-v3.20/drop-legacy-3517~97^2~41 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b1b00a5b8a6cf32e3973507decf1216709b55072;p=pandora-kernel.git zsmalloc: fix zs_init cpu notifier error handling Mahendran Ganesh reported that zpool-enabled zsmalloc should not call zpool_unregister_driver() from zs_init() if cpu notifier registration has failed, because error handling is performed before we register the driver via zpool_register_driver() call. Factor out cpu notifier registration and unregistration code and fix zs_init() error handling. link: http://lkml.iu.edu//hypermail/linux/kernel/1411.1/04156.html [akpm@linux-foundation.org: squash bogus gcc warning] [akpm@linux-foundation.org: use __init and __exit] Signed-off-by: Sergey Senozhatsky Reported-by: Mahendran Ganesh Cc: Minchan Kim Cc: Nitin Gupta Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed