<div class="content"><p> </p><p>The DISK_INFO_EX structure provides information about a <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_c4133b2a-a990-4042-ba44-7fda3090f118" data-linktype="relative-path">disk</a></span>.</p><dl>
<dd>
<div><pre> struct diskinfoex {
   LdmObjectId id;
   LONGLONG length;
   LONGLONG freeBytes;
   unsigned long bytesPerTrack;
   unsigned long bytesPerCylinder;
   unsigned long bytesPerSector;
   unsigned long regionCount;
   unsigned long dflags;
   unsigned long deviceType;
   unsigned long deviceState;
   unsigned long busType;
   unsigned long attributes;
   unsigned long maxPartitionCount;
   boolean isUpgradeable;
   boolean maySwitchStyle;
   PARTITIONSTYLE partitionStyle;
   [switch_is(partitionStyle)] union {
     [case(PARTITIONSTYLE_MBR)] 
       struct {
       unsigned long signature;
     } mbr;
     [case(PARTITIONSTYLE_GPT)] 
       struct {
       GUID diskId;
     } gpt;
     [default]       ;
   };
   int portNumber;
   int targetNumber;
   int lunNumber;
   LONGLONG lastKnownState;
   LdmObjectId taskId;
   int cchName;
   int cchVendor;
   int cchDgid;
   int cchAdapterName;
   int cchDgName;
   int cchDevInstId;
   [size_is(cchName)] wchar_t* name;
   [size_is(cchVendor)] wchar_t* vendor;
   [size_is(cchDgid)] byte* dgid;
   [size_is(cchAdapterName)] wchar_t* adapterName;
   [size_is(cchDgName)] wchar_t* dgName;
   [size_is(cchDevInstId)] wchar_t* devInstId;
 };
 typedef struct diskinfoex DISK_INFO_EX;
</pre></div>
</dd></dl><p><b>id:</b>  Specifies the OID of the disk.</p><p><b>length:</b>   Size of the disk in bytes.</p><p><b>freeBytes:</b>  Number of unallocated
bytes on the disk.</p><p><b>bytesPerTrack:</b>  Size of a disk <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_97ccb480-d025-4a9c-995a-5ead9d3076f9" data-linktype="relative-path">track</a></span>
in bytes.</p><p><b>bytesPerCylinder:</b>  Size of a disk <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_cb6bd999-9860-47c5-a5d6-0f267edcaabb" data-linktype="relative-path">cylinder</a></span>
in bytes.</p><p><b>bytesPerSector:</b>  Size of a disk <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_b5bbe646-aa5f-4b4e-ae9e-bdae444cbfa2" data-linktype="relative-path">sector</a></span>
in bytes.</p><p><b>regionCount:</b>  Total number of
regions on the disk.</p><p><b>dflags:</b>  <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_e73d1856-ae37-4059-8ffb-1b22002219f1" data-linktype="relative-path">Disk type</a></span> of the
disk. The value of this field is generated by combining zero or more of the
applicable <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_425bcab9-7911-4eae-b414-624b7a51eb5f" data-linktype="relative-path">flags</a></span> with a logical
OR operation.</p><dl>
<dd>
<table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>
  <p>DISK_AUDIO_CD</p>
  <p>0x00000001</p>
  </td>
  <td>
  <p>Disk is an audio CD.</p>
  </td>
 </tr><tr>
  <td>
  <p>DISK_NEC98</p>
  <p>0x00000002</p>
  </td>
  <td>
  <p>This value is obsolete and MUST NOT be returned.</p>
  </td>
 </tr><tr>
  <td>
  <p>DISK_FORMATTABLE_DVD</p>
  <p>0x00000004</p>
  </td>
  <td>
  <p>Disk is a DVD that can be formatted.</p>
  </td>
 </tr><tr>
  <td>
  <p>DISK_MEMORY_STICK</p>
  <p>0x00000008</p>
  </td>
  <td>
  <p>Disk is a memory stick.</p>
  </td>
 </tr><tr>
  <td>
  <p>DISK_NTFS_NOT_SUPPORTED</p>
  <p>0x000000010</p>
  </td>
  <td>
  <p>Disk does not support being formatted as <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_86f79a17-c0be-4937-8660-0cf6ce5ddc1a" data-linktype="relative-path">NTFS</a></span>.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>deviceType:</b>  Device type of the
disk.</p><dl>
<dd>
<table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>
  <p>DEVICETYPE_UNKNOWN</p>
  <p>0x00000000</p>
  </td>
  <td>
  <p>Device is of an unknown type.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICETYPE_VM</p>
  <p>0x00000001</p>
  </td>
  <td>
  <p>Device is a dynamic disk.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICETYPE_REMOVABLE</p>
  <p>0x00000002</p>
  </td>
  <td>
  <p>Device uses <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_58aae236-0186-4ba1-a46b-f0a997e6c6f2" data-linktype="relative-path">removable media</a></span>.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICETYPE_CDROM</p>
  <p>0x00000003</p>
  </td>
  <td>
  <p>Device is a CD-ROM.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICETYPE_FDISK</p>
  <p>0x00000004</p>
  </td>
  <td>
  <p>Device is a <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_425be2e8-ca0d-45db-afba-d9daee040d07" data-linktype="relative-path">basic disk</a></span>.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICETYPE_DVD</p>
  <p>0x00000005</p>
  </td>
  <td>
  <p>Device is a DVD.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>deviceState:</b>   Device state of the
disk.</p><dl>
<dd>
<table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>
  <p>DEVICESTATE_UNKNOWN</p>
  <p>0x00000000</p>
  </td>
  <td>
  <p>Disk is in an unknown state.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_HEALTHY</p>
  <p>0x00000001</p>
  </td>
  <td>
  <p>Disk is fully functional.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_NO_MEDIA</p>
  <p>0x00000002</p>
  </td>
  <td>
  <p>Disk has no media.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_NOSIG</p>
  <p>0x00000004</p>
  </td>
  <td>
  <p>Disk has an invalid signature.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_BAD</p>
  <p>0x00000008</p>
  </td>
  <td>
  <p>Disk experienced a geometry failure.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_NOT_READY</p>
  <p>0x00000010</p>
  </td>
  <td>
  <p>Disk is not ready yet.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_MISSING</p>
  <p>0x00000020</p>
  </td>
  <td>
  <p>Disk is no longer available.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_OFFLINE</p>
  <p>0x00000040</p>
  </td>
  <td>
  <p>Disk is offline.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_FAILING</p>
  <p>0x00000080</p>
  </td>
  <td>
  <p>Disk experienced a physical I/O error.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_IMPORT_FAILED</p>
  <p>0x00000100</p>
  </td>
  <td>
  <p>Disk belongs to a group whose import failed. See <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_0b3b1554-5a0a-4a00-8948-1d65335fc6ea" data-linktype="relative-path">disk
  group import</a></span>. </p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICESTATE_UNCLAIMED</p>
  <p>0x00000200</p>
  </td>
  <td>
  <p>Disk belongs to a <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_5ec63ea1-a5c7-4538-a099-f9a886f5aa66" data-linktype="relative-path">foreign</a></span> <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_142c4dda-fa9f-45a4-8dfd-61fb3944261e" data-linktype="relative-path">disk
  group</a></span>.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>busType:</b>   Type of <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_36805c8d-5505-4906-986b-8b08a4f0741e" data-linktype="relative-path">bus</a></span>
