diff options
author | David Howells <dhowells@redhat.com> | 2013-09-24 10:35:18 +0100 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2013-09-24 10:35:18 +0100 |
commit | b2a4df200d570b2c33a57e1ebfa5896e4bc81b69 (patch) | |
tree | 7fa48ae3c5ecff90d6d1f662fd91af5ddf74d56d /lib | |
parent | 3cb989501c2688cacbb7dc4b0d353faf838f53a1 (diff) | |
download | linux-stable-b2a4df200d570b2c33a57e1ebfa5896e4bc81b69.tar.gz linux-stable-b2a4df200d570b2c33a57e1ebfa5896e4bc81b69.tar.bz2 linux-stable-b2a4df200d570b2c33a57e1ebfa5896e4bc81b69.zip |
KEYS: Expand the capacity of a keyring
Expand the capacity of a keyring to be able to hold a lot more keys by using
the previously added associative array implementation. Currently the maximum
capacity is:
(PAGE_SIZE - sizeof(header)) / sizeof(struct key *)
which, on a 64-bit system, is a little more 500. However, since this is being
used for the NFS uid mapper, we need more than that. The new implementation
gives us effectively unlimited capacity.
With some alterations, the keyutils testsuite runs successfully to completion
after this patch is applied. The alterations are because (a) keyrings that
are simply added to no longer appear ordered and (b) some of the errors have
changed a bit.
Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/assoc_array.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/assoc_array.c b/lib/assoc_array.c index a0952818f938..17edeaf19180 100644 --- a/lib/assoc_array.c +++ b/lib/assoc_array.c @@ -12,6 +12,7 @@ */ //#define DEBUG #include <linux/slab.h> +#include <linux/err.h> #include <linux/assoc_array_priv.h> /* |