Herbert Xu
34c9a0ffc7
crypto: fix broken crypto_register_instance() module handling
...
Commit 9c521a200bc3 ("crypto: api - remove instance when test failed")
tried to grab a module reference count before the module was even set.
Worse, it then goes on to free the module reference count after it is
set so you quickly end up with a negative module reference count which
prevents people from using any instances belonging to that module.
This patch moves the module initialisation before the reference
count.
Reported-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-04-15 20:26:16 -07:00
..
2014-11-24 22:43:57 +08:00
2015-03-31 21:21:04 +08:00
2015-01-26 11:34:22 +11:00
2014-12-22 23:02:35 +11:00
2015-01-13 22:29:11 +11:00
2015-04-01 15:32:20 -04:00
2015-01-26 11:34:22 +11:00
2015-04-15 20:26:16 -07:00
2015-04-15 14:09:46 -07:00
2015-04-11 15:53:35 -04:00
2015-04-15 10:42:15 -07:00
2015-04-11 15:53:35 -04:00
2015-03-09 21:06:18 +11:00
2014-11-24 22:43:57 +08:00
2015-03-31 21:21:03 +08:00
2014-11-24 22:43:57 +08:00
2014-11-26 20:06:30 +08:00
2014-11-26 20:06:30 +08:00
2015-01-13 22:29:11 +11:00
2015-01-13 22:29:11 +11:00
2015-01-13 22:29:11 +11:00
2015-01-13 22:29:11 +11:00
2014-11-26 20:06:30 +08:00
2014-11-26 20:06:30 +08:00
2014-11-26 20:06:30 +08:00
2014-11-26 20:06:30 +08:00
2014-11-24 22:43:57 +08:00
2015-01-13 22:29:11 +11:00
2015-01-13 22:29:11 +11:00
2015-03-31 21:21:04 +08:00
2014-11-24 22:43:57 +08:00
2015-04-08 22:20:06 +08:00
2014-11-26 20:06:30 +08:00
2015-01-20 14:44:15 +11:00
2014-11-24 22:43:57 +08:00
2015-01-13 22:29:11 +11:00
2015-03-09 21:06:18 +11:00
2014-11-26 20:06:30 +08:00
2014-11-26 20:06:30 +08:00
2014-11-24 22:43:57 +08:00
2014-11-26 20:06:30 +08:00
2015-01-13 22:29:11 +11:00
2014-11-26 20:06:30 +08:00
2015-04-07 21:34:20 +08:00
2014-11-24 22:43:57 +08:00
2015-01-13 22:29:11 +11:00
2014-11-26 20:06:30 +08:00
2014-11-24 22:43:57 +08:00
2014-11-24 22:43:57 +08:00
2014-11-24 22:43:57 +08:00
2015-03-04 22:12:39 +13:00
2015-03-31 21:21:13 +08:00
2014-11-24 22:43:57 +08:00
2014-11-24 22:43:57 +08:00
2014-11-24 22:43:57 +08:00
2014-11-26 20:06:30 +08:00
2014-11-26 20:06:30 +08:00
2015-03-31 21:21:04 +08:00
2014-11-24 22:43:57 +08:00
2014-11-24 22:43:57 +08:00
2014-11-24 22:43:57 +08:00
2014-11-24 22:43:57 +08:00
2015-01-13 22:29:11 +11:00
2015-01-26 11:34:22 +11:00
2014-11-24 22:43:57 +08:00
2015-01-20 14:44:16 +11:00
2015-01-13 22:29:11 +11:00
2015-04-10 21:39:40 +08:00
2015-04-10 21:39:41 +08:00
2015-04-10 21:39:41 +08:00
2015-03-12 01:11:05 +11:00
2015-01-13 22:29:11 +11:00
2015-03-31 21:21:03 +08:00
2015-01-13 22:29:11 +11:00
2015-01-13 22:29:11 +11:00
2014-11-26 20:06:30 +08:00
2015-01-13 22:29:11 +11:00
2014-11-26 20:06:30 +08:00
2014-11-26 20:06:30 +08:00
2014-11-24 22:43:57 +08:00