On Mon, 4 Feb 2013 14:22:47 +0000 "Myklebust, Trond" <Trond.Myklebust@xxxxxxxxxx> wrote: > > -----Original Message----- > > From: linux-nfs-owner@xxxxxxxxxxxxxxx [mailto:linux-nfs- > > owner@xxxxxxxxxxxxxxx] On Behalf Of Jeff Layton > > Sent: Monday, February 04, 2013 8:10 AM > > To: bfields@xxxxxxxxxxxx > > Cc: linux-nfs@xxxxxxxxxxxxxxx; chuck.lever@xxxxxxxxxx > > Subject: [PATCH] sunrpc: copy scope ID in __rpc_copy_addr6 > > > > When copying an address, we should also copy the scopeid in the event that > > this is a link-local address and the scope matters. > > > > Signed-off-by: Jeff Layton <jlayton@xxxxxxxxxx> > > --- > > include/linux/sunrpc/clnt.h | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/include/linux/sunrpc/clnt.h b/include/linux/sunrpc/clnt.h index > > 47354a2..6a7c261 100644 > > --- a/include/linux/sunrpc/clnt.h > > +++ b/include/linux/sunrpc/clnt.h > > @@ -242,6 +242,7 @@ static inline bool __rpc_copy_addr6(struct sockaddr > > *dst, > > > > dsin6->sin6_family = ssin6->sin6_family; > > dsin6->sin6_addr = ssin6->sin6_addr; > > + dsin6->sin6_scope_id = ssin6->sin6_scope_id; > > return true; > > } > > #else /* !(IS_ENABLED(CONFIG_IPV6) */ > > -- > > > Can we please move these helpers into a separate header, say include/Linux/sunrpc/inet.h? > Yes, that's long overdue. I'll spin up a patch on top of this one to do that. I'd suggest that we call it "addr.h" to keep it in parity with the "addr.c" file that's in the sunrpc directory, since we'll need to move the prototypes for those functions as well. > Oh... Also note that you probably want to apply the above scopeid to the NFSv4 callback address that is supplied by the client in the setclientid call. > I'm not clear on what you mean here. This patch should make it so that the server keeps the correct scopeid along with the cb address that it tracks for a client (something that I don't think it does properly today). -- Jeff Layton <jlayton@xxxxxxxxxx> -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html