http://msdn2.microsoft.com/en-us/library/aa363965(vs.85).aspx
> DetectionType
> The detected partition type.
> This member can be one of the following values from the DETECTION_TYPE
> enumeration.
> DetectExInt13 2 The disk has an extended Int13 partition.
> DetectInt13 1 The disk has a standard Int13 partition.
> DetectNone 0 The disk does not have an Int13 or an extended
> Int13 partition.

Did someone forget to document this possibility:
DetectBoth 3 The disk has at lease one partition of each
type.

Or if someone forgot to design for this possibility, then what happens?
Some PC creates a standard Int13 partition on a hard drive, a second PC
creates an extended Int13 partition on the same hard drive, and a third PC
calls DeviceIoControl and gets a BSOD?

Next:

> Int13
> If DetectionType is DetectInt13, the union is a DISK_INT13_INFO structure.
> ExInt13
> If DetectionType is DetectExInt13, the union is a DISK_EX_INT13_INFO
> structure.

Is that so? Earlier on the same page, Microsoft said that the union is a
structure of both structures:
> union {
> struct {
> DISK_INT13_INFO Int13;
> DISK_EX_INT13_INFO ExInt13;
> };
> };

In case of any doubt, the above information is not one per partition, it's
one per disk. Look at the DISK_GEOMETRY_EX structure.
http://msdn2.microsoft.com/en-us/library/aa363970(VS.85).aspx

Re: DISK_DETECTION_INFO by Maxim

Maxim
Fri Mar 28 09:12:45 CDT 2008

> Or if someone forgot to design for this possibility, then what happens?
> Some PC creates a standard Int13 partition on a hard drive, a second PC
> creates an extended Int13 partition on the same hard drive, and a third PC
> calls DeviceIoControl and gets a BSOD?

XP and Server 2003 only support DetectInt13.

Actually, the BIOS's disk number is the only value in these structures. The H
and S values are the same as in the usual disk geometry.

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@storagecraft.com
http://www.storagecraft.com


Re: DISK_DETECTION_INFO by Norman

Norman
Sun Mar 30 20:48:41 CDT 2008

"Maxim S. Shatskih" <maxim@storagecraft.com> wrote in message
news:ujp1M3NkIHA.3400@TK2MSFTNGP03.phx.gbl...
[Norman Diamond]
>> Or if someone forgot to design for this possibility, then what happens?
>> Some PC creates a standard Int13 partition on a hard drive, a second PC
>> creates an extended Int13 partition on the same hard drive, and a third
>> PC calls DeviceIoControl and gets a BSOD?
>
> XP and Server 2003 only support DetectInt13.

I'm trying to figure out what this means. If a PC created an extended Int13
partition then a DeviceIoControl call to get DISK_DETECTION_INFO will get it
with DetectionType's value equal to DetectInt13 instead of DetectExInt13?

Even so, what will Vista or Server 2008 do if the drive contains both kinds
of partitions?


Re: DISK_DETECTION_INFO by Maxim

Maxim
Sun Mar 30 21:16:27 CDT 2008

> I'm trying to figure out what this means. If a PC created an extended Int13
> partition then a DeviceIoControl call to get DISK_DETECTION_INFO will get it
> with DetectionType's value equal to DetectInt13 instead of DetectExInt13?

Yes. XP can only return DetectInt13, see Disk source from XP DDK.

BTW - why is this information important? The only int13-related thing which is
important is the BIOS's disk number. Even CHS are automatically used as the
disk's CHS in Windows, not to say modern days in 99.9% of cases H=16 S=64.

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@storagecraft.com
http://www.storagecraft.com


Re: DISK_DETECTION_INFO by Norman

Norman
Sun Mar 30 23:13:55 CDT 2008

"Maxim S. Shatskih" <maxim@storagecraft.com> wrote in message
news:eOm16UtkIHA.1164@TK2MSFTNGP02.phx.gbl...
>> I'm trying to figure out what this means. If a PC created an extended
>> Int13 partition then a DeviceIoControl call to get DISK_DETECTION_INFO
>> will get it with DetectionType's value equal to DetectInt13 instead of
>> DetectExInt13?
>
> Yes. XP can only return DetectInt13, see Disk source from XP DDK.

... if I can still find the XP DDK. Anyway, thank you.

> BTW - why is this information important?

It's just one of several bugs that I saw last week in reading about FAT file
structures. Yeah supposedly we should know not to believe anything we read
in MSDN (even if 75% of it happens to be true). We should ignore MSDN and
rely on experiments. For unknown reasons I still forget to make that
transition.