J. Bruce Fields: > On Mon, Aug 22, 2011 at 03:32:13PM -0400, Chuck Lever wrote: >> On Aug 22, 2011, at 3:26 PM, J. Bruce Fields wrote: >> >>> On Sat, Aug 20, 2011 at 06:24:29PM +0800, Mi Jinlong wrote: >>>> +/* >>>> + * Add scope id for LINKLOCAL address >>>> + */ >>>> +struct in6_addr_scopeid{ >>>> + struct in6_addr sin6_addr; >>>> + __u32 sin6_scope_id; >>>> +}; >>>> + >>>> union svc_addr_u { >>>> - struct in_addr addr; >>>> - struct in6_addr addr6; >>>> + struct in_addr addr; >>>> + struct in6_addr_scopeid addr6; >>> By the way, is there any reason why nfsd really needs its own address >>> structure? Shouldn't we use sockaddr_storage or something? I feel like >>> we've got a little too much one-off address handling in nfsd. >> That would be my only complaint about the patch. >> >> I think we chose a smaller struct here to save space, and we could do that because we didn't need a port number or scope ID. If a scope ID is indeed required, then we should consider something larger like a struct sockaddr_storage, IMO. > > If we care about the size of struct svc_rqst: rq_vec and rq_pages fields > are 4k and 2k, respectively, and the rest is lost in the noise. > > Mi Jinlong, would you have the time to try this? OK, I will do this. Thanks for all comment. -- ---- thanks Mi Jinlong > > - Replace svc_addr_u by sockaddr_storage > - See of that allows us to delete some lines of code in nfsd by > using standard helper functions instead of copying things by > hand. > > You'd do that in one patch, then apply your scope-id fix on top of it as > a second patch. > > --b. > -- > 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 > > -- 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