nfsd4: move principal name into svc_cred

Instead of keeping the principal name associated with a request in a
structure that's private to auth_gss and using an accessor function,
move it to svc_cred.

Signed-off-by: J. Bruce Fields <bfields@redhat.com>
This commit is contained in:
J. Bruce Fields
2012-05-14 19:55:22 -04:00
parent 631fc9ea05
commit 03a4e1f6dd
8 changed files with 38 additions and 41 deletions

View File

@@ -15,13 +15,22 @@
#include <linux/sunrpc/msg_prot.h>
#include <linux/sunrpc/cache.h>
#include <linux/hash.h>
#include <linux/cred.h>
struct svc_cred {
uid_t cr_uid;
gid_t cr_gid;
struct group_info *cr_group_info;
char *cr_principal; /* for gss */
};
static inline void free_svc_cred(struct svc_cred *cred)
{
if (cred->cr_group_info)
put_group_info(cred->cr_group_info);
kfree(cred->cr_principal);
}
struct svc_rqst; /* forward decl */
struct in6_addr;