From owner-freebsd-hackers Tue Aug 27 6:52: 0 2002 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 E0F7537B400 for ; Tue, 27 Aug 2002 06:51:56 -0700 (PDT) Received: from insomnia.spc.org (insomnia.spc.org [195.224.94.183]) by mx1.FreeBSD.org (Postfix) with SMTP id 7367743E84 for ; Tue, 27 Aug 2002 06:51:55 -0700 (PDT) (envelope-from bms@insomnia.spc.org) Received: (qmail 32079 invoked by uid 1031); 27 Aug 2002 13:51:10 -0000 Date: Tue, 27 Aug 2002 14:51:10 +0100 From: Bruce M Simpson To: Ian Dowse Cc: n_hibma@FreeBSD.ORG, joe@FreeBSD.ORG, hackers@freebsd.org Subject: Re: USB->ATA devices Message-ID: <20020827135110.GB24795@spc.org> References: <20020827122010.GA5438@spc.org> <200208271420.aa79383@salmon.maths.tcd.ie> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200208271420.aa79383@salmon.maths.tcd.ie> User-Agent: Mutt/1.3.28i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi Ian, [Moved to -hackers because no longer directly relevant to -mobile.] Please let me know if I'm talking complete monkey dung here. On Tue, Aug 27, 2002 at 02:20:09PM +0100, Ian Dowse wrote: > If you're interested, I wrote a functional but incomplete driver > for a similar device, the Prolific Technology PL2307 bridge. I just This is good stuff. The Onspec expects a command packet containing the ATA register contents in the order they appear in i/o space. Plus an additional byte whose meaning I have yet to decipher. > implemented the conversion for a minimal set of ATA commands in the > driver itself; it would obviously be better to have the ATA layer > in a separate driver though. The code for that driver is at: How about doing ata(4) over usb? Support was added for PCMCIA to ata in the form of ata-card.c. This required macro-izing the bus_space_write*() calls amongst other things. Normally this takes place over an underlying isa/pci bus abstraction, maybe we could re-use this abstraction in ata-usb.c to avoid changing anything here? That way we avoid duplicating the ATA bit-banging code. Remember atapicam? I like the fact that it allows one to run cdrecord with an ATAPI CDRW drive; perhaps it could be re-used and extended to allow CAM to be used to interact with these pure ATA devices? Of course in this case, if we make the devices on the USB->ATA bridge look like ata-disk devices and what have you, who needs CAM? Discussion invited and welcomed... BMS To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message