From: Maxim S. Shatskih on
> But my device manager shows that i have IDE ATA/ATAPI controllers & no
> SCSI controllers it means no SCSI interface,so should i perform the
> transformation from USBSTOR URB'S to IDE command set queries.

The upper edge of any storage port in Windows, USBSTOR and ATAPI included, is SCSI.

USBSTOR translates SCSI commands (used internally by Windows) to URBs.

--
Maxim S. Shatskih
Windows DDK MVP
maxim(a)storagecraft.com
http://www.storagecraft.com

From: Maxim S. Shatskih on
> Since ATA packet interface uses SCSI Command set,so even if i have IDE
> ATA/ATAPI interface I need to perform USBSTOR's URB to SCSI command set
> conversion.

What is your task? how is IDE related to your task?

Is it an external enclosure for IDE device, connected to the host by USB? In this case, the enclosure has a USB Storage -> IDE bridge chip, and the host knows nothing on IDE there, it thinks this is just an USB storage device.

--
Maxim S. Shatskih
Windows DDK MVP
maxim(a)storagecraft.com
http://www.storagecraft.com

From: Tim Roberts on
PRANAV KANT GAUR <PRANAVKANTGAUR(a)discussions.microsoft.com> wrote:
>
>Since ATA packet interface uses SCSI Command set,so even if i have IDE
>ATA/ATAPI interface I need to perform USBSTOR's URB to SCSI command set
>conversion.
>Please correct me if i am still interpreting anything wrongly.

The fact that you have IDE disks on your computer (or not) is completely
irrelevant. The USB Mass Storage Class specification is freely available.
You can download it (and you absolutely NEED to read it, if you plan to
continue on this pointless adventure). The commands that are sent to a USB
Mass Storage Class device are a subset of the SCSI command set. It's just
that simple.
--
Tim Roberts, timr(a)probo.com
Providenza & Boekelheide, Inc.
From: Maxim S. Shatskih on
> continue on this pointless adventure). The commands that are sent to a USB
> Mass Storage Class device are a subset of the SCSI command set.

(not to Tim who knows all of this I think, but to OP and the whole forum)

Correct, and they are wrapped to special URBs moving via a special pipe.

For instance, if you have an ATA DVD drive in external USB enclosure - then the only agents who interpret the SCSI commands are a) the CD/DVD burning software, who is now usually a user-mode DLL or EXE and who forms these commands b) the drive itself.

The rest of the pipeline - CdRom.sys, storage port, USB stack and the USB-to-ATA bridge chip - do not interpret them, they only deliver them "down". These parts of the stack can only enforce the transfer size and buffer alignment requirement, but not the SCSI commands semantics.

USBSTOR is the one who does this CDB-to-URB wrapping, and also provides the generic storage port functionality (being a PnP bus driver, enumerating a LUN PDO for the storage device, assigning correct names/symlinks to it, implementing the mandatory IOCTLs).

About ATA in this picture. ATAPI (for CD/DVD drives) is just SCSI over IDE wires, so, nothing special. As about the usual ATA (hard disks) - then the USB-to-ATA bridge chip has the conversion logic for them, and thus supports only a very limited set of SCSI commands.

As about the ATA hard disk without USB - ATAPI stack is the place where conversion is done. It is also limited a lot, thus there is an ATA passthrough feature.

Too bad we have no standard-described SCSI command which should map directly to ATA vendor-specific commands. If there would be such a standard - then a) no pathetic ATA passthrough interface, powerful SCSI passthrough could be used instead and b) ability to execute vendor ATA commands on a disk in external USB/1394 enclosure.

--
Maxim S. Shatskih
Windows DDK MVP
maxim(a)storagecraft.com
http://www.storagecraft.com

From: PRANAV KANT GAUR on


"Maxim S. Shatskih" wrote:

> > Since ATA packet interface uses SCSI Command set,so even if i have IDE
> > ATA/ATAPI interface I need to perform USBSTOR's URB to SCSI command set
> > conversion.
>
> What is your task? how is IDE related to your task?
I have a Sandisk Cruzer Micro flash drive device & i want to replace the
USBSTOR.sys which acts as function driver for it by the driver written by my
own.

> Is it an external enclosure for IDE device, connected to the host by USB? In this case, the enclosure has a USB Storage -> IDE bridge chip, and the host knows nothing on IDE there, it thinks this is just an USB storage device.
>
> --
> Maxim S. Shatskih
> Windows DDK MVP
> maxim(a)storagecraft.com
> http://www.storagecraft.com
>
> .
>