on which the disk resides.</p><dl>
<dd>
<table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>
  <p>BUSTYPE_UNKNOWN</p>
  <p>0x00000000</p>
  </td>
  <td>
  <p><span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_66a8cd6f-195a-444d-b834-016adb2165c8" data-linktype="relative-path">Bus type</a></span> is
  unknown.</p>
  </td>
 </tr><tr>
  <td>
  <p>BUSTYPE_IDE</p>
  <p>0x00000001</p>
  </td>
  <td>
  <p>Disk resides on an <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_8060307d-3719-401a-8892-f0b3f9c754bb" data-linktype="relative-path">IDE bus</a></span>.</p>
  </td>
 </tr><tr>
  <td>
  <p>BUSTYPE_SCSI</p>
  <p>0x00000002</p>
  </td>
  <td>
  <p>Disk resides on an <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_3bfde62c-c276-4263-9612-9e89133154fd" data-linktype="relative-path">SCSI bus</a></span>.</p>
  </td>
 </tr><tr>
  <td>
  <p>BUSTYPE_FIBRE</p>
  <p>0x00000003</p>
  </td>
  <td>
  <p>Disk resides on a fiber channel bus.</p>
  </td>
 </tr><tr>
  <td>
  <p>BUSTYPE_USB</p>
  <p>0x00000004</p>
  </td>
  <td>
  <p>Disk resides on a <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_2922ead8-cc31-4cea-a2aa-885ac2c9455d" data-linktype="relative-path">USB</a></span>.</p>
  </td>
 </tr><tr>
  <td>
  <p>BUSTYPE_SSA</p>
  <p>0x00000005</p>
  </td>
  <td>
  <p>Disk resides on an <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_dcc7e8a3-030b-4065-8c31-5448032df41d" data-linktype="relative-path">SSA bus</a></span>.</p>
  </td>
 </tr><tr>
  <td>
  <p>BUSTYPE_1394</p>
  <p>0x00000006</p>
  </td>
  <td>
  <p>Disk resides on an IEEE 1394 bus.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>attributes:</b>  Bitmap of disk
attributes.</p><dl>
<dd>
<table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>
  <p>DEVICEATTR_NONE</p>
  <p>0x00000000</p>
  </td>
  <td>
  <p>Disk has no attributes.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICEATTR_RDONLY</p>
  <p>0x00000001</p>
  </td>
  <td>
  <p>Disk is read-only.</p>
  </td>
 </tr><tr>
  <td>
  <p>DEVICEATTR_NTMS</p>
  <p>0x00000002</p>
  </td>
  <td>
  <p>This value is obsolete.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>maxPartitionCount:</b>   Maximum number
of partitions on the disk.</p><p><b>isUpgradeable:</b>   Boolean value that
indicates if the disk can be converted to a dynamic disk. True if the disk is
basic, healthy, and has 512-byte sectors.</p><dl>
<dd>
<table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>
  <p>FALSE</p>
  <p>0</p>
  </td>
  <td>
  <p>Disk cannot be encapsulated or converted to a dynamic
  disk.</p>
  </td>
 </tr><tr>
  <td>
  <p>TRUE</p>
  <p>1</p>
  </td>
  <td>
  <p>Disk can be encapsulated or converted to a dynamic
  disk.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>maySwitchStyle:</b>   Boolean value that
indicates if the disk&#39;s partition style can be changed from <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_b251c771-5ccf-40f2-b98d-0119db210b4b" data-linktype="relative-path">MBR</a></span>
to <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_2fc866b7-7f83-479a-ad4e-fdffcbcff989" data-linktype="relative-path">GPT</a></span>,
or changed from GPT to MBR.</p><dl>
<dd>
<table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>
  <p>FALSE</p>
  <p>0</p>
  </td>
  <td>
  <p>Partition style of the disk cannot be changed.</p>
  </td>
 </tr><tr>
  <td>
  <p>TRUE</p>
  <p>1</p>
  </td>
  <td>
  <p>Partition style of the disk can be changed between MBR
  and GPT.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>partitionStyle:</b>   Value from the <span><a href="c17c0433-880e-4f57-9b71-23e9379d0594" data-linktype="relative-path">PARTITIONSTYLE</a></span>
