Date: Tue, 19 May 1998 17:21:27 +0200 From: Eivind Eklund <eivind@yes.no> To: Luigi Rizzo <luigi@labinfo.iet.unipi.it>, Kenjiro Cho <kjc@csl.sony.co.jp> Cc: current@FreeBSD.ORG Subject: Re: struct ifnet handling... Message-ID: <19980519172127.08361@follo.net> In-Reply-To: <199805191149.NAA09232@labinfo.iet.unipi.it>; from Luigi Rizzo on Tue, May 19, 1998 at 01:49:16PM %2B0200 References: <199805191038.TAA25933@hotaka.csl.sony.co.jp> <199805191149.NAA09232@labinfo.iet.unipi.it>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, May 19, 1998 at 01:49:16PM +0200, Luigi Rizzo wrote: > > >> When this is done, matching interface names requires only a pointer > > >> comparison (and furthermore, a NULL pointer can be used as an > > >> indication that no interface match is required). > > > > Use if_index instead of a pointer to the interface name. if_index is > > a unique interface number start from 1. Many routing related programs > > I also thought of the pointer to struct ifnet as a unique identifier, > except that the current ipfw syntax allows wildcards to selects all > interfaces of the same kind (e.g. all "tun", all "ed", etc.) > > I don't think this makes much sense, but maybe someone depends on it. > > In any case it is clear that if we want a fast firewall code, > rules must be simplified. We now have CISC rules, should go for RISC > ones :) If you're interested in implementing fast firewall code, there are a lot of changes that are more interesting than removing that strncmp(). One of them is getting rid of the dual pass through the firewall rules - which you can do by switching to a chained system. Eivind. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19980519172127.08361>