Date: Mon, 25 Jun 2001 01:31:06 +0900 (JST) From: Hajimu UMEMOTO <ume@mahoroba.org> To: brooks@one-eyed-alien.net Cc: hackers@FreeBSD.ORG, brian@Awfulhak.org, phk@critter.freebsd.dk, arch@FreeBSD.ORG Subject: Re: cloning network interfaces Message-ID: <20010625.013106.78752396.ume@mahoroba.org> In-Reply-To: <20010622125113.A30459@Odin.AC.HMC.Edu> References: <20010611142030.A15283@Odin.AC.HMC.Edu> <20010613.040716.115941864.ume@mahoroba.org> <20010622125113.A30459@Odin.AC.HMC.Edu>
next in thread | previous in thread | raw e-mail | index | archive | help
>>>>> On Fri, 22 Jun 2001 12:51:13 -0700 >>>>> Brooks Davis <brooks@one-eyed-alien.net> said: brooks> Ok, after a week and a half of doing other things, I've got a patch brooks> together which adds interface cloning based on NetBSD's code. The brooks> difference is that you may pass an interface of the from gif# if you brooks> don't need a specific number. The ioctl now returns a potentialy brooks> modified ifreq which contains the new interface name. This changes the brooks> way drivers implement cloning in that they may return a different unit brooks> then they were passed and they must do their own resource management brooks> rather then relying on the clone functionality in sys/net/if.c to do it brooks> for them. brooks> The patch is at: brooks> http://people.freebsd.org/~brooks/patches/gif.diff brooks> The patch can be applied as follows (you need to make the directories): brooks> cd /usr/src brooks> mkdir sys/modules/if_gif sys/modules/if_stf brooks> patch < /tmp/gif.diff brooks> The patch does the following: brooks> - adds interface cloning support to the kernel brooks> - adds interface cloning support to ifconfig brooks> - makes gif clonable brooks> - makes gif usable as a module brooks> - removes the need for NGIF and gif.h brooks> - removes va_args usage in in_gif_input to remove a warning brooks> - removes gif dependencies from stf brooks> - makes stf usable as a module It seems fine to me. I just tried it on my box. You forget to include prototype change of in_gif_input() in sys/net/if_gif.h. BTW, why did you change gif_ioctl() to gif_ifioctl()? gif related modules are shared among *BSDs and maintained in KAME CVS repository. Could you please keep local changes small as possible? -- Hajimu UMEMOTO @ Internet Mutual Aid Society Yokohama, Japan ume@mahoroba.org ume@bisd.hitachi.co.jp ume@{,jp.}FreeBSD.org http://www.imasy.org/~ume/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010625.013106.78752396.ume>