(For Win 2K and above)

I've been using the SetupDiXXX to enumerate disk devices on the
system. I need to differentiate between the drives connected through
the built-in motherboard (e.g. Primary, Secondary, etc.) and drives
connected through a plug-in card (e.g PCI RAID controller).

I've noticed that the DeviceDesc for the ones connected to the
built-in IDE controller is "Primary IDE Channel", or "Secondary IDE
Channel", etc. I doubt this will be true for all IDE controllers for
all OSes.

Does anyone know the proper way to find out if a drive is connected to
the built-in IDE controller?

Re: How to find out if drive belongs to built-in IDE controller by Eliyas

Eliyas
Sat May 08 00:39:41 CDT 2004

By reading the bustypes
(SetupDiGetDeviceRegistryProperty(SPDRP_BUSTYPEGUID)) of the parents in the
device tree, you should be able to make that differentiation.

--
-Eliyas
This posting is provided "AS IS" with no warranties, and confers no rights.
http://www.microsoft.com/whdc/hwdev/driver/kb-drv.mspx