summaryrefslogtreecommitdiffstats
path: root/mm/bootmem.c
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2009-04-09 17:14:05 +0100
committerLinus Torvalds <torvalds@linux-foundation.org>2009-04-09 10:41:19 -0700
commit34574dd10b6d0697b86703388d6d6af9cbf4bb48 (patch)
tree89eb52c0777687d4704d3ab3a370c50c1fe9479c /mm/bootmem.c
parent11ff5f6affe9b75f115a900a5584db339d46002b (diff)
downloadop-kernel-dev-34574dd10b6d0697b86703388d6d6af9cbf4bb48.zip
op-kernel-dev-34574dd10b6d0697b86703388d6d6af9cbf4bb48.tar.gz
keys: Handle there being no fallback destination keyring for request_key()
When request_key() is called, without there being any standard process keyrings on which to fall back if a destination keyring is not specified, an oops is liable to occur when construct_alloc_key() calls down_write() on dest_keyring's semaphore. Due to function inlining this may be seen as an oops in down_write() as called from request_key_and_link(). This situation crops up during boot, where request_key() is called from within the kernel (such as in CIFS mounts) where nobody is actually logged in, and so PAM has not had a chance to create a session keyring and user keyrings to act as the fallback. To fix this, make construct_alloc_key() not attempt to cache a key if there is no fallback key if no destination keyring is given specifically. Signed-off-by: David Howells <dhowells@redhat.com> Tested-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/bootmem.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud