Date: Sat, 12 Oct 2002 20:07:47 -0600 (MDT) From: "M. Warner Losh" <imp@bsdimp.com> To: rizzo@icir.org Cc: net@FreeBSD.ORG Subject: Re: Comments Please Message-ID: <20021012.200747.59843102.imp@bsdimp.com> In-Reply-To: <20021012171339.A92744@carp.icir.org> References: <20021012.171809.93306957.imp@bsdimp.com> <20021012171339.A92744@carp.icir.org>
next in thread | previous in thread | raw e-mail | index | archive | help
In message: <20021012171339.A92744@carp.icir.org> Luigi Rizzo <rizzo@icir.org> writes: : On Sat, Oct 12, 2002 at 05:18:09PM -0600, M. Warner Losh wrote: : > OK. I'm not a network wonk, so I thought I'd run this by people : > here. What do people think. : : sounds ok -- removing explicit constants is always good. : On passing: : : * While you are at it, : grep etherbroadcastaddr sys/net*/* : reveals the use of an explicit constant (6) in net/if_arp.h and : netinet/if_ether.c; there is more of the same in net/bridge.c : (my fault), net/if_atmsubr.c, netinet/if_ether.c, netncp/ncp_subr.c atmsubr? Doesn't ATM have its own constants? : * there is no real reason to have etherbroadcastaddr as a : variable. net/bridge.c has a macro, IS_ETHER_BROADCAST, : which is much faster to evaluate on i386, and : could be moved e.g. in net/ethernet.h and be used : to check for ethernet broadcast addresses in : net/if_ethersubr.c : net/if_iso88025subr.c : netatalk/aarp.c : net/if_fddisubr.c : This only leaves some usages of etherbroadcastaddr is in : netinet/if_ether.c to set the address for outgoing broadcast : packets. I'll let others deal with that. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021012.200747.59843102.imp>