Subject: Re: ipsec pcb/socket passing
To: Jun-ichiro itojun Hagino <itojun@itojun.org>
From: Bill Studenmund <wrstuden@netbsd.org>
List: tech-net
Date: 08/26/2003 09:50:44
On Tue, 26 Aug 2003, Jun-ichiro itojun Hagino wrote:

> > What parts along the so->so_proto->pr_domain->dom_family chain will change
> > during a socket's lifetime? I think the best thing to do is comment "If
> > you change this, you need to change the in{,6}pcb."
>
> 	ok, i understand.  if there's no problem in breaking kmem grovellers
> 	i can introduce "int inp_af" field to inpcb (location aligned with
> 	in6pcb) and use it to distinguish the two.  i also can make inpcbtable
> 	unified (instead of inpcbtable/in6pcbtable) but i'm not sure how
> 	good hash distribution will be.

The one thing I'd say (which is an echo of your policy :-) is let's see if
we can make one change, get the change right the first time. I like the
idea of a common structure that they share.

It might be that inpcbtable and in6pcbtable shoudl stay separate. Maybe
use the same fields in the common struct, but if they need different
hashing, they probably need different tables.

Take care,

Bill