keys: Provide request_key_rcu()

Provide a request_key_rcu() function that can be used to request a key
under RCU conditions.  It can only search and check permissions; it cannot
allocate a new key, upcall or wait for an upcall to complete.  It may
return a partially constructed key.

Signed-off-by: David Howells <dhowells@redhat.com>
This commit is contained in:
David Howells 2019-06-19 16:10:15 +01:00
parent e59428f721
commit 896f1950e5
4 changed files with 66 additions and 0 deletions

View file

@ -274,6 +274,9 @@ extern struct key *request_key(struct key_type *type,
const char *description,
const char *callout_info);
extern struct key *request_key_rcu(struct key_type *type,
const char *description);
extern struct key *request_key_with_auxdata(struct key_type *type,
const char *description,
const void *callout_info,