NFS: Change nfs_find_client() to take "struct sockaddr *"
Adjust arguments and callers of nfs_find_client() to pass a "struct sockaddr *" instead of "struct sockaddr_in *" to support non-IPv4 addresses. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Cc: Aurelien Charbon <aurelien.charbon@ext.bull.net> Trond: Also fix up protocol version number argument in nfs_find_client() to use the correct u32 type. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:

committed by
Trond Myklebust

parent
c1d3586656
commit
ff052645c9
@@ -164,12 +164,11 @@ void nfs_callback_down(void)
|
||||
|
||||
static int nfs_callback_authenticate(struct svc_rqst *rqstp)
|
||||
{
|
||||
struct sockaddr_in *addr = svc_addr_in(rqstp);
|
||||
struct nfs_client *clp;
|
||||
char buf[RPC_MAX_ADDRBUFLEN];
|
||||
|
||||
/* Don't talk to strangers */
|
||||
clp = nfs_find_client(addr, 4);
|
||||
clp = nfs_find_client(svc_addr(rqstp), 4);
|
||||
if (clp == NULL)
|
||||
return SVC_DROP;
|
||||
|
||||
|
Reference in New Issue
Block a user