Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 25 Aug 2006 06:46:27 -0700
From:      Luigi Rizzo <rizzo@icir.org>
To:        Ian FREISLICH <if@hetzner.co.za>
Cc:        freebsd-ipfw@freebsd.org
Subject:   Re: ipfw performance and random musings.
Message-ID:  <20060825064627.D6023@xorpc.icir.org>
In-Reply-To: <E1GGbiP-000DFG-1B@hetzner.co.za>; from if@hetzner.co.za on Fri, Aug 25, 2006 at 03:27:17PM %2B0200
References:  <rizzo@icir.org> <E1GGbiP-000DFG-1B@hetzner.co.za>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Aug 25, 2006 at 03:27:17PM +0200, Ian FREISLICH wrote:
> Luigi Rizzo wrote:
> > i am basically ok with this except, as i said, that there is
> > no point in replicating the interface name i.e. why re0-re5
> > instead of just re0-5 ? you just open up to possible mistakes
> > and the need for extra code to check what happens when the user
> > types re2-de5 (by mistake or intentionally).
> 
> Ok, it's just syntactic sugar anyway which doesn't really affect
> implimentation anyway.
> 
> So, to recap.  You will be fine with although I'm now leaning toward
> "factor" in stead of "delta" but that will be a trivial change and
> I'd like to change "@" to "indirect".
> 
> skipto @ via vlan2-264 base 100 delta 100
> 
> or as I'd prefer
> 
> skipto indirect via vlan2-264 base 100 factor 100

either way is fine with me.

> Only thing is that this slightly complicates displaying the rules
> since the indirection is stored in the ipfw_insn_if structure so
> at this time it's not known whether this is an indirection or not.

actually not, what i had in mind is exactly what you mention below - to
record the type of jump (direct/indirect) in the skipto instruction
(going one step further, one could think of several "indirect" registers
to be used as jump target, possibly filled by previous instructions
(e.g. from the content of an ipfw "table", etc.)

You still implement these as local variables in the ip_fw_check()
function.

cheers
luigi



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060825064627.D6023>