mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-20 21:51:05 +00:00
sunrpc: Hash uids by first computing their value in the initial userns
In svcauth_unix introduce a helper unix_gid_hash as otherwise the expresion to generate the hash value is just too long. Cc: "J. Bruce Fields" <bfields@fieldses.org> Cc: Trond Myklebust <Trond.Myklebust@netapp.com> Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
This commit is contained in:
parent
683428fae8
commit
9e469e30d7
2 changed files with 8 additions and 3 deletions
|
@ -412,7 +412,7 @@ rpcauth_lookup_credcache(struct rpc_auth *auth, struct auth_cred * acred,
|
|||
*entry, *new;
|
||||
unsigned int nr;
|
||||
|
||||
nr = hash_long(acred->uid, cache->hashbits);
|
||||
nr = hash_long(from_kuid(&init_user_ns, acred->uid), cache->hashbits);
|
||||
|
||||
rcu_read_lock();
|
||||
hlist_for_each_entry_rcu(entry, pos, &cache->hashtable[nr], cr_hash) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue