how to detect whether the device is on an IDE bus

Hi,

I want to check whether my device is on an IDE bus.
Also I have scsi devices attached;
When I issue DeviceIoControl with ioctl_scsi_get_address
as the parameter, even the IDE device behaves as a scsi
device with scsiport 0, targetid 0, LUN 0
I think all IDE devices do behave this way according to
the atapi standard.

IOCTL_DISK_CONTROLLER_NUMBER for this device fails.

system: WinNT sp6 The IDE device is a Quantum disk.

Is there any other way to check whether the device is on
an IDE bus? (I don’t want to query the registry for the
driver for this device)

thanks
Harish


Get free email and a permanent address at http://www.netaddress.com/?N=1

SCSIOP_INQUIRY may tell if the bus is not an SCSI bus.
In order to issue SCSIOP_INQUIRY, you can use
IOCTL_SCSI_PATH_THROUGH.

Please refer to <8.2.5 INQUIRY command> in
SCSI2_specification for details about SCSIOP_INQUIRY.

Regards,
Steve Huang

----- Original Message -----
From: Harish B
To: NT Developers Interest List
Sent: Wednesday, August 23, 2000 2:31 AM
Subject: [ntdev] how to detect whether the device is on an IDE bus

Hi,

I want to check whether my device is on an IDE bus.
Also I have scsi devices attached;
When I issue DeviceIoControl with ioctl_scsi_get_address
as the parameter, even the IDE device behaves as a scsi
device with scsiport 0, targetid 0, LUN 0
I think all IDE devices do behave this way according to
the atapi standard.

IOCTL_DISK_CONTROLLER_NUMBER for this device fails.

system: WinNT sp6 The IDE device is a Quantum disk.

Is there any other way to check whether the device is on
an IDE bus? (I don’t want to query the registry for the
driver for this device)

thanks
Harish