NFSD: Support AF_INET6 in svc_addsock() function
Relax the address family check at the top of svc_addsock() to allow AF_INET6 listener sockets to be specified via /proc/fs/nfsd/portlist. Signed-off-by: Aime Le Rouzic <aime.le-rouzic@bull.net> Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
This commit is contained in:
parent
07396051a5
commit
205ba42308
@ -1357,7 +1357,7 @@ int svc_addsock(struct svc_serv *serv, const int fd, char *name_return,
|
||||
|
||||
if (!so)
|
||||
return err;
|
||||
if (so->sk->sk_family != AF_INET)
|
||||
if ((so->sk->sk_family != PF_INET) && (so->sk->sk_family != PF_INET6))
|
||||
err = -EAFNOSUPPORT;
|
||||
else if (so->sk->sk_protocol != IPPROTO_TCP &&
|
||||
so->sk->sk_protocol != IPPROTO_UDP)
|
||||
|
Loading…
Reference in New Issue
Block a user