ReactOS 0.4.15-dev-7958-gcd0bb1a
ntddstor.h
Go to the documentation of this file.
1/*
2 * ntddstor.h
3 *
4 * Storage class IOCTL interface.
5 *
6 * This file is part of the w32api package.
7 *
8 * Contributors:
9 * Created by Casper S. Hornstrup <chorns@users.sourceforge.net>
10 *
11 * THIS SOFTWARE IS NOT COPYRIGHTED
12 *
13 * This source code is offered for use in the public domain. You may
14 * use, modify or distribute it freely.
15 *
16 * This code is distributed in the hope that it will be useful but
17 * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
18 * DISCLAIMED. This includes but is not limited to warranties of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
20 *
21 */
22
23#ifndef _NTDDSTOR_H_
24#define _NTDDSTOR_H_
25
26#ifdef __cplusplus
27extern "C" {
28#endif
29
30#if defined(DEFINE_GUID)
31
32DEFINE_GUID(GUID_DEVINTERFACE_DISK,
33 0x53f56307L, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
34
35DEFINE_GUID(GUID_DEVINTERFACE_CDROM,
36 0x53f56308L, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
37
38DEFINE_GUID(GUID_DEVINTERFACE_PARTITION,
39 0x53f5630aL, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
40
41DEFINE_GUID(GUID_DEVINTERFACE_TAPE,
42 0x53f5630bL, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
43
44DEFINE_GUID(GUID_DEVINTERFACE_WRITEONCEDISK,
45 0x53f5630cL, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
46
47DEFINE_GUID(GUID_DEVINTERFACE_VOLUME,
48 0x53f5630dL, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
49
50DEFINE_GUID(GUID_DEVINTERFACE_MEDIUMCHANGER,
51 0x53f56310L, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
52
53DEFINE_GUID(GUID_DEVINTERFACE_FLOPPY,
54 0x53f56311L, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
55
56DEFINE_GUID(GUID_DEVINTERFACE_CDCHANGER,
57 0x53f56312L, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
58
59DEFINE_GUID(GUID_DEVINTERFACE_STORAGEPORT,
60 0x2accfe60L, 0xc130, 0x11d2, 0xb0, 0x82, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
61
62DEFINE_GUID(GUID_DEVINTERFACE_HIDDEN_VOLUME,
63 0x7f108a28L, 0x9833, 0x4b3b, 0xb7, 0x80, 0x2c, 0x6b, 0x5f, 0xa5, 0xc0, 0x62);
64
65#define WDI_STORAGE_PREDICT_FAILURE_DPS_GUID \
66 {0xe9f2d03aL, 0x747c, 0x41c2, {0xbb, 0x9a, 0x02, 0xc6, 0x2b, 0x6d, 0x5f, 0xcb}};
67
68/* Aliases for storage guids */
69#define DiskClassGuid GUID_DEVINTERFACE_DISK
70#define CdRomClassGuid GUID_DEVINTERFACE_CDROM
71#define PartitionClassGuid GUID_DEVINTERFACE_PARTITION
72#define TapeClassGuid GUID_DEVINTERFACE_TAPE
73#define WriteOnceDiskClassGuid GUID_DEVINTERFACE_WRITEONCEDISK
74#define VolumeClassGuid GUID_DEVINTERFACE_VOLUME
75#define MediumChangerClassGuid GUID_DEVINTERFACE_MEDIUMCHANGER
76#define FloppyClassGuid GUID_DEVINTERFACE_FLOPPY
77#define CdChangerClassGuid GUID_DEVINTERFACE_CDCHANGER
78#define StoragePortClassGuid GUID_DEVINTERFACE_STORAGEPORT
79#define HiddenVolumeClassGuid GUID_DEVINTERFACE_HIDDEN_VOLUME
80
81#endif /* defined(DEFINE_GUID) */
82
83#if defined(DEFINE_DEVPROPKEY)
84DEFINE_DEVPROPKEY(DEVPKEY_Storage_Portable, 0x4d1ebee8, 0x803, 0x4774, 0x98, 0x42, 0xb7, 0x7d, 0xb5, 0x2, 0x65, 0xe9, 2);
85DEFINE_DEVPROPKEY(DEVPKEY_Storage_Removable_Media, 0x4d1ebee8, 0x803, 0x4774, 0x98, 0x42, 0xb7, 0x7d, 0xb5, 0x2, 0x65, 0xe9, 3);
86DEFINE_DEVPROPKEY(DEVPKEY_Storage_System_Critical, 0x4d1ebee8, 0x803, 0x4774, 0x98, 0x42, 0xb7, 0x7d, 0xb5, 0x2, 0x65, 0xe9, 4);
87DEFINE_DEVPROPKEY(DEVPKEY_Storage_Disk_Number, 0x4d1ebee8, 0x803, 0x4774, 0x98, 0x42, 0xb7, 0x7d, 0xb5, 0x2, 0x65, 0xe9, 5);
88DEFINE_DEVPROPKEY(DEVPKEY_Storage_Partition_Number, 0x4d1ebee8, 0x803, 0x4774, 0x98, 0x42, 0xb7, 0x7d, 0xb5, 0x2, 0x65, 0xe9, 6);
89DEFINE_DEVPROPKEY(DEVPKEY_Storage_Mbr_Type, 0x4d1ebee8, 0x803, 0x4774, 0x98, 0x42, 0xb7, 0x7d, 0xb5, 0x2, 0x65, 0xe9, 7);
90DEFINE_DEVPROPKEY(DEVPKEY_Storage_Gpt_Type, 0x4d1ebee8, 0x803, 0x4774, 0x98, 0x42, 0xb7, 0x7d, 0xb5, 0x2, 0x65, 0xe9, 8);
91DEFINE_DEVPROPKEY(DEVPKEY_Storage_Gpt_Name, 0x4d1ebee8, 0x803, 0x4774, 0x98, 0x42, 0xb7, 0x7d, 0xb5, 0x2, 0x65, 0xe9, 9);
92#endif
93
94#ifndef _WINIOCTL_
95
96#define IOCTL_STORAGE_BASE FILE_DEVICE_MASS_STORAGE
97
98#define IOCTL_STORAGE_CHECK_VERIFY \
99 CTL_CODE(IOCTL_STORAGE_BASE, 0x0200, METHOD_BUFFERED, FILE_READ_ACCESS)
100
101#define IOCTL_STORAGE_CHECK_VERIFY2 \
102 CTL_CODE(IOCTL_STORAGE_BASE, 0x0200, METHOD_BUFFERED, FILE_ANY_ACCESS)
103
104#define IOCTL_STORAGE_MEDIA_REMOVAL \
105 CTL_CODE(IOCTL_STORAGE_BASE, 0x0201, METHOD_BUFFERED, FILE_READ_ACCESS)
106
107#define IOCTL_STORAGE_EJECT_MEDIA \
108 CTL_CODE(IOCTL_STORAGE_BASE, 0x0202, METHOD_BUFFERED, FILE_READ_ACCESS)
109
110#define IOCTL_STORAGE_LOAD_MEDIA \
111 CTL_CODE(IOCTL_STORAGE_BASE, 0x0203, METHOD_BUFFERED, FILE_READ_ACCESS)
112
113#define IOCTL_STORAGE_LOAD_MEDIA2 \
114 CTL_CODE(IOCTL_STORAGE_BASE, 0x0203, METHOD_BUFFERED, FILE_ANY_ACCESS)
115
116#define IOCTL_STORAGE_RESERVE \
117 CTL_CODE(IOCTL_STORAGE_BASE, 0x0204, METHOD_BUFFERED, FILE_READ_ACCESS)
118
119#define IOCTL_STORAGE_RELEASE \
120 CTL_CODE(IOCTL_STORAGE_BASE, 0x0205, METHOD_BUFFERED, FILE_READ_ACCESS)
121
122#define IOCTL_STORAGE_FIND_NEW_DEVICES \
123 CTL_CODE(IOCTL_STORAGE_BASE, 0x0206, METHOD_BUFFERED, FILE_READ_ACCESS)
124
125#define IOCTL_STORAGE_EJECTION_CONTROL \
126 CTL_CODE(IOCTL_STORAGE_BASE, 0x0250, METHOD_BUFFERED, FILE_ANY_ACCESS)
127
128#define IOCTL_STORAGE_MCN_CONTROL \
129 CTL_CODE(IOCTL_STORAGE_BASE, 0x0251, METHOD_BUFFERED, FILE_ANY_ACCESS)
130
131#define IOCTL_STORAGE_GET_MEDIA_TYPES \
132 CTL_CODE(IOCTL_STORAGE_BASE, 0x0300, METHOD_BUFFERED, FILE_ANY_ACCESS)
133
134#define IOCTL_STORAGE_GET_MEDIA_TYPES_EX \
135 CTL_CODE(IOCTL_STORAGE_BASE, 0x0301, METHOD_BUFFERED, FILE_ANY_ACCESS)
136
137#define IOCTL_STORAGE_RESET_BUS \
138 CTL_CODE(IOCTL_STORAGE_BASE, 0x0400, METHOD_BUFFERED, FILE_READ_ACCESS)
139
140#define IOCTL_STORAGE_RESET_DEVICE \
141 CTL_CODE(IOCTL_STORAGE_BASE, 0x0401, METHOD_BUFFERED, FILE_READ_ACCESS)
142
143#define IOCTL_STORAGE_GET_DEVICE_NUMBER \
144 CTL_CODE(IOCTL_STORAGE_BASE, 0x0420, METHOD_BUFFERED, FILE_ANY_ACCESS)
145
146#define IOCTL_STORAGE_PREDICT_FAILURE \
147 CTL_CODE(IOCTL_STORAGE_BASE, 0x0440, METHOD_BUFFERED, FILE_ANY_ACCESS)
148
149#endif /* _WINIOCTL_ */
150
151#define IOCTL_STORAGE_GET_MEDIA_SERIAL_NUMBER \
152 CTL_CODE(IOCTL_STORAGE_BASE, 0x0304, METHOD_BUFFERED, FILE_ANY_ACCESS)
153
154#define IOCTL_STORAGE_GET_HOTPLUG_INFO \
155 CTL_CODE(IOCTL_STORAGE_BASE, 0x0305, METHOD_BUFFERED, FILE_ANY_ACCESS)
156
157#define IOCTL_STORAGE_SET_HOTPLUG_INFO \
158 CTL_CODE(IOCTL_STORAGE_BASE, 0x0306, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
159
160#define OBSOLETE_IOCTL_STORAGE_RESET_BUS \
161 CTL_CODE(IOCTL_STORAGE_BASE, 0x0400, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
162
163#define OBSOLETE_IOCTL_STORAGE_RESET_DEVICE \
164 CTL_CODE(IOCTL_STORAGE_BASE, 0x0401, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
165
166#define IOCTL_STORAGE_BREAK_RESERVATION \
167 CTL_CODE(IOCTL_STORAGE_BASE, 0x0405, METHOD_BUFFERED, FILE_READ_ACCESS)
168
169#define IOCTL_STORAGE_PERSISTENT_RESERVE_IN \
170 CTL_CODE(IOCTL_STORAGE_BASE, 0x0406, METHOD_BUFFERED, FILE_READ_ACCESS)
171
172#define IOCTL_STORAGE_PERSISTENT_RESERVE_OUT \
173 CTL_CODE(IOCTL_STORAGE_BASE, 0x0407, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
174
175#define IOCTL_STORAGE_READ_CAPACITY \
176 CTL_CODE(IOCTL_STORAGE_BASE, 0x0450, METHOD_BUFFERED, FILE_READ_ACCESS)
177
178#define IOCTL_STORAGE_QUERY_PROPERTY \
179 CTL_CODE(IOCTL_STORAGE_BASE, 0x0500, METHOD_BUFFERED, FILE_ANY_ACCESS)
180
181#define IOCTL_STORAGE_MANAGE_DATA_SET_ATTRIBUTES \
182 CTL_CODE(IOCTL_STORAGE_BASE, 0x0501, METHOD_BUFFERED, FILE_WRITE_ACCESS)
183
184#define IOCTL_STORAGE_GET_LB_PROVISIONING_MAP_RESOURCES \
185 CTL_CODE(IOCTL_STORAGE_BASE, 0x0502, METHOD_BUFFERED, FILE_READ_ACCESS)
186
187#define IOCTL_STORAGE_GET_BC_PROPERTIES \
188 CTL_CODE(IOCTL_STORAGE_BASE, 0x0600, METHOD_BUFFERED, FILE_READ_ACCESS)
189
190#define IOCTL_STORAGE_ALLOCATE_BC_STREAM \
191 CTL_CODE(IOCTL_STORAGE_BASE, 0x0601, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
192
193#define IOCTL_STORAGE_FREE_BC_STREAM \
194 CTL_CODE(IOCTL_STORAGE_BASE, 0x0602, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
195
196#define IOCTL_STORAGE_CHECK_PRIORITY_HINT_SUPPORT \
197 CTL_CODE(IOCTL_STORAGE_BASE, 0x0620, METHOD_BUFFERED, FILE_ANY_ACCESS)
198
199#define IOCTL_STORAGE_START_DATA_INTEGRITY_CHECK \
200 CTL_CODE(IOCTL_STORAGE_BASE, 0x0621, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
201
202#define IOCTL_STORAGE_STOP_DATA_INTEGRITY_CHECK \
203 CTL_CODE(IOCTL_STORAGE_BASE, 0x0622, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
204
205#define IOCTL_STORAGE_FIRMWARE_GET_INFO \
206 CTL_CODE(IOCTL_STORAGE_BASE, 0x0700, METHOD_BUFFERED, FILE_ANY_ACCESS)
207
208#define IOCTL_STORAGE_FIRMWARE_DOWNLOAD \
209 CTL_CODE(IOCTL_STORAGE_BASE, 0x0701, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
210
211#define IOCTL_STORAGE_FIRMWARE_ACTIVATE \
212 CTL_CODE(IOCTL_STORAGE_BASE, 0x0702, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
213
214#define IOCTL_STORAGE_ENABLE_IDLE_POWER \
215 CTL_CODE(IOCTL_STORAGE_BASE, 0x0720, METHOD_BUFFERED, FILE_ANY_ACCESS)
216
217#define IOCTL_STORAGE_GET_IDLE_POWERUP_REASON \
218 CTL_CODE(IOCTL_STORAGE_BASE, 0x0721, METHOD_BUFFERED, FILE_ANY_ACCESS)
219
220#define IOCTL_STORAGE_POWER_ACTIVE \
221 CTL_CODE(IOCTL_STORAGE_BASE, 0x0722, METHOD_BUFFERED, FILE_ANY_ACCESS)
222
223#define IOCTL_STORAGE_POWER_IDLE \
224 CTL_CODE(IOCTL_STORAGE_BASE, 0x0723, METHOD_BUFFERED, FILE_ANY_ACCESS)
225
226#define IOCTL_STORAGE_EVENT_NOTIFICATION \
227 CTL_CODE(IOCTL_STORAGE_BASE, 0x0724, METHOD_BUFFERED, FILE_ANY_ACCESS)
228
229#define IOCTL_STORAGE_DEVICE_POWER_CAP \
230 CTL_CODE(IOCTL_STORAGE_BASE, 0x0725, METHOD_BUFFERED, FILE_ANY_ACCESS)
231
232#define IOCTL_STORAGE_RPMB_COMMAND \
233 CTL_CODE(IOCTL_STORAGE_BASE, 0x0726, METHOD_BUFFERED, FILE_ANY_ACCESS)
234
235#define IOCTL_STORAGE_ATTRIBUTE_MANAGEMENT \
236 CTL_CODE(IOCTL_STORAGE_BASE, 0x0727, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS)
237
238#define IOCTL_STORAGE_DIAGNOSTIC \
239 CTL_CODE(IOCTL_STORAGE_BASE, 0x0728, METHOD_BUFFERED, FILE_ANY_ACCESS)
240
241#define IOCTL_STORAGE_GET_PHYSICAL_ELEMENT_STATUS \
242 CTL_CODE(IOCTL_STORAGE_BASE, 0x0729, METHOD_BUFFERED, FILE_ANY_ACCESS)
243
244#define IOCTL_STORAGE_REMOVE_ELEMENT_AND_TRUNCATE \
245 CTL_CODE(IOCTL_STORAGE_BASE, 0x0730, METHOD_BUFFERED, FILE_ANY_ACCESS)
246
247#define IOCTL_STORAGE_GET_DEVICE_INTERNAL_LOG \
248 CTL_CODE(IOCTL_STORAGE_BASE, 0x0731, METHOD_BUFFERED, FILE_ANY_ACCESS)
249
250#define RECOVERED_WRITES_VALID 0x00000001
251#define UNRECOVERED_WRITES_VALID 0x00000002
252#define RECOVERED_READS_VALID 0x00000004
253#define UNRECOVERED_READS_VALID 0x00000008
254#define WRITE_COMPRESSION_INFO_VALID 0x00000010
255#define READ_COMPRESSION_INFO_VALID 0x00000020
256
257#define TAPE_RETURN_STATISTICS 0L
258#define TAPE_RETURN_ENV_INFO 1L
259#define TAPE_RESET_STATISTICS 2L
260
261/* DEVICE_MEDIA_INFO.DeviceSpecific.DiskInfo.MediaCharacteristics constants */
262#define MEDIA_ERASEABLE 0x00000001
263#define MEDIA_WRITE_ONCE 0x00000002
264#define MEDIA_READ_ONLY 0x00000004
265#define MEDIA_READ_WRITE 0x00000008
266#define MEDIA_WRITE_PROTECTED 0x00000100
267#define MEDIA_CURRENTLY_MOUNTED 0x80000000
268
269#define StorageIdTypeNAA StorageIdTypeFCPHName
270
271#define DeviceDsmActionFlag_NonDestructive 0x80000000
272
273#define IsDsmActionNonDestructive(_Action) ((BOOLEAN)((_Action & DeviceDsmActionFlag_NonDestructive) != 0))
274
275#define DeviceDsmAction_None 0x0u
276#define DeviceDsmAction_Trim 0x1u
277#define DeviceDsmAction_Notification (0x00000002u | DeviceDsmActionFlag_NonDestructive)
278#define DeviceDsmAction_OffloadRead (0x00000003u | DeviceDsmActionFlag_NonDestructive)
279#define DeviceDsmAction_OffloadWrite (0x00000004u)
280#define DeviceDsmAction_Allocation (0x00000005u | DeviceDsmActionFlag_NonDestructive)
281#define DeviceDsmAction_Repair (0x00000006u | DeviceDsmActionFlag_NonDestructive)
282#define DeviceDsmAction_Scrub (0x00000007u | DeviceDsmActionFlag_NonDestructive)
283#define DeviceDsmAction_DrtQuery (0x00000008u | DeviceDsmActionFlag_NonDestructive)
284#define DeviceDsmAction_DrtClear (0x00000009u | DeviceDsmActionFlag_NonDestructive)
285#define DeviceDsmAction_DrtDisable (0x0000000Au | DeviceDsmActionFlag_NonDestructive)
286#define DeviceDsmAction_TieringQuery (0x0000000Bu | DeviceDsmActionFlag_NonDestructive)
287#define DeviceDsmAction_Map (0x0000000Cu | DeviceDsmActionFlag_NonDestructive)
288#define DeviceDsmAction_RegenerateParity (0x0000000Du | DeviceDsmActionFlag_NonDestructive)
289#define DeviceDsmAction_NvCache_Change_Priority (0x0000000Eu | DeviceDsmActionFlag_NonDestructive)
290#define DeviceDsmAction_NvCache_Evict (0x0000000Fu | DeviceDsmActionFlag_NonDestructive)
291#define DeviceDsmAction_TopologyIdQuery (0x00000010u | DeviceDsmActionFlag_NonDestructive)
292#define DeviceDsmAction_GetPhysicalAddresses (0x00000011u | DeviceDsmActionFlag_NonDestructive)
293#define DeviceDsmAction_ScopeRegen (0x00000012u | DeviceDsmActionFlag_NonDestructive)
294#define DeviceDsmAction_ReportZones (0x00000013u | DeviceDsmActionFlag_NonDestructive)
295#define DeviceDsmAction_OpenZone (0x00000014u | DeviceDsmActionFlag_NonDestructive)
296#define DeviceDsmAction_FinishZone (0x00000015u | DeviceDsmActionFlag_NonDestructive)
297#define DeviceDsmAction_CloseZone (0x00000016u | DeviceDsmActionFlag_NonDestructive)
298#define DeviceDsmAction_ResetWritePointer (0x00000017u)
299#define DeviceDsmAction_GetRangeErrorInfo (0x00000018u | DeviceDsmActionFlag_NonDestructive)
300#define DeviceDsmAction_WriteZeroes (0x00000019u)
301#define DeviceDsmAction_LostQuery (0x0000001Au | DeviceDsmActionFlag_NonDestructive)
302#define DeviceDsmAction_GetFreeSpace (0x0000001Bu | DeviceDsmActionFlag_NonDestructive)
303#define DeviceDsmAction_ConversionQuery (0x0000001Cu | DeviceDsmActionFlag_NonDestructive)
304#define DeviceDsmAction_VdtSet (0x0000001Du)
305
306#define DEVICE_DSM_FLAG_ENTIRE_DATA_SET_RANGE 0x00000001
307
308#define DEVICE_DSM_NOTIFY_FLAG_BEGIN 0x00000001
309#define DEVICE_DSM_NOTIFY_FLAG_END 0x00000002
310
311#define IOCTL_STORAGE_BC_VERSION 1
312
313#define STORAGE_PRIORITY_HINT_SUPPORTED 0x0001
314
315typedef struct _STORAGE_HOTPLUG_INFO {
316 ULONG Size;
322
328
332
340
341#ifndef _WINIOCTL_
345#endif
346
351
352typedef struct _TAPE_STATISTICS {
362
363typedef struct _TAPE_GET_STATISTICS {
366
368 DDS_4mm = 0x20,
421#if (NTDDI_VERSION < NTDDI_WINXP)
422 STK_EAGLE,
423#else
425#endif
434 VXATape
436
437typedef enum _STORAGE_BUS_TYPE {
455 BusTypeMaxReserved = 0x7F
457
458typedef struct _DEVICE_MEDIA_INFO {
459 union {
460 struct {
469 struct {
478 struct {
483 union {
484 struct {
492
493typedef struct _GET_MEDIA_TYPES {
498
503
510
550
556
557typedef _Struct_size_bytes_(Size) struct _STORAGE_DESCRIPTOR_HEADER {
559 ULONG Size;
561
562typedef _Struct_size_bytes_(Size) struct _STORAGE_DEVICE_DESCRIPTOR {
564 ULONG Size;
566 UCHAR DeviceTypeModifier;
568 BOOLEAN CommandQueueing;
569 ULONG VendorIdOffset;
570 ULONG ProductIdOffset;
571 ULONG ProductRevisionOffset;
572 ULONG SerialNumberOffset;
574 ULONG RawPropertiesLength;
575 UCHAR RawDeviceProperties[1];
577
578typedef _Struct_size_bytes_(Size) struct _STORAGE_ADAPTER_DESCRIPTOR {
580 ULONG Size;
582 ULONG MaximumPhysicalPages;
583 ULONG AlignmentMask;
584 BOOLEAN AdapterUsesPio;
585 BOOLEAN AdapterScansDown;
586 BOOLEAN CommandQueueing;
587 BOOLEAN AcceleratedTransfer;
588#if (NTDDI_VERSION < NTDDI_WINXP)
590#else
592#endif
593 USHORT BusMajorVersion;
594 USHORT BusMinorVersion;
595#if (NTDDI_VERSION >= NTDDI_WIN8)
596 UCHAR SrbType;
597 UCHAR AddressType;
598#endif
600
601typedef _Struct_size_bytes_(Size) struct _STORAGE_ACCESS_ALIGNMENT_DESCRIPTOR {
603 ULONG Size;
604 ULONG BytesPerCacheLine;
605 ULONG BytesOffsetForCacheAlignment;
606 ULONG BytesPerLogicalSector;
607 ULONG BytesPerPhysicalSector;
608 ULONG BytesOffsetForSectorAlignment;
610
611typedef _Struct_size_bytes_(Size) struct _STORAGE_MEDIUM_PRODUCT_TYPE_DESCRIPTOR {
613 ULONG Size;
614 ULONG MediumProductType;
616
627
634#if (NTDDI_VERSION >= NTDDI_WIN8)
636#endif
637#if (NTDDI_VERSION >= NTDDI_WINBLUE)
641#endif
643
655#if (NTDDI_VERSION >= NTDDI_WINBLUE)
658#endif
660
661#define DEVICE_LB_PROVISIONING_DESCRIPTOR_V1_SIZE RTL_SIZEOF_THROUGH_FIELD(DEVICE_LB_PROVISIONING_DESCRIPTOR, UnmapGranularityAlignment)
662
675
689
690typedef _Struct_size_bytes_(Size) struct _STORAGE_DEVICE_IO_CAPABILITY_DESCRIPTOR {
692 ULONG Size;
693 ULONG LunMaxIoCount;
694 ULONG AdapterMaxIoCount;
696
703
715
721
727
728typedef struct _STORAGE_IDENTIFIER {
736
737typedef _Struct_size_bytes_(Size) struct _STORAGE_DEVICE_ID_DESCRIPTOR {
739 ULONG Size;
740 ULONG NumberOfIdentifiers;
741 UCHAR Identifiers[1];
743
749
755
761
763
764#define DEVICE_DSM_FLAG_TRIM_NOT_FS_ALLOCATED 0x80000000
765
770
780
787
796
807
812
816
817#ifdef _MSC_VER
818#pragma warning(push)
819#pragma warning(disable:4200)
820#endif
821
822// #if defined(_MSC_EXTENSIONS)
823
829
833 __MINGW_EXTENSION union {
834 struct {
839 struct {
848
849// #endif /* defined(_MSC_EXTENSIONS) */
850
851#ifdef _MSC_VER
852#pragma warning(pop) /* disable:4200 */
853#endif
854
855typedef _Struct_size_bytes_(Size) struct _STORAGE_READ_CAPACITY {
857 ULONG Size;
858 ULONG BlockLength;
859 LARGE_INTEGER NumberOfBlocks;
860 LARGE_INTEGER DiskLength;
862
863typedef enum _WRITE_CACHE_TYPE {
869
875
881
882typedef enum _WRITE_THROUGH {
887
888typedef _Struct_size_bytes_(Size) struct _STORAGE_WRITE_CACHE_PROPERTY {
890 ULONG Size;
891 WRITE_CACHE_TYPE WriteCacheType;
895 BOOLEAN FlushCacheSupported;
896 BOOLEAN UserDefinedPowerProtection;
897 BOOLEAN NVCacheEnabled;
899
914
926
937
938#define DEVICE_DSM_ALLOCATION_OUTPUT_V1 (sizeof(DEVICE_DSM_ALLOCATION_OUTPUT))
939#define DEVICE_DATA_SET_LB_PROVISIONING_STATE_VERSION_V1 DEVICE_DSM_ALLOCATION_OUTPUT_V1
940
951
952#define DEVICE_DSM_ALLOCATION_OUTPUT_V2 (sizeof(DEVICE_DSM_ALLOCATION_OUTPUT2))
953#define DEVICE_DATA_SET_LB_PROVISIONING_STATE_VERSION_V2 DEVICE_DSM_ALLOCATION_OUTPUT_V2
954
955#define DeviceDsmDefinition_Allocation {DeviceDsmAction_Allocation, \
956 TRUE, \
957 __alignof(DEVICE_DSM_ALLOCATION_PARAMETERS), \
958 sizeof(DEVICE_DSM_ALLOCATION_PARAMETERS), \
959 TRUE, \
960 __alignof(DEVICE_DSM_ALLOCATION_OUTPUT2), \
961 sizeof(DEVICE_DSM_ALLOCATION_OUTPUT2)}
962
963#define DEVICE_DSM_FLAG_ALLOCATION_CONSOLIDATEABLE_ONLY 0x40000000
964
972
978
979#define STORAGE_EVENT_NOTIFICATION_VERSION_V1 1
980
981#define STORAGE_EVENT_MEDIA_STATUS 0x0000000000000001
982#define STORAGE_EVENT_DEVICE_STATUS 0x0000000000000002
983#define STORAGE_EVENT_DEVICE_OPERATION 0x0000000000000004
984#define STORAGE_EVENT_ALL (STORAGE_EVENT_MEDIA_STATUS | STORAGE_EVENT_DEVICE_STATUS | STORAGE_EVENT_DEVICE_OPERATION)
985
986#define STORAGE_OFFLOAD_MAX_TOKEN_LENGTH 512
987#define STORAGE_OFFLOAD_TOKEN_ID_LENGTH 0x1F8
988#define STORAGE_OFFLOAD_TOKEN_TYPE_ZERO_DATA 0xFFFF0001
989
994 union {
995 struct {
1001
1002#define MAKE_ZERO_TOKEN(T) ( \
1003 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenType[0] = 0xFF, \
1004 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenType[1] = 0xFF, \
1005 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenType[2] = 0x00, \
1006 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenType[3] = 0x01, \
1007 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenIdLength[0] = 0x01, \
1008 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenIdLength[1] = 0xF8 \
1009)
1010
1011#define IS_ZERO_TOKEN(T) ( \
1012 (((PSTORAGE_OFFLOAD_TOKEN)T)->TokenType[0] == 0xFF && \
1013 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenType[1] == 0xFF && \
1014 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenType[2] == 0x00 && \
1015 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenType[3] == 0x01 && \
1016 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenIdLength[0] == 0x01 && \
1017 ((PSTORAGE_OFFLOAD_TOKEN)T)->TokenIdLength[1] == 0xF8) \
1018)
1019
1025
1026#define STORAGE_OFFLOAD_READ_RANGE_TRUNCATED 0x00000001
1027
1035
1036#define DeviceDsmDefinition_OffloadRead {DeviceDsmAction_OffloadRead, \
1037 FALSE, \
1038 __alignof(DEVICE_DSM_OFFLOAD_READ_PARAMETERS), \
1039 sizeof(DEVICE_DSM_OFFLOAD_READ_PARAMETERS), \
1040 FALSE, \
1041 __alignof(STORAGE_OFFLOAD_READ_OUTPUT), \
1042 sizeof(STORAGE_OFFLOAD_READ_OUTPUT)}
1043
1050
1051#define STORAGE_OFFLOAD_WRITE_RANGE_TRUNCATED 0x0001
1052#define STORAGE_OFFLOAD_TOKEN_INVALID 0x0002
1053
1059
1060#define DeviceDsmDefinition_OffloadWrite {DeviceDsmAction_OffloadWrite, \
1061 FALSE, \
1062 __alignof(DEVICE_DSM_OFFLOAD_WRITE_PARAMETERS), \
1063 sizeof(DEVICE_DSM_OFFLOAD_WRITE_PARAMETERS), \
1064 FALSE, \
1065 __alignof(STORAGE_OFFLOAD_WRITE_OUTPUT), \
1066 sizeof(STORAGE_OFFLOAD_WRITE_OUTPUT)}
1067
1068
1069#define READ_COPY_NUMBER_KEY 0x52434e00 //'RCN'
1070#define READ_COPY_NUMBER_BYPASS_CACHE_FLAG 0x00000100
1071
1072#define IsKeyReadCopyNumber(_k) (((_k) & 0xFFFFFE00) == READ_COPY_NUMBER_KEY)
1073
1074#define IsKeyReadCopyNumberBypassCache(_k) ((_k) & READ_COPY_NUMBER_BYPASS_CACHE_FLAG)
1075#define SetReadCopyNumberBypassCacheToKey(_k) ((_k) |= READ_COPY_NUMBER_BYPASS_CACHE_FLAG)
1076
1077#define ReadCopyNumberToKey(_c) (READ_COPY_NUMBER_KEY | (UCHAR)(_c))
1078#define ReadCopyNumberFromKey(_k) (UCHAR)((_k) & 0x000000FF)
1079
1080typedef struct _STORAGE_IDLE_POWER {
1088
1089
1090// for IOCTL_STORAGE_GET_IDLE_POWERUP_REASON
1091
1097
1099{
1104
1105#define STORAGE_IDLE_POWERUP_REASON_VERSION_V1 1
1106
1107#ifdef __cplusplus
1108}
1109#endif
1110
1111#endif /* _NTDDSTOR_H_ */
unsigned char BOOLEAN
#define __MINGW_EXTENSION
Definition: _mingw.h:166
enum _STORAGE_MEDIA_TYPE STORAGE_MEDIA_TYPE
_STORAGE_MEDIA_TYPE
Definition: cdrw_usr.h:192
@ STK_EAGLE
Definition: cdrw_usr.h:274
#define DEFINE_DEVPROPKEY(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8, pid)
Definition: devpropdef.h:103
#define DEVICE_TYPE
Definition: guid.c:10
DeviceType
Definition: mmdrv.h:42
#define _Struct_size_bytes_(size)
Definition: ms_sal.h:591
@ RemovableMedia
Definition: ntdddisk.h:387
struct _STORAGE_PROPERTY_QUERY STORAGE_PROPERTY_QUERY
struct _STORAGE_ALLOCATE_BC_STREAM_INPUT STORAGE_ALLOCATE_BC_STREAM_INPUT
struct _STORAGE_IDLE_POWER STORAGE_IDLE_POWER
enum _STORAGE_PORT_CODE_SET * PSTORAGE_PORT_CODE_SET
enum _STORAGE_POWERUP_REASON_TYPE STORAGE_POWERUP_REASON_TYPE
struct _DEVICE_DATA_SET_LB_PROVISIONING_STATE DEVICE_DATA_SET_LB_PROVISIONING_STATE
_WRITE_THROUGH
Definition: ntddstor.h:882
@ WriteThroughSupported
Definition: ntddstor.h:885
@ WriteThroughUnknown
Definition: ntddstor.h:883
@ WriteThroughNotSupported
Definition: ntddstor.h:884
struct _STORAGE_OFFLOAD_TOKEN STORAGE_OFFLOAD_TOKEN
enum _STORAGE_IDENTIFIER_TYPE * PSTORAGE_IDENTIFIER_TYPE
enum _STORAGE_IDENTIFIER_CODE_SET * PSTORAGE_IDENTIFIER_CODE_SET
struct _TAPE_STATISTICS * PTAPE_STATISTICS
struct _STORAGE_EVENT_NOTIFICATION STORAGE_EVENT_NOTIFICATION
* PSTORAGE_DESCRIPTOR_HEADER
Definition: ntddstor.h:560
enum _STORAGE_PROPERTY_ID STORAGE_PROPERTY_ID
struct _STORAGE_MEDIA_SERIAL_NUMBER_DATA * PSTORAGE_MEDIA_SERIAL_NUMBER_DATA
STORAGE_DESCRIPTOR_HEADER
Definition: ntddstor.h:560
struct _STORAGE_HOTPLUG_INFO STORAGE_HOTPLUG_INFO
enum _STORAGE_ID_NAA_FORMAT * PSTORAGE_ID_NAA_FORMAT
STORAGE_ADAPTER_DESCRIPTOR
Definition: ntddstor.h:599
enum _STORAGE_IDENTIFIER_CODE_SET STORAGE_IDENTIFIER_CODE_SET
enum _WRITE_CACHE_ENABLE WRITE_CACHE_ENABLE
struct _STORAGE_MINIPORT_DESCRIPTOR STORAGE_MINIPORT_DESCRIPTOR
ULONG DEVICE_DATA_MANAGEMENT_SET_ACTION
Definition: ntddstor.h:762
struct _STORAGE_ALLOCATE_BC_STREAM_OUTPUT STORAGE_ALLOCATE_BC_STREAM_OUTPUT
struct _STORAGE_ALLOCATE_BC_STREAM_OUTPUT * PSTORAGE_ALLOCATE_BC_STREAM_OUTPUT
struct _DEVICE_MANAGE_DATA_SET_ATTRIBUTES DEVICE_MANAGE_DATA_SET_ATTRIBUTES
enum _STORAGE_ID_NAA_FORMAT STORAGE_ID_NAA_FORMAT
STORAGE_READ_CAPACITY
Definition: ntddstor.h:861
enum _WRITE_CACHE_CHANGE WRITE_CACHE_CHANGE
enum _STORAGE_POWERUP_REASON_TYPE * PSTORAGE_POWERUP_REASON_TYPE
struct _DEVICE_POWER_DESCRIPTOR DEVICE_POWER_DESCRIPTOR
struct _DEVICE_DSM_OFFLOAD_WRITE_PARAMETERS DEVICE_DSM_OFFLOAD_WRITE_PARAMETERS
struct _DEVICE_DATA_SET_LB_PROVISIONING_STATE_V2 DEVICE_DSM_ALLOCATION_OUTPUT2
_STORAGE_IDENTIFIER_CODE_SET
Definition: ntddstor.h:697
@ StorageIdCodeSetUtf8
Definition: ntddstor.h:701
@ StorageIdCodeSetBinary
Definition: ntddstor.h:699
@ StorageIdCodeSetReserved
Definition: ntddstor.h:698
@ StorageIdCodeSetAscii
Definition: ntddstor.h:700
struct _STORAGE_DEVICE_NUMBER STORAGE_DEVICE_NUMBER
struct _STORAGE_IDENTIFIER * PSTORAGE_IDENTIFIER
* PSTORAGE_WRITE_CACHE_PROPERTY
Definition: ntddstor.h:898
struct _DEVICE_DATA_SET_LB_PROVISIONING_STATE * PDEVICE_DATA_SET_LB_PROVISIONING_STATE
struct _STORAGE_PRIORITY_HINT_SUPPORT * PSTORAGE_PRIORITY_HINT_SUPPORT
enum _STORAGE_QUERY_TYPE * PSTORAGE_QUERY_TYPE
struct _DEVICE_SEEK_PENALTY_DESCRIPTOR DEVICE_SEEK_PENALTY_DESCRIPTOR
_WRITE_CACHE_CHANGE
Definition: ntddstor.h:876
@ WriteCacheChangeUnknown
Definition: ntddstor.h:877
@ WriteCacheChangeable
Definition: ntddstor.h:879
@ WriteCacheNotChangeable
Definition: ntddstor.h:878
struct _STORAGE_MINIPORT_DESCRIPTOR * PSTORAGE_MINIPORT_DESCRIPTOR
struct _PREVENT_MEDIA_REMOVAL * PPREVENT_MEDIA_REMOVAL
struct _DEVICE_SEEK_PENALTY_DESCRIPTOR * PDEVICE_SEEK_PENALTY_DESCRIPTOR
struct _STORAGE_EVENT_NOTIFICATION * PSTORAGE_EVENT_NOTIFICATION
_WRITE_CACHE_TYPE
Definition: ntddstor.h:863
@ WriteCacheTypeNone
Definition: ntddstor.h:865
@ WriteCacheTypeWriteBack
Definition: ntddstor.h:866
@ WriteCacheTypeUnknown
Definition: ntddstor.h:864
@ WriteCacheTypeWriteThrough
Definition: ntddstor.h:867
struct _STORAGE_BUS_RESET_REQUEST * PSTORAGE_BUS_RESET_REQUEST
_STORAGE_POWERUP_REASON_TYPE
Definition: ntddstor.h:1092
@ StoragePowerupUnknown
Definition: ntddstor.h:1093
@ StoragePowerupIO
Definition: ntddstor.h:1094
@ StoragePowerupDeviceAttention
Definition: ntddstor.h:1095
struct _DEVICE_WRITE_AGGREGATION_DESCRIPTOR * PDEVICE_WRITE_AGGREGATION_DESCRIPTOR
enum _STORAGE_PORT_CODE_SET STORAGE_PORT_CODE_SET
enum _STORAGE_MEDIA_TYPE STORAGE_MEDIA_TYPE
struct _STORAGE_BREAK_RESERVATION_REQUEST STORAGE_BREAK_RESERVATION_REQUEST
_STORAGE_BUS_TYPE
Definition: ntddstor.h:437
@ BusTypeScsi
Definition: ntddstor.h:439
@ BusTypeMmc
Definition: ntddstor.h:451
@ BusTypeiScsi
Definition: ntddstor.h:447
@ BusTypeSd
Definition: ntddstor.h:450
@ BusTypeMaxReserved
Definition: ntddstor.h:455
@ BusTypeFileBackedVirtual
Definition: ntddstor.h:453
@ BusTypeUsb
Definition: ntddstor.h:445
@ BusTypeSsa
Definition: ntddstor.h:443
@ BusTypeSas
Definition: ntddstor.h:448
@ BusTypeMax
Definition: ntddstor.h:454
@ BusTypeSata
Definition: ntddstor.h:449
@ BusTypeRAID
Definition: ntddstor.h:446
@ BusTypeVirtual
Definition: ntddstor.h:452
@ BusTypeFibre
Definition: ntddstor.h:444
@ BusTypeAtapi
Definition: ntddstor.h:440
@ BusTypeUnknown
Definition: ntddstor.h:438
@ BusType1394
Definition: ntddstor.h:442
@ BusTypeAta
Definition: ntddstor.h:441
struct _DEVICE_COPY_OFFLOAD_DESCRIPTOR DEVICE_COPY_OFFLOAD_DESCRIPTOR
struct _DEVICE_COPY_OFFLOAD_DESCRIPTOR * PDEVICE_COPY_OFFLOAD_DESCRIPTOR
struct _DEVICE_DATA_SET_RANGE * PDEVICE_DATA_SET_RANGE
struct _STORAGE_BUS_RESET_REQUEST STORAGE_BUS_RESET_REQUEST
struct _STORAGE_LB_PROVISIONING_MAP_RESOURCES STORAGE_LB_PROVISIONING_MAP_RESOURCES
struct _PERSISTENT_RESERVE_COMMAND * PPERSISTENT_RESERVE_COMMAND
struct _CLASS_MEDIA_CHANGE_CONTEXT CLASS_MEDIA_CHANGE_CONTEXT
struct _STORAGE_MEDIA_SERIAL_NUMBER_DATA STORAGE_MEDIA_SERIAL_NUMBER_DATA
STORAGE_ACCESS_ALIGNMENT_DESCRIPTOR
Definition: ntddstor.h:609
STORAGE_MEDIUM_PRODUCT_TYPE_DESCRIPTOR
Definition: ntddstor.h:615
enum _STORAGE_MEDIA_TYPE * PSTORAGE_MEDIA_TYPE
struct _DEVICE_WRITE_AGGREGATION_DESCRIPTOR DEVICE_WRITE_AGGREGATION_DESCRIPTOR
struct _DEVICE_DATA_SET_LB_PROVISIONING_STATE * PDEVICE_DSM_ALLOCATION_OUTPUT
struct _STORAGE_IDLE_POWERUP_REASON STORAGE_IDLE_POWERUP_REASON
struct _GET_MEDIA_TYPES * PGET_MEDIA_TYPES
struct _DEVICE_DATA_SET_LBP_STATE_PARAMETERS * PDEVICE_DSM_ALLOCATION_PARAMETERS
struct _DEVICE_LB_PROVISIONING_DESCRIPTOR * PDEVICE_LB_PROVISIONING_DESCRIPTOR
struct _STORAGE_OFFLOAD_WRITE_OUTPUT * PSTORAGE_OFFLOAD_WRITE_OUTPUT
struct _STORAGE_IDLE_POWERUP_REASON * PSTORAGE_IDLE_POWERUP_REASON
struct _STORAGE_PRIORITY_HINT_SUPPORT STORAGE_PRIORITY_HINT_SUPPORT
enum _STORAGE_ASSOCIATION_TYPE STORAGE_ASSOCIATION_TYPE
struct _PREVENT_MEDIA_REMOVAL PREVENT_MEDIA_REMOVAL
enum _STORAGE_ASSOCIATION_TYPE * PSTORAGE_ASSOCIATION_TYPE
* PSTORAGE_ACCESS_ALIGNMENT_DESCRIPTOR
Definition: ntddstor.h:609
* PSTORAGE_DEVICE_DESCRIPTOR
Definition: ntddstor.h:576
struct _DEVICE_MANAGE_DATA_SET_ATTRIBUTES * PDEVICE_MANAGE_DATA_SET_ATTRIBUTES
struct _STORAGE_OFFLOAD_READ_OUTPUT * PSTORAGE_OFFLOAD_READ_OUTPUT
_STORAGE_PROPERTY_ID
Definition: ntddstor.h:511
@ StorageMiniportProperty
Definition: ntddstor.h:517
@ StorageDeviceUniqueIdProperty
Definition: ntddstor.h:515
@ StorageDevicePhysicalTopologyProperty
Definition: ntddstor.h:540
@ StorageDeviceZonedDeviceProperty
Definition: ntddstor.h:546
@ StorageDeviceDependantDevicesProperty
Definition: ntddstor.h:533
@ StorageDeviceMediumProductType
Definition: ntddstor.h:527
@ StorageDeviceUnsafeShutdownCount
Definition: ntddstor.h:547
@ StorageAdapterRpmbProperty
Definition: ntddstor.h:528
@ StorageAdapterProtocolSpecificProperty
Definition: ntddstor.h:535
@ StorageDeviceFaultDomainProperty
Definition: ntddstor.h:531
@ StorageDeviceIoCapabilityProperty
Definition: ntddstor.h:534
@ StorageDeviceSeekPenaltyProperty
Definition: ntddstor.h:519
@ StorageAdapterPhysicalTopologyProperty
Definition: ntddstor.h:539
@ StorageDeviceIdProperty
Definition: ntddstor.h:514
@ StorageDeviceProtocolSpecificProperty
Definition: ntddstor.h:536
@ StorageDeviceLBProvisioningProperty
Definition: ntddstor.h:523
@ StorageDeviceDeviceTelemetryProperty
Definition: ntddstor.h:522
@ StorageAdapterCryptoProperty
Definition: ntddstor.h:529
@ StorageDeviceWriteAggregationProperty
Definition: ntddstor.h:521
@ StorageDeviceWriteCacheProperty
Definition: ntddstor.h:516
@ StorageDeviceTieringProperty
Definition: ntddstor.h:530
@ StorageDeviceManagementStatus
Definition: ntddstor.h:542
@ StorageAdapterProperty
Definition: ntddstor.h:513
@ StorageDeviceTemperatureProperty
Definition: ntddstor.h:538
@ StorageDeviceNumaProperty
Definition: ntddstor.h:545
@ StorageDeviceAttributesProperty
Definition: ntddstor.h:541
@ StorageDeviceLocationProperty
Definition: ntddstor.h:544
@ StorageDeviceEnduranceProperty
Definition: ntddstor.h:548
@ StorageDeviceTrimProperty
Definition: ntddstor.h:520
@ StorageDevicePowerProperty
Definition: ntddstor.h:524
@ StorageDeviceClusportProperty
Definition: ntddstor.h:532
@ StorageAdapterSerialNumberProperty
Definition: ntddstor.h:543
@ StorageAdapterTemperatureProperty
Definition: ntddstor.h:537
@ StorageDeviceCopyOffloadProperty
Definition: ntddstor.h:525
@ StorageAccessAlignmentProperty
Definition: ntddstor.h:518
@ StorageDeviceResiliencyProperty
Definition: ntddstor.h:526
@ StorageDeviceProperty
Definition: ntddstor.h:512
struct _DEVICE_DATA_SET_LBP_STATE_PARAMETERS DEVICE_DATA_SET_LBP_STATE_PARAMETERS
enum _STORAGE_BUS_TYPE * PSTORAGE_BUS_TYPE
struct _DEVICE_DATA_SET_LB_PROVISIONING_STATE_V2 * PDEVICE_DATA_SET_LB_PROVISIONING_STATE_V2
struct _STORAGE_BREAK_RESERVATION_REQUEST * PSTORAGE_BREAK_RESERVATION_REQUEST
struct _TAPE_STATISTICS TAPE_STATISTICS
* PSTORAGE_DEVICE_IO_CAPABILITY_DESCRIPTOR
Definition: ntddstor.h:695
struct _CLASS_MEDIA_CHANGE_CONTEXT * PCLASS_MEDIA_CHANGE_CONTEXT
struct _STORAGE_IDENTIFIER STORAGE_IDENTIFIER
struct _STORAGE_PROPERTY_QUERY * PSTORAGE_PROPERTY_QUERY
struct _DEVICE_DATA_SET_LB_PROVISIONING_STATE_V2 * PDEVICE_DSM_ALLOCATION_OUTPUT2
struct _DEVICE_MANAGE_DATA_SET_ATTRIBUTES_OUTPUT DEVICE_MANAGE_DATA_SET_ATTRIBUTES_OUTPUT
struct _DEVICE_TRIM_DESCRIPTOR DEVICE_TRIM_DESCRIPTOR
enum _STORAGE_QUERY_TYPE STORAGE_QUERY_TYPE
enum _STORAGE_BUS_TYPE STORAGE_BUS_TYPE
struct _DEVICE_LB_PROVISIONING_DESCRIPTOR DEVICE_LB_PROVISIONING_DESCRIPTOR
_WRITE_CACHE_ENABLE
Definition: ntddstor.h:870
@ WriteCacheEnableUnknown
Definition: ntddstor.h:871
@ WriteCacheDisabled
Definition: ntddstor.h:872
@ WriteCacheEnabled
Definition: ntddstor.h:873
struct _STORAGE_IDLE_POWER * PSTORAGE_IDLE_POWER
struct _STORAGE_ALLOCATE_BC_STREAM_INPUT * PSTORAGE_ALLOCATE_BC_STREAM_INPUT
STORAGE_DEVICE_DESCRIPTOR
Definition: ntddstor.h:576
struct _DEVICE_MANAGE_DATA_SET_ATTRIBUTES_OUTPUT * PDEVICE_MANAGE_DATA_SET_ATTRIBUTES_OUTPUT
enum _WRITE_THROUGH WRITE_THROUGH
STORAGE_DEVICE_ID_DESCRIPTOR
Definition: ntddstor.h:742
_STORAGE_IDENTIFIER_TYPE
Definition: ntddstor.h:704
@ StorageIdTypeLogicalUnitGroup
Definition: ntddstor.h:711
@ StorageIdTypeEUI64
Definition: ntddstor.h:707
@ StorageIdTypePortRelative
Definition: ntddstor.h:709
@ StorageIdTypeMD5LogicalUnitIdentifier
Definition: ntddstor.h:712
@ StorageIdTypeFCPHName
Definition: ntddstor.h:708
@ StorageIdTypeTargetPortGroup
Definition: ntddstor.h:710
@ StorageIdTypeVendorId
Definition: ntddstor.h:706
@ StorageIdTypeScsiNameString
Definition: ntddstor.h:713
@ StorageIdTypeVendorSpecific
Definition: ntddstor.h:705
enum _WRITE_CACHE_TYPE WRITE_CACHE_TYPE
_STORAGE_QUERY_TYPE
Definition: ntddstor.h:504
@ PropertyMaskQuery
Definition: ntddstor.h:507
@ PropertyQueryMaxDefined
Definition: ntddstor.h:508
@ PropertyExistsQuery
Definition: ntddstor.h:506
@ PropertyStandardQuery
Definition: ntddstor.h:505
struct _TAPE_GET_STATISTICS TAPE_GET_STATISTICS
STORAGE_DEVICE_IO_CAPABILITY_DESCRIPTOR
Definition: ntddstor.h:695
struct _TAPE_GET_STATISTICS * PTAPE_GET_STATISTICS
struct _STORAGE_PREDICT_FAILURE STORAGE_PREDICT_FAILURE
@ SYQUEST_EZ135
Definition: ntddstor.h:411
@ NCTP
Definition: ntddstor.h:376
@ VXATape_1
Definition: ntddstor.h:419
@ SONY_DTF
Definition: ntddstor.h:382
@ AIT1_8mm
Definition: ntddstor.h:374
@ IOMEGA_JAZ
Definition: ntddstor.h:410
@ CD_R
Definition: ntddstor.h:388
@ KODAK_14_WO
Definition: ntddstor.h:406
@ DST_M
Definition: ntddstor.h:417
@ SYQUEST_EZFLYER
Definition: ntddstor.h:412
@ SYQUEST_SYJET
Definition: ntddstor.h:413
@ DST_L
Definition: ntddstor.h:418
@ CD_ROM
Definition: ntddstor.h:387
@ PC_5_WO
Definition: ntddstor.h:397
@ DVD_RW
Definition: ntddstor.h:392
@ DV_6mm
Definition: ntddstor.h:383
@ PHILIPS_12_WO
Definition: ntddstor.h:403
@ DMI
Definition: ntddstor.h:384
@ AME_8mm
Definition: ntddstor.h:373
@ IBM_3480
Definition: ntddstor.h:377
@ SAIT
Definition: ntddstor.h:433
@ AIT_8mm
Definition: ntddstor.h:429
@ CLEANER_CARTRIDGE
Definition: ntddstor.h:386
@ QIC
Definition: ntddstor.h:371
@ HITACHI_12_WO
Definition: ntddstor.h:404
@ VXATape
Definition: ntddstor.h:434
@ MP_8mm
Definition: ntddstor.h:372
@ STK_DATA_D3
Definition: ntddstor.h:381
@ PC_5_RW
Definition: ntddstor.h:398
@ IOMEGA_ZIP
Definition: ntddstor.h:409
@ PINNACLE_APEX_5_RW
Definition: ntddstor.h:401
@ DVD_R
Definition: ntddstor.h:391
@ ABL_5_WO
Definition: ntddstor.h:400
@ DLT
Definition: ntddstor.h:375
@ SONY_D2
Definition: ntddstor.h:385
@ CYGNET_12_WO
Definition: ntddstor.h:405
@ MO_3_RW
Definition: ntddstor.h:393
@ DVD_ROM
Definition: ntddstor.h:390
@ DDS_4mm
Definition: ntddstor.h:368
@ MP2_8mm
Definition: ntddstor.h:415
@ IBM_Magstar_3590
Definition: ntddstor.h:379
@ IBM_Magstar_MP
Definition: ntddstor.h:380
@ LTO_Ultrium
Definition: ntddstor.h:426
@ ADR_1
Definition: ntddstor.h:430
@ STK_9940
Definition: ntddstor.h:432
@ IBM_3490E
Definition: ntddstor.h:378
@ CD_RW
Definition: ntddstor.h:389
@ VXATape_2
Definition: ntddstor.h:420
@ NIKON_12_RW
Definition: ntddstor.h:408
@ DVD_RAM
Definition: ntddstor.h:428
@ DST_S
Definition: ntddstor.h:416
@ LTO_Accelis
Definition: ntddstor.h:427
@ MO_5_RW
Definition: ntddstor.h:395
@ ADR_2
Definition: ntddstor.h:431
@ SONY_12_WO
Definition: ntddstor.h:402
@ MiniQic
Definition: ntddstor.h:369
@ Travan
Definition: ntddstor.h:370
@ PD_5_RW
Definition: ntddstor.h:399
@ MO_NFR_525
Definition: ntddstor.h:407
@ AVATAR_F2
Definition: ntddstor.h:414
@ STK_9840
Definition: ntddstor.h:424
@ MO_5_WO
Definition: ntddstor.h:394
@ MO_5_LIMDOW
Definition: ntddstor.h:396
struct _STORAGE_LB_PROVISIONING_MAP_RESOURCES * PSTORAGE_LB_PROVISIONING_MAP_RESOURCES
struct _STORAGE_OFFLOAD_WRITE_OUTPUT STORAGE_OFFLOAD_WRITE_OUTPUT
struct _STORAGE_OFFLOAD_TOKEN * PSTORAGE_OFFLOAD_TOKEN
struct _STORAGE_HOTPLUG_INFO * PSTORAGE_HOTPLUG_INFO
struct _DEVICE_DSM_NOTIFICATION_PARAMETERS DEVICE_DSM_NOTIFICATION_PARAMETERS
struct _STORAGE_PREDICT_FAILURE * PSTORAGE_PREDICT_FAILURE
struct _STORAGE_OFFLOAD_READ_OUTPUT STORAGE_OFFLOAD_READ_OUTPUT
enum _STORAGE_PROPERTY_ID * PSTORAGE_PROPERTY_ID
struct _DEVICE_TRIM_DESCRIPTOR * PDEVICE_TRIM_DESCRIPTOR
#define STORAGE_OFFLOAD_TOKEN_ID_LENGTH
Definition: ntddstor.h:987
struct _DEVICE_POWER_DESCRIPTOR * PDEVICE_POWER_DESCRIPTOR
struct _DEVICE_DATA_SET_LBP_STATE_PARAMETERS * PDEVICE_DATA_SET_LBP_STATE_PARAMETERS
struct _STORAGE_GET_BC_PROPERTIES_OUTPUT * PSTORAGE_GET_BC_PROPERTIES_OUTPUT
struct _DEVICE_DSM_OFFLOAD_WRITE_PARAMETERS * PDEVICE_DSM_OFFLOAD_WRITE_PARAMETERS
_STORAGE_PORT_CODE_SET
Definition: ntddstor.h:617
@ StoragePortCodeSetReserved
Definition: ntddstor.h:618
@ StoragePortCodeSetStorport
Definition: ntddstor.h:619
@ StoragePortCodeSetATAport
Definition: ntddstor.h:622
@ StoragePortCodeSetSBP2port
Definition: ntddstor.h:624
@ StoragePortCodeSetUSBport
Definition: ntddstor.h:623
@ StoragePortCodeSetSpaceport
Definition: ntddstor.h:621
@ StoragePortCodeSetSCSIport
Definition: ntddstor.h:620
@ StoragePortCodeSetSDport
Definition: ntddstor.h:625
struct _DEVICE_MEDIA_INFO DEVICE_MEDIA_INFO
struct _STORAGE_DEVICE_NUMBER * PSTORAGE_DEVICE_NUMBER
STORAGE_WRITE_CACHE_PROPERTY
Definition: ntddstor.h:898
struct _DEVICE_DATA_SET_RANGE DEVICE_DATA_SET_RANGE
struct _DEVICE_DSM_OFFLOAD_READ_PARAMETERS * PDEVICE_DSM_OFFLOAD_READ_PARAMETERS
_STORAGE_ID_NAA_FORMAT
Definition: ntddstor.h:716
@ StorageIdNAAFormatIEEERegistered
Definition: ntddstor.h:718
@ StorageIdNAAFormatIEEEERegisteredExtended
Definition: ntddstor.h:719
@ StorageIdNAAFormatIEEEExtended
Definition: ntddstor.h:717
* PSTORAGE_MEDIUM_PRODUCT_TYPE_DESCRIPTOR
Definition: ntddstor.h:615
struct _STORAGE_GET_BC_PROPERTIES_OUTPUT STORAGE_GET_BC_PROPERTIES_OUTPUT
struct _DEVICE_DSM_NOTIFICATION_PARAMETERS * PDEVICE_DSM_NOTIFICATION_PARAMETERS
* PSTORAGE_DEVICE_ID_DESCRIPTOR
Definition: ntddstor.h:742
struct _DEVICE_MEDIA_INFO * PDEVICE_MEDIA_INFO
* PSTORAGE_ADAPTER_DESCRIPTOR
Definition: ntddstor.h:599
enum _STORAGE_IDENTIFIER_TYPE STORAGE_IDENTIFIER_TYPE
* PSTORAGE_READ_CAPACITY
Definition: ntddstor.h:861
struct _GET_MEDIA_TYPES GET_MEDIA_TYPES
_STORAGE_ASSOCIATION_TYPE
Definition: ntddstor.h:722
@ StorageIdAssocPort
Definition: ntddstor.h:724
@ StorageIdAssocTarget
Definition: ntddstor.h:725
@ StorageIdAssocDevice
Definition: ntddstor.h:723
struct _DEVICE_DATA_SET_LB_PROVISIONING_STATE DEVICE_DSM_ALLOCATION_OUTPUT
struct _PERSISTENT_RESERVE_COMMAND PERSISTENT_RESERVE_COMMAND
struct _DEVICE_DATA_SET_LBP_STATE_PARAMETERS DEVICE_DSM_ALLOCATION_PARAMETERS
struct _DEVICE_DATA_SET_LB_PROVISIONING_STATE_V2 DEVICE_DATA_SET_LB_PROVISIONING_STATE_V2
struct _DEVICE_DSM_OFFLOAD_READ_PARAMETERS DEVICE_DSM_OFFLOAD_READ_PARAMETERS
unsigned short USHORT
Definition: pedump.c:61
#define DEFINE_GUID(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8)
Definition: guiddef.h:68
_In_opt_ WDFREQUEST _In_ ULONG MaximumTransferLength
Definition: scratch.h:54
ULONG SlabAllocationBitMap[ANYSIZE_ARRAY]
Definition: ntddstor.h:948
ULONG SlabAllocationBitMap[ANYSIZE_ARRAY]
Definition: ntddstor.h:934
ULONGLONG LengthInBytes
Definition: ntddstor.h:768
LONGLONG StartingOffset
Definition: ntddstor.h:767
STORAGE_OFFLOAD_TOKEN Token
Definition: ntddstor.h:1048
DEVICE_DATA_MANAGEMENT_SET_ACTION Action
Definition: ntddstor.h:917
DEVICE_DATA_MANAGEMENT_SET_ACTION Action
Definition: ntddstor.h:773
ULONG TracksPerCylinder
Definition: ntddstor.h:463
struct _DEVICE_MEDIA_INFO::@3170::@3171 DiskInfo
ULONG BytesPerSector
Definition: ntddstor.h:465
union _DEVICE_MEDIA_INFO::@3170 DeviceSpecific
ULONG MediaCharacteristics
Definition: ntddstor.h:467
ULONG SectorsPerTrack
Definition: ntddstor.h:464
STORAGE_BUS_TYPE BusType
Definition: ntddstor.h:482
STORAGE_MEDIA_TYPE MediaType
Definition: ntddstor.h:462
union _DEVICE_MEDIA_INFO::@3170::@3173::@3174 BusSpecificData
ULONG NumberMediaSides
Definition: ntddstor.h:466
LARGE_INTEGER Cylinders
Definition: ntddstor.h:461
struct _DEVICE_MEDIA_INFO::@3170::@3173 TapeInfo
struct _DEVICE_MEDIA_INFO::@3170::@3172 RemovableDiskInfo
struct _DEVICE_MEDIA_INFO::@3170::@3173::@3174::@3175 ScsiInformation
ULONG CurrentBlockSize
Definition: ntddstor.h:481
BOOLEAN IdlePowerManagementEnabled
Definition: ntddstor.h:668
BOOLEAN NoVerifyDuringIdlePower
Definition: ntddstor.h:671
BOOLEAN DeviceAttentionSupported
Definition: ntddstor.h:666
BOOLEAN AsynchronousNotificationSupported
Definition: ntddstor.h:667
ULONG DeviceType
Definition: ntddstor.h:494
DEVICE_MEDIA_INFO MediaInfo[1]
Definition: ntddstor.h:496
ULONG MediaInfoCount
Definition: ntddstor.h:495
struct _PERSISTENT_RESERVE_COMMAND::@3176::@3177 PR_IN
struct _PERSISTENT_RESERVE_COMMAND::@3176::@3178 PR_OUT
__MINGW_EXTENSION union _PERSISTENT_RESERVE_COMMAND::@3176 DUMMYUNIONNAME
BOOLEAN PreventMediaRemoval
Definition: ntddstor.h:343
DEVICE_TYPE DeviceType
Definition: ntddstor.h:324
BOOLEAN WriteCacheEnableOverride
Definition: imports.h:249
BOOLEAN MediaRemovable
Definition: imports.h:246
BOOLEAN DeviceHotplug
Definition: imports.h:248
BOOLEAN MediaHotplug
Definition: imports.h:247
USHORT IdentifierSize
Definition: ntddstor.h:731
STORAGE_IDENTIFIER_CODE_SET CodeSet
Definition: ntddstor.h:729
STORAGE_ASSOCIATION_TYPE Association
Definition: ntddstor.h:733
STORAGE_IDENTIFIER_TYPE Type
Definition: ntddstor.h:730
UCHAR Identifier[1]
Definition: ntddstor.h:734
STORAGE_POWERUP_REASON_TYPE PowerupReason
Definition: ntddstor.h:1102
STORAGE_PORT_CODE_SET Portdriver
Definition: ntddstor.h:631
STORAGE_OFFLOAD_TOKEN Token
Definition: ntddstor.h:1033
UCHAR Reserved2[STORAGE_OFFLOAD_TOKEN_ID_LENGTH]
Definition: ntddstor.h:996
union _STORAGE_OFFLOAD_TOKEN::@3179 DUMMYUNIONNAME
struct _STORAGE_OFFLOAD_TOKEN::@3179::@3180 StorageOffloadZeroDataToken
UCHAR TokenIdLength[2]
Definition: ntddstor.h:993
UCHAR VendorSpecific[512]
Definition: ntddstor.h:501
STORAGE_QUERY_TYPE QueryType
Definition: ntddstor.h:553
UCHAR AdditionalParameters[1]
Definition: ntddstor.h:554
STORAGE_PROPERTY_ID PropertyId
Definition: ntddstor.h:552
LARGE_INTEGER UnrecoveredReads
Definition: ntddstor.h:358
LARGE_INTEGER RecoveredWrites
Definition: ntddstor.h:355
LARGE_INTEGER RecoveredReads
Definition: ntddstor.h:357
UCHAR CompressionRatioWrites
Definition: ntddstor.h:360
UCHAR CompressionRatioReads
Definition: ntddstor.h:359
LARGE_INTEGER UnrecoveredWrites
Definition: ntddstor.h:356
#define ANYSIZE_ARRAY
Definition: typedefs.h:46
int64_t LONGLONG
Definition: typedefs.h:68
uint32_t ULONG
Definition: typedefs.h:59
uint64_t ULONGLONG
Definition: typedefs.h:67
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_DEVICE_PROPERTY_DATA _In_ DEVPROPTYPE _In_ ULONG Size
Definition: wdfdevice.h:4533
_Must_inspect_result_ _In_ WDFDEVICE _In_ LPCGUID _Out_ PINTERFACE _In_ USHORT _In_ USHORT Version
Definition: wdffdo.h:469
_Reserved_ PVOID Reserved
Definition: winddi.h:3974
_In_opt_ PUNICODE_STRING _In_ PDRIVER_OBJECT _In_ PDEVICE_OBJECT _In_ INTERFACE_TYPE BusType
Definition: halfuncs.h:159
unsigned char UCHAR
Definition: xmlstorage.h:181