]> git.karo-electronics.de Git - karo-tx-linux.git/commit
module: remove over-zealous check in __module_get()
authorRusty Russell <rusty@rustcorp.com.au>
Sat, 7 Feb 2009 07:45:56 +0000 (18:15 +1030)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 12 Feb 2009 17:31:02 +0000 (09:31 -0800)
commitc8e7fd2807c76ec171fee6bce142cd06b5745497
tree1a608c7752b37135485f98ba080026235ca28af3
parentd7a95c07acbca8128e8a3a776bc1ab43ad744f9f
module: remove over-zealous check in __module_get()

commit 7f9a50a5b89b87f8e754f59ae9968da28be618a5 upstream.

Impact: fix spurious BUG_ON() triggered under load

module_refcount() isn't reliable outside stop_machine(), as demonstrated
by Karsten Keil <kkeil@suse.de>, networking can trigger it under load
(an inc on one cpu and dec on another while module_refcount() is tallying
 can give false results, for example).

Almost noone should be using __module_get, but that's another issue.

Cc: Karsten Keil <kkeil@suse.de>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
include/linux/module.h