mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts: drivers/net/ixgbe/ixgbe_main.c include/net/mac80211.h net/phonet/af_phonet.c
This commit is contained in:
commit
6ab33d5171
120 changed files with 778 additions and 679 deletions
|
|
@ -133,13 +133,29 @@ static int
|
|||
generic_match(struct auth_cred *acred, struct rpc_cred *cred, int flags)
|
||||
{
|
||||
struct generic_cred *gcred = container_of(cred, struct generic_cred, gc_base);
|
||||
int i;
|
||||
|
||||
if (gcred->acred.uid != acred->uid ||
|
||||
gcred->acred.gid != acred->gid ||
|
||||
gcred->acred.group_info != acred->group_info ||
|
||||
gcred->acred.machine_cred != acred->machine_cred)
|
||||
return 0;
|
||||
goto out_nomatch;
|
||||
|
||||
/* Optimisation in the case where pointers are identical... */
|
||||
if (gcred->acred.group_info == acred->group_info)
|
||||
goto out_match;
|
||||
|
||||
/* Slow path... */
|
||||
if (gcred->acred.group_info->ngroups != acred->group_info->ngroups)
|
||||
goto out_nomatch;
|
||||
for (i = 0; i < gcred->acred.group_info->ngroups; i++) {
|
||||
if (GROUP_AT(gcred->acred.group_info, i) !=
|
||||
GROUP_AT(acred->group_info, i))
|
||||
goto out_nomatch;
|
||||
}
|
||||
out_match:
|
||||
return 1;
|
||||
out_nomatch:
|
||||
return 0;
|
||||
}
|
||||
|
||||
void __init rpc_init_generic_auth(void)
|
||||
|
|
|
|||
Loading…
Reference in a new issue