Jeff Garzik wrote:
Mark Lord wrote:
Jeff Garzik wrote:
..
The miscdev (i.e. chrdev) interface found in
drivers/scsi/scsi_tgt_if.c of repo [1] seems pretty generic, simple,
small and applicable to portions of the problem presented here...
The basic task in scsi_tgt_if's case is just shoveling packets
to/from userspace.
..
Except it's rather SCSI specific, and the userspace frontend even more so.
The code expects a SCSI command block, LUN, TAG, and other fields that
a SATA FIS won't have. Seems clumsy, particularly when we (in theory)
are trying to decouple libata from SCSI. But if that's the way,
then I can clumsily wrap each FIS in a fake ATA_16 header or something.
The kernel bits are not terribly SCSI-specific. I'd ignore the userland
bits.
We just have to get the interface right. Even if we "cp scsi_tgt_if.c
ata_tgt_if.c" and then go from there, we should make an effort to create
similar packet push/pull interfaces.
..
Yeah, that does look like a good starting point.
To begin with, I'll see if I can just wrap the SATA FIS+data
into something that scsi_tgt_if.c will pass through unmolested.
This will give us a way to play with it in the 2.6.30 time frame,
and we can fork it or tweak it as needed for later releases then.
Creating something wildly different would be counterproductive.
..
Yes we definitely should re-use that stuff if possible.
I think it all feeds to/from netlink, too, though it's been
a month since I last tried to find my way through it all.
Patches in a week or so.
Cheers
--
To unsubscribe from this list: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html