From owner-freebsd-net@FreeBSD.ORG Sun Mar 25 01:19:15 2007 Return-Path: X-Original-To: freebsd-net@freebsd.org Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 16AC016A400 for ; Sun, 25 Mar 2007 01:19:15 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (grnl-static-02-0046.dsl.iowatelecom.net [69.66.56.110]) by mx1.freebsd.org (Postfix) with ESMTP id A2AD413C487 for ; Sun, 25 Mar 2007 01:19:14 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (localhost [127.0.0.1]) by lor.one-eyed-alien.net (8.13.8/8.13.8) with ESMTP id l2P1JAZx007959; Sat, 24 Mar 2007 20:19:10 -0500 (CDT) (envelope-from brooks@lor.one-eyed-alien.net) Received: (from brooks@localhost) by lor.one-eyed-alien.net (8.13.8/8.13.8/Submit) id l2P1J8M2007958; Sat, 24 Mar 2007 20:19:08 -0500 (CDT) (envelope-from brooks) Date: Sat, 24 Mar 2007 20:19:08 -0500 From: Brooks Davis To: Hartmut Brandt Message-ID: <20070325011908.GC7607@lor.one-eyed-alien.net> References: <200703231844.l2NIiCsa089542@freefall.freebsd.org> <20070324102948.Q58113@knop-beagle.kn.op.dlr.de> <4604FDD4.2080805@freebsd.org> <20070324123754.GA80483@svzserv.kemerovo.su> <20070324182901.I59406@knop-beagle.kn.op.dlr.de> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="KDt/GgjP6HVcx58l" Content-Disposition: inline In-Reply-To: <20070324182901.I59406@knop-beagle.kn.op.dlr.de> User-Agent: Mutt/1.5.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (lor.one-eyed-alien.net [127.0.0.1]); Sat, 24 Mar 2007 20:19:10 -0500 (CDT) Cc: freebsd-net@freebsd.org, freebsd-bugs@freebsd.org, Andre Oppermann , Eugene Grosbein Subject: Re: kern/110720: [net] [patch] support for interface descriptions X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 25 Mar 2007 01:19:15 -0000 --KDt/GgjP6HVcx58l Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Mar 24, 2007 at 06:37:59PM +0100, Hartmut Brandt wrote: > On Sat, 24 Mar 2007, Eugene Grosbein wrote: >=20 > EG>On Sat, Mar 24, 2007 at 11:30:44AM +0100, Andre Oppermann wrote: > EG> > EG>> Harti Brandt wrote: > EG>> >Nice feature, although it would be nice to align the maximum length= with=20 > EG>> >IF-MIB::ifDescr (255 byte + \0). Also I suppose that the field more= =20 > EG>> >naturally fits into struct if_data (see net/if.h) given the comment= for=20 > EG>> >that struct: > EG>> > > EG>> >/* > EG>> > * Structure describing information about an interface > EG>> > * which may be of interest to management entities. > EG>> > */ > EG>>=20 > EG>> The string array should most likely not be part of struct ifnet as t= hat > EG>> would bloat it quite a bit. If it is in there it should be at the e= nd > EG>> of the struct to avoid cache line busting effects. > EG> > EG>Also vote for this. And is it possible to make it a pointer instead > EG>of array? The bloat would be minimal for system with tons of interface= s, > EG>think about large pptp or pppoe server or similar that never would > EG>utilize arrays. >=20 > That makes sense. If it is a pointer it should not live in struct ifdata= =20 > which can be retrieved via sysctl(). >=20 > As for access to this field perhaps it makes more sense to use the sysctl > net.link.generic.ifdata subtree. We have already IFDATA_DRIVERNAME there= =20 > which returns a string. Could be IFDATA_DESCRIPTION (4). This would=20 > probably be more in line with the management nature of the data. Just a= =20 > thought... Would be slightly easier for the SNMP daemon to use... If must not live in struct ifdata as the size of struct ifdata is part of the routing socket API. :( There are two bytes avaible in struct ifdata. -- Brooks --KDt/GgjP6HVcx58l Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (FreeBSD) iD8DBQFGBc4MXY6L6fI4GtQRAjp0AKDL6bYit59V+7Fptg8/TtcijgyGHQCfSKqi BnyLnBae+A2iduGFcBlwMvQ= =E/BL -----END PGP SIGNATURE----- --KDt/GgjP6HVcx58l--