diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2011-11-17 02:20:58 -0500 |
---|---|---|
committer | Eric W. Biederman <ebiederm@xmission.com> | 2012-04-07 20:11:46 -0400 |
commit | 7b44ab978b77a91b327058a0f4db7e6fcdb90b92 (patch) | |
tree | 632c872f0b88d001f1bddce2c0aacd77bf062454 /include/linux/user_namespace.h | |
parent | 5673a94c14574d7c6495c320c6b0e480673d54bd (diff) |
userns: Disassociate user_struct from the user_namespace.
Modify alloc_uid to take a kuid and make the user hash table global.
Stop holding a reference to the user namespace in struct user_struct.
This simplifies the code and makes the per user accounting not
care about which user namespace a uid happens to appear in.
Acked-by: Serge Hallyn <serge.hallyn@canonical.com>
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Diffstat (limited to 'include/linux/user_namespace.h')
-rw-r--r-- | include/linux/user_namespace.h | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/include/linux/user_namespace.h b/include/linux/user_namespace.h index dc2d85a76376..d767508db4f9 100644 --- a/include/linux/user_namespace.h +++ b/include/linux/user_namespace.h | |||
@@ -6,12 +6,8 @@ | |||
6 | #include <linux/sched.h> | 6 | #include <linux/sched.h> |
7 | #include <linux/err.h> | 7 | #include <linux/err.h> |
8 | 8 | ||
9 | #define UIDHASH_BITS (CONFIG_BASE_SMALL ? 3 : 7) | ||
10 | #define UIDHASH_SZ (1 << UIDHASH_BITS) | ||
11 | |||
12 | struct user_namespace { | 9 | struct user_namespace { |
13 | struct kref kref; | 10 | struct kref kref; |
14 | struct hlist_head uidhash_table[UIDHASH_SZ]; | ||
15 | struct user_namespace *parent; | 11 | struct user_namespace *parent; |
16 | struct user_struct *creator; | 12 | struct user_struct *creator; |
17 | struct work_struct destroyer; | 13 | struct work_struct destroyer; |