Date: Tue, 27 Aug 2002 20:29:00 +0200 (CEST) From: Nick Hibma <n_hibma@van-laarhoven.org> To: Soeren Schmidt <sos@freebsd.dk> Cc: Ian Dowse <iedowse@maths.tcd.ie>, Bruce M Simpson <bms@spc.org>, "joe@FreeBSD.ORG" <joe@FreeBSD.ORG>, "hackers@FreeBSD.ORG" <hackers@FreeBSD.ORG> Subject: Re: USB->ATA devices Message-ID: <20000101203734.M3514-100000@heather.van-laarhoven.org> In-Reply-To: <200208271536.g7RFapYX004079@freebsd.dk>
next in thread | previous in thread | raw e-mail | index | archive | help
> > This would be hard to do right, as the preferred way to talk to USB > > devices is with a request-callback model. The ATA command would > > need to be put into a request structure and handed to the USB device > > driver, and the USB driver would then call back when the request > > completes. There are hacks that can be used to perform the USB > > operations synchronously, but they generally do not handle unexpected > > removal of the device well at all. > > > > There are many possible ATA/ATAPI over USB protocols, so turning > > the ATA request into one or more USB transfers is a bridge-specific > > operation. Basically these odd protocols exist because the manufacturers > > of the various bridges have decided to cut corners and not implement > > the standard USB mass storage interface. > > Sounds like a can of worms better left unopened... Translating the commands in the umass driver is the best you can do I'm afraid. Until the moment of course where you run the ATA driver on a thread that doesn't mind being suspended for 1 or 2 ms during a 'register write' operation. That approach has been considered and hacked into shape for the MIIBUS enabled USB ethernet dongles. Just check out the threads telling you that they won't work and you'll see that it ain't an easy problem to solve. Nick -- n_hibma@van-laarhoven.org http://www.van-laarhoven.org/ n_hibma@FreeBSD.org http://www.etla.net/~n_hibma/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000101203734.M3514-100000>