<div class="content"><p> </p><p>The DISK_INFO 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 diskinfo {
   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;
   boolean isUpgradeable;
   int portNumber;
   int targetNumber;
   int lunNumber;
   LONGLONG lastKnownState;
   LdmObjectId taskId;
   int cchName;
   int cchVendor;
   int cchDgid;
   int cchAdapterName;
   int cchDgName;
   [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;
 };
 typedef struct diskinfo DISK_INFO;
</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 <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_6f13fe5f-8747-4ae0-9375-814bf0528197" data-linktype="relative-path">regions</a></span>
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.</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 used.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>deviceType:</b>  Device type of the
disk. This field contains one of the following values.</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. 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. Valid combinations are device-type dependent.</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 was deleted or experienced an install or hardware
  problem.</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.</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. This field contains one of the following values.</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">Integrated Drive Electronics
  (IDE) bus</a></span>.</p>
  </td>
 </tr><tr>
  <td>
  <p>BUSTYPE_SCSI</p>
  <p>0x00000002</p>
  </td>
  <td>
  <p>Disk resides on a <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">universal serial bus (USB)</a></span>.</p>
  </td>
 </tr><tr>
  <td>
  <p>BUSTYPE_SSA</p>
  <p>0x00000005</p>
  </td>
  <td>
  <p>Disk resides on a <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_dcc7e8a3-030b-4065-8c31-5448032df41d" data-linktype="relative-path">serial storage architecture
  (SSA) Bus</a></span>.</p>
  </td>
 </tr><tr>
  <td>
  <p>BUSTYPE_1394</p>
  <p>0x00000006</p>
  </td>
  <td>
  <p>Disk resides on an Institute of Electronics and
  Electrical Engineers (IEEE) 1394 bus.</p>
  </td>
 </tr></tbody></table>
</dd></dl><p><b>attributes:</b>  Bitmap of disk
attributes. The value of this field is generated by combining zero or more of
the applicable flags defined in the following table 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>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>isUpgradeable:</b>  Boolean value that
indicates whether the disk can be converted to a dynamic disk. Will be 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 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>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, if the bus reports this information.</p><p><b>targetNumber:</b>  SCSI target
identifier of the disk, if the bus reports this information.</p><p><b>lunNumber:</b>  <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_17a307c8-d4b9-4a78-bf01-a1b5a2da11db" data-linktype="relative-path">SCSI
logical unit number (LUN)</a></span> of the disk, if the bus reports this
information.</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. For more
information about this task identifier, see section <span><a href="d55c167e-c6ad-445f-951c-9ac2d0de7a11" data-linktype="relative-path">2.2.17</a></span>.</p><p><b>cchName:</b>  Length of the <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_c6421d9a-1a20-4ef1-983b-5d4208d8e473" data-linktype="relative-path">hard disk
physical name</a></span>, in <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_c305d0ab-8b94-461a-bd76-13b40cb8c4d8" data-linktype="relative-path">Unicode</a></span> characters,
including the terminating null character.</p><p><b>cchVendor:</b>  Length of the disk&#39;s
vendor name, in Unicode characters, including the terminating null character.</p><p><b>cchDgid:</b>  Length of the disk&#39;s group
identification handle, in <span><a href="3c91641b-e5cd-409e-a445-2e4d61ae33c6#gt_79fa85ca-ac61-467c-b819-e97dc1a7a599" data-linktype="relative-path">ASCII</a></span> characters,
including the terminating null character.</p><p><b>cchAdapterName:</b>  Length of the
disk&#39;s adapter name, in Unicode characters, including the terminating null
character.</p><p><b>cchDgName:</b>  Length of the disk&#39;s group
name, in Unicode characters, including the terminating null character.</p><p><b>name:</b>  Null-terminated physical
device name of the hard disk, in the format &#39;\device\Harddisk1&#39;. This is
Unicode.</p><p><b>vendor:</b>  Null-terminated name of the
hard disk vendor. This is the disk vendor&#39;s disk model name. This is Unicode.</p><p><b>dgid:</b>  Specifies the object
identifier of the disk&#39;s disk group. This is ASCII.</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> as
returned by the disk adapter firmware; for example, &#39;Adaptec AHA-2940U2W -
Ultra2 SCSI&#39;. This is Unicode.</p><p><b>dgName:</b>  Null-terminated name for
the disk&#39;s disk group, if the disk is dynamic. Only dynamic disks have an
associated disk group. Basic disks do not. This is Unicode.</p></div>