[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: RFC: Fixing USB ethernet for FreeBSD 7.0.
- To: freebsd-usb_(_at_)_freebsd_(_dot_)_org
- Subject: Re: RFC: Fixing USB ethernet for FreeBSD 7.0.
- From: Hans Petter Selasky <hselasky_(_at_)_c2i_(_dot_)_net>
- Date: Fri, 1 Dec 2006 23:32:10 +0100
- Cc: Alfred Perlstein <alfred_(_at_)_freebsd_(_dot_)_org>, freebsd-smp_(_at_)_freebsd_(_dot_)_org
On Friday 01 December 2006 20:43, Alfred Perlstein wrote:
> * M. Warner Losh <imp_(_at_)_bsdimp_(_dot_)_com> [061201 11:30] wrote:
> > Have you looked at the usb work that Hans Petter Selasky
> > at http://www.turbocat.net/~hselasky/usb4bsd yet?
>
> I just did, while it solves a lock order problem, this doesn't
> appear to solve the programmitic issues, namely multiple usb IOs
> requiring callbacks and how to issue a series of complex usb
> IOs from interrupt context.
>
> Basically, I need to be able to do USB IO as if I was doing normal
> BUS IO, usb does not offer this in interrupt context except as a
> series of callbacks that appear to be programmatically impossible
> to implement.
Yes, yes, this is supported. See the USBD_USE_POLLING flag.
>
> Have a look at if_aue.c, then look at any of the error cases that
> might be called from interrupt context, they wind up doing sync IO
> to the device which is illegal (sleeping while holding a driver
> lock).
>
> Hans Petter Selasky's work is nice, however it doesn't solve
> these issues, the lock would still have to be held.
You don't want to do things without holding a lock.
> Do you understand that I'm trying to give usb ethernet the
> same ease of programming that other devices on a "fast bus"
> have?
Yes, but that comes at an expense. Higher CPU usage, more delay.
--HPS
_______________________________________________
freebsd-usb_(_at_)_freebsd_(_dot_)_org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscribe_(_at_)_freebsd_(_dot_)_org"
Visit your host, monkey.org