IOCTL_STORAGE_GET_MEDIA_TYPES_EX
- From: "Norman Diamond" <ndiamond@xxxxxxxxxxxxxxxx>
- Date: Wed, 2 Apr 2008 12:16:02 +0900
Today's quiz.
Q1. If a hard drive is connected through a USB-to-IDE adapter using Microsoft's driver stack for USB2 and hard drives, then does IOCTL_STORAGE_GET_MEDIA_TYPES_EX succeed or does it fail with GetLastError() set to 1 (approximate translation: function is making a mistake)?
A1. Yes. In fact it is so reliable today that we could make a randomizing device by taping the hard drives to each other, flipping them like a coin, and connect whichever drive lands on top. If the Fujitsu drive connects then IOCTL_STORAGE_GET_MEDIA_TYPES_EX succeeds but if the Hitachi drive connects then IOCTL_STORAGE_GET_MEDIA_TYPES_EX fails.
Q2. If a hard drive is connected through a USB-to-IDE adapter using Microsoft's driver stack for USB2 and hard drives, then does IOCTL_STORAGE_GET_MEDIA_TYPES (no EX) succeed or does it fail with GetLastError() set to 50 (approximate translation: this request is not supported)?
A2. Not sure. The reason is that if IOCTL_STORAGE_GET_MEDIA_TYPES_EX succeeds then I neglect to call IOCTL_STORAGE_GET_MEDIA_TYPES (no EX). However, with the Hitachi drive, IOCTL_STORAGE_GET_MEDIA_TYPES (no EX) always fails.
Q3. If a hard drive is connected through a USB-to-IDE adapter using Microsoft's driver stack for USB1.1 and hard drives because Microsoft's driver for USB2 randomly decided that it didn't want to work this time, then do IOCTL_STORAGE_GET_MEDIA_TYPES_EX and IOCTL_STORAGE_GET_MEDIA_TYPES (no EX) succeed or fail?
A3. Oops this one has a reliable answer, at least today. In this situation they always fail, at least today.
Q4. Why?
.
- Follow-Ups:
- Re: IOCTL_STORAGE_GET_MEDIA_TYPES_EX
- From: Maxim S. Shatskih
- Re: IOCTL_STORAGE_GET_MEDIA_TYPES_EX
- From: Doron Holan [MSFT]
- Re: IOCTL_STORAGE_GET_MEDIA_TYPES_EX
- Prev by Date: Re: Read kernel space problem, system hang
- Next by Date: Re: Read kernel space problem, system hang
- Previous by thread: Read kernel space problem, system hang
- Next by thread: Re: IOCTL_STORAGE_GET_MEDIA_TYPES_EX
- Index(es):
Relevant Pages
|
|