Re: [PATCH] libata transport attributes

From: Justin Cormack
Date: Fri Apr 02 2004 - 09:45:40 EST


On Thu, 2004-04-01 at 19:10, Jeff Garzik wrote:
> Justin Cormack wrote:
> > On Wed, 2004-03-31 at 22:07, Jeff Garzik wrote:
> >
> >
> >>Did you see the comments I posted WRT mort's patch?
> >>
> >
> >
> > oops, no I missed his patch and your comments until now.
> >
> >
> >>Since libata is leaving SCSI in 2.7, I would rather not add superfluous
> >>stuff like this at all.
> >>
> >
> >
> > I didnt know this.
> >
> >
> >>Further, you can already retrieve the information you export with _zero_
> >>new code.
> >
> >
> > How? Sorry to be dumb...
>
> Obtain the SCSI inquiry info from userspace...

I looked at doing this, but unfortunately this doesnt work due to
incompatibilities between the SCSI and ATA way of doing things. The ATA
product ids are truncated from 20 chars to 16 (there is no separate
vendor ID so both are effectively combined into one field with arbitrary
layout). The product revision level is only 4 bytes in scsi, unlike the
8 byte firmware revision in ATA. You can get the serial number though.

Currently you use ATA as vendor id, I will quite happily patch libata to
stick the whole ATA identify into some EVPD scsi inquiry pages as vendor
specific info and write a userspace tool to parse it if you would
rather. Thats much easier to junk when you move out of scsi-world and
presumably start to export native sysfs info.

Justin


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/