shakti wrote:
> Hi,
>
> I'm trying to get the device object pointer for a volume in a driver
> (kernel mode) by using IoGetDeviceObjectPointer.
>
> If I use "/PhysicalDrive0", the call succeeds. But if i use "/Device/
> Harddisk0" or "/Device/HarddiskVolume1" the call fails.
>
> Actually I wanted to get a way to send IOCTL_PASS_THROUGH to a
> specified drive, for eg. C:, which I can do easily from user mode by
> opening a handle to the drive using CreateFile().
>
> Can somebody please explain, why is it happening.
You should use backslash '\', not forward slash '/' in kernel object paths.
--
Olof Lagerkvist
|