]> git.baikalelectronics.ru Git - kernel.git/commit
KEYS: Introduce a search context structure
authorDavid Howells <dhowells@redhat.com>
Tue, 24 Sep 2013 09:35:15 +0000 (10:35 +0100)
committerDavid Howells <dhowells@redhat.com>
Tue, 24 Sep 2013 09:35:15 +0000 (10:35 +0100)
commit3508413fe7c406009bcd0e5f9b5dfd073ccaf810
treeecf5a1d74d507410a9defa32edb4ea73edb9d205
parent9c589b4e21fa9b959b7d069ff1684ef9266345c5
KEYS: Introduce a search context structure

Search functions pass around a bunch of arguments, each of which gets copied
with each call.  Introduce a search context structure to hold these.

Whilst we're at it, create a search flag that indicates whether the search
should be directly to the description or whether it should iterate through all
keys looking for a non-description match.

This will be useful when keyrings use a generic data struct with generic
routines to manage their content as the search terms can just be passed
through to the iterator callback function.

Also, for future use, the data to be supplied to the match function is
separated from the description pointer in the search context.  This makes it
clear which is being supplied.

Signed-off-by: David Howells <dhowells@redhat.com>
include/linux/key-type.h
security/keys/internal.h
security/keys/keyring.c
security/keys/proc.c
security/keys/process_keys.c
security/keys/request_key.c
security/keys/request_key_auth.c
security/keys/user_defined.c