Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-31 Thread Julian Elischer
Yar Tikhiy wrote: However, I have one question regarding "etype", please see below. [...] + /* +* if we have an ether header, +*/ + if (args->eh) + etype = (ntohs(args->eh->ether_type)) == ETHERTYPE_VLAN; And here we assign a boolean value to etype.

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-30 Thread Julian Elischer
Yar Tikhiy wrote: However, I have one question regarding "etype", please see below. Index: netinet/ip_fw2.c + /* +* if we have an ether header, +*/ + if (args->eh) + etype = (ntohs(args->eh->ether_type)) == ETHERTYPE_VLAN; And here we assign a bo

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-30 Thread Yar Tikhiy
On Fri, Dec 29, 2006 at 10:59:53AM -0800, Julian Elischer wrote: > Yar Tikhiy wrote: > >On Tue, Dec 26, 2006 at 11:27:44AM -0800, Julian Elischer wrote: > >>Yar Tikhiy wrote: > >> > If what you are suggesting is that we pass into ipfw an 'offset' > into the packet as well as the packet, the

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-30 Thread Yar Tikhiy
On Tue, Dec 26, 2006 at 02:31:47PM -0800, Julian Elischer wrote: > Ok, so, here is a patch for general review by ipfw types. > This is the first of two related changes. > > It is MOSTLY a cleanup of ip_fw2.c, removing a bunch of mtod() > operations and replacing them with a cached value of the add

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-29 Thread Julian Elischer
Yar Tikhiy wrote: On Tue, Dec 26, 2006 at 11:27:44AM -0800, Julian Elischer wrote: Yar Tikhiy wrote: If what you are suggesting is that we pass into ipfw an 'offset' into the packet as well as the packet, then yes I like that idea, but I didn't see Andre suggest it. Do you consider only ideas

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-29 Thread Yar Tikhiy
On Tue, Dec 26, 2006 at 11:27:44AM -0800, Julian Elischer wrote: > Yar Tikhiy wrote: > > >> > >>If what you are suggesting is that we pass into ipfw an 'offset' > >>into the packet as well as the packet, then yes I like that idea, > >>but I didn't see Andre suggest it. > > > >Do you consider only

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-26 Thread Julian Elischer
Ok, so, here is a patch for general review by ipfw types. This is the first of two related changes. It is MOSTLY a cleanup of ip_fw2.c, removing a bunch of mtod() operations and replacing them with a cached value of the address of the IP header. It also has a couple of (commented out) referenc

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-26 Thread Julian Elischer
Yar Tikhiy wrote: If what you are suggesting is that we pass into ipfw an 'offset' into the packet as well as the packet, then yes I like that idea, but I didn't see Andre suggest it. Do you consider only ideas by Andre? ;-) By Andre's opinion I meant this: Please have the ipfw code

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-25 Thread Yar Tikhiy
On Mon, Dec 25, 2006 at 12:22:02PM -0800, Julian Elischer wrote: > Yar Tikhiy wrote: > >On Fri, Dec 22, 2006 at 12:39:06PM -0800, Julian Elischer wrote: > >>Taking to heart comments by Andre and Max (Laier), > >>I have redone this patch in a different manner. > >> > >>The aim is to be able to see i

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-25 Thread Julian Elischer
Max Laier wrote: I'm not sure if you are mistaking Yar for me here. As for my concerns - consider them withdrawn. I still don't like the idea that the code in net*inet*/ip_fw2.c gets to know about VLAN internals, but if everybody feels that it does belong there - fine. I hereby resign fr

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-25 Thread Yar Tikhiy
On Mon, Dec 25, 2006 at 10:39:51PM +0100, Max Laier wrote: > On Monday 25 December 2006 21:22, Julian Elischer wrote: > > Yar Tikhiy wrote: > > > On Fri, Dec 22, 2006 at 12:39:06PM -0800, Julian Elischer wrote: > > >> Taking to heart comments by Andre and Max (Laier), > > >> I have redone this patc

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-25 Thread Max Laier
On Monday 25 December 2006 21:22, Julian Elischer wrote: > Yar Tikhiy wrote: > > On Fri, Dec 22, 2006 at 12:39:06PM -0800, Julian Elischer wrote: > >> Taking to heart comments by Andre and Max (Laier), > >> I have redone this patch in a different manner. > >> > >> The aim is to be able to see insid

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-25 Thread Julian Elischer
Yar Tikhiy wrote: On Fri, Dec 22, 2006 at 12:39:06PM -0800, Julian Elischer wrote: Taking to heart comments by Andre and Max (Laier), I have redone this patch in a different manner. The aim is to be able to see inside vlans when bridging. Now, this is a 6.x patch to bridge.c because that is wha

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-24 Thread Yar Tikhiy
On Fri, Dec 22, 2006 at 12:39:06PM -0800, Julian Elischer wrote: > > Taking to heart comments by Andre and Max (Laier), > I have redone this patch in a different manner. > > The aim is to be able to see inside vlans when bridging. > Now, this is a 6.x patch to bridge.c because that is what we > a

Re: [was] addition to ipfw (read vlans from bridge)..

2006-12-22 Thread Julian Elischer
Taking to heart comments by Andre and Max (Laier), I have redone this patch in a different manner. The aim is to be able to see inside vlans when bridging. Now, this is a 6.x patch to bridge.c because that is what we are using, but I will make a similar patch to if_bridge.c for 6 and 7 if this m