enumeration that indicates the disk&#39;s partitioning style.</p><p><b>(unnamed union):</b>  A union that
contains either a <b>signature</b> or a <b>diskId</b>, depending on the value
of <b>partitionStyle:</b></p><p><b>signature:</b>  Signature of the disk.
The <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_0e4c21af-021e-4059-ae9a-7821ec3c2e39" data-linktype="relative-path">disk
signature</a></span> is not guaranteed to be unique across machines.<a id="Appendix_A_Target_8"></a><a aria-label="Product behavior note 8" href="5f5043a3-9e6d-40cc-a05b-1a4a3617df32#Appendix_A_8" data-linktype="relative-path">&lt;8&gt;</a></p><p><b>diskId:</b>  <span><a href="../ms-dtyp/49e490b8-f972-45d6-a3a4-99f924998d97" data-linktype="relative-path">GUID</a></span>,
as specified in <span><a href="../ms-dtyp/cca27429-5689-4a16-b2b4-9325d93e4ba2" data-linktype="relative-path">[MS-DTYP]</a></span>,
section 2.3.4.1, of the disk.<a id="Appendix_A_Target_9"></a><a aria-label="Product behavior note 9" href="5f5043a3-9e6d-40cc-a05b-1a4a3617df32#Appendix_A_9" data-linktype="relative-path">&lt;9&gt;</a></p><p><b>portNumber:</b>  <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_9e1126a3-da48-4fd8-aafa-17b25c8818f5" data-linktype="relative-path">SCSI port
number</a></span> of the disk.</p><p><b>targetNumber:</b>   SCSI target
identifier of the disk.</p><p><b>lunNumber:</b>  <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_17a307c8-d4b9-4a78-bf01-a1b5a2da11db" data-linktype="relative-path">SCSI LUN</a></span>
of the disk.</p><p><b>lastKnownState:</b>  <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_5a574d80-6bdb-4fb0-a0dd-b0601d16b4cd" data-linktype="relative-path">Modification
sequence number</a></span> of the disk. </p><p><b>taskId:</b>   The task identifier of the
associated user request. If no request is made, the value is 0.</p><p><b>cchName:</b>   Length of the hard disk&#39;s
physical name, including the terminating null character.</p><p><b>cchVendor:</b>   Length of the disk&#39;s
vendor name, including the terminating null character.</p><p><b>cchDgid:</b>   Length of the disk&#39;s
group identification handle, including the terminating null character.</p><p><b>cchAdapterName:</b>   Length of the
disk&#39;s adapter name, including the terminating null character.</p><p><b>cchDgName:</b>   Length of the disk&#39;s
group name, including the terminating null character.</p><p><b>cchDevInstId:</b>   Length of the disk&#39;s
device instance <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_2cd71385-2d9c-4ab8-bf4a-7b258816d613" data-linktype="relative-path">path</a></span>, including the
terminating null character.</p><p><b>name:</b>  Null-terminated physical name
of the hard disk. For example: &#39;\device\Harddisk1&#39;. </p><p><b>vendor:</b>   Null-terminated name of
the hard disk vendor. This is the disk vendor&#39;s disk model name. For example:
&#34;SEAGATE ST34573N SCSI Disk Device&#34;.</p><p><b>dgid:</b>   Specifies the object
identifier of the disk&#39;s disk group.</p><p><b>adapterName:</b>   Null-terminated name
of the <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_13bf93c4-ba9e-4e36-a915-4a238b3da763" data-linktype="relative-path">disk adapter</a></span>. For
example: &#34;Adaptec AHA-2940U2W - Ultra2 SCSI&#34;.</p><p><b>dgName:</b>  Null-terminated name for
the disk&#39;s disk group, if the disk is dynamic.</p><p><b>devInstId:</b>  Null-terminated device
instance path of the disk with the backslashes replaced by &#34;#&#34;,
&#34;\\?\&#34; prepended to the beginning, and the Pnp disk class <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_f49694cc-c350-462d-ab8e-816f0103c6c1" data-linktype="relative-path">GUID</a></span>,
as specified in [MS-DTYP] section <span><a href="../ms-dtyp/222af2d3-5c00-4899-bc87-ed4c6515e80d" data-linktype="relative-path">2.3.4.3</a></span>,
appended to the end. For example:
&#34;\\?\ide#diskwdc_wd1600jd-75hbb0_____________________08.02d08#5&amp;15c8d966&amp;0&amp;0.0.0#{53f56307-b6bf-11d0-94f2-00a0c91efb8b}&#34;.
</p></div>