From: David Howells <dhowells@redhat.com>

During system boot many probes, etc.  will generate upcalls to userspace
via call_usermodehelper().  This has the effect of calling execve() before
the key subsystem has been initialized, and thus Oopsing on a NULL key_jar
during key_alloc().  Move key_init to security_initcall so that it's called
along with other security initialization routines which have similar
requirements.

Signed-off-by: Chris Wright <chrisw@osdl.org>
Signed-Off-By: David Howells <dhowells@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 25-akpm/security/keys/key.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -puN security/keys/key.c~move-key_init-to-security_initcall security/keys/key.c
--- 25/security/keys/key.c~move-key_init-to-security_initcall	2004-10-26 03:03:17.793541784 -0700
+++ 25-akpm/security/keys/key.c	2004-10-26 03:03:17.796541328 -0700
@@ -1036,4 +1036,4 @@ static int __init key_init(void)
 
 } /* end key_init() */
 
-subsys_initcall(key_init);
+security_initcall(key_init);
_