From owner-freebsd-audit Sun Feb 4 9: 7:18 2001 Delivered-To: freebsd-audit@freebsd.org Received: from lennier.cc.vt.edu (lennier.cc.vt.edu [198.82.161.193]) by hub.freebsd.org (Postfix) with ESMTP id 57A9437B401; Sun, 4 Feb 2001 09:07:00 -0800 (PST) Received: from mail.vt.edu (gkar.cc.vt.edu [198.82.161.190]) by lennier.cc.vt.edu (8.11.0/8.11.0) with ESMTP id f14H6wu86157; Sun, 4 Feb 2001 12:06:58 -0500 (EST) Received: from enterprise.muriel.penguinpowered.com ([198.82.100.151]) by gkar.cc.vt.edu (Sun Internet Mail Server sims.3.5.2000.03.23.18.03.p10) with ESMTP id <0G8800L1GSVLGB@gkar.cc.vt.edu>; Sun, 4 Feb 2001 12:06:57 -0500 (EST) Date: Sun, 04 Feb 2001 12:06:57 -0500 (EST) From: Mike Heffner Subject: RE: if_multiaddrs.patch In-reply-to: <19497.981304817@critter> To: Poul-Henning Kamp Cc: audit@freebsd.org Message-id: MIME-version: 1.0 X-Mailer: XFMail 1.4.6-3 on FreeBSD Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 8bit X-Priority: 3 (Normal) Sender: owner-freebsd-audit@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Looks good to me. One thing I noticed was that in sys/pci/if_xl.c, functions xl_setmulti() and xl_setmulti_hash(), the variable mcnt isn't needed and TAILQ_EMPTY() could be used instead. In the following case, it would remove one loop. Index: pci/if_xl.c =================================================================== RCS file: /home/ncvs/src/sys/pci/if_xl.c,v retrieving revision 1.90 diff -u -r1.90 if_xl.c --- pci/if_xl.c 2001/02/03 16:29:10 1.90 +++ pci/if_xl.c 2001/02/04 16:11:58 @@ -808,7 +808,7 @@ return; } - LIST_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) + TAILQ_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) mcnt++; if (mcnt) On 04-Feb-2001 Poul-Henning Kamp wrote: | | http://phk.freebsd.dk/patch | | 2001-02-04 if_multiaddrs.patch | | Convert if_multiaddrs from LIST to TAILQ so that it can | be traversed backwards also. | | To be committed 2001-02-08 | -- Mike Heffner Blacksburg, VA ICQ# 882073 http://filebox.vt.edu/users/mheffner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-audit" in the body of the message