From owner-freebsd-hackers@FreeBSD.ORG Mon May 24 06:51:34 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2554F16A4CE for ; Mon, 24 May 2004 06:51:34 -0700 (PDT) Received: from bloodwood.hunterlink.net.au (smtp-local.hunterlink.net.au [203.12.144.17]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8B40543D4C for ; Mon, 24 May 2004 06:51:32 -0700 (PDT) (envelope-from boris@brooknet.com.au) Received: from [61.8.41.1] (ppp2901.dyn.pacific.net.au [61.8.41.1]) i4ODkODk032315; Mon, 24 May 2004 23:46:32 +1000 From: Sam Lawrance To: Craig Boston In-Reply-To: <200405232014.02736.craig@tobuj.gank.org> References: <1085318525.10526.25.camel@dirk> <1085358339.10526.28.camel@dirk> <200405232014.02736.craig@tobuj.gank.org> Content-Type: text/plain Message-Id: <1085406660.960.9.camel@dirk> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.6 Date: Mon, 24 May 2004 23:51:01 +1000 Content-Transfer-Encoding: 7bit cc: freebsd-hackers@freebsd.org Subject: Re: USB ethernet CDC driver X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 24 May 2004 13:51:34 -0000 After having a bit more of a look through the archives and more searching it's apparent this driver has been written a number of times over independently by different people (and for different reasons). I will try to make a bit of a collation effort and sort out the good bits. Sam On Mon, 2004-05-24 at 11:14, Craig Boston wrote: > On Sunday 23 May 2004 7:25 pm, Sam Lawrance wrote: > > That would be great, I would love to take a look at it. > > I'll go ahead and copy the list in case anybody else is interested... > > You can grab the source at > http://www.gank.org/freebsd/cdce.tar.gz > > I'm planning to eventually make a FreeBSD projects page -- I have a few local > patches and such I'd like to share. If and when I ever get time to do that, > I'll move this in with it, but the above link should work until then. > > The list archives will have to suffice as documentation until then, here's a > few random comments about it: > > * It's set up as a standalone kernel module. If you have the kernel source on > your system it should be as simple as "cd cdce; make all && make install". > That will dump it in /boot/kernel/if_cdce.ko, which can be loaded by any of > the normal means. > > * When you plug in the device, if all goes well, you should end up with a > cdce0 network device. Just ifconfig it and go. > > * It registers itself as the handler for the CDC Ethernet class. If your > device doesn't report itself as that, you may have to add a specific device > ID for it in the cdce_devs[] structure (get the values from usbdevs -v). If > it complains about not being able to find endpoints, try adding it in there > with the CDCE_NO_UNION flag. Linux on the Zaurus seems to be slightly > non-conformant to the spec, so it may be similar on the iPaq. > > * The driver generates a random MAC address for the local end rather than > trying to read it from the device. While incorrect for real Ethernet > adapters, it seems to be fine (and may even be necessary) for these kinds of > point-to-point connections. > > * There is special handling for the Zaurus's nonstandard frame format, but it > should be off by default for other devices. This hasn't been tested yet, > though :) > > * The driver is targeted at -CURRENT. It was originally developed against > 5.2-RELEASE sources and should still compile fine on those systems. It would > probably require some work to back-port to stable though. > > * Not entirely sure what to do about the copyright message -- I borrowed > heavily from the if_axe and if_aue drivers... > > * BSD license, so feel free to do whatever with it :) > > * Also applies is my standard disclaimer: It works fine on my system, but may > cause your toaster to explode. I used to sometimes get panics on detach, but > I think the problem is fixed now. Haven't had one in quite a while, even if > I unplug it while transferring something. > > Good luck! > > Craig > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" >