Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

513 lines
18 KiB

  1. #ifndef __NTDDMMC__
  2. #define __NTDDMMC__
  3. #if _MSC_VER >= 1200
  4. #pragma warning(push)
  5. #endif
  6. #pragma warning(disable:4200) // array[0] is not a warning for this file
  7. //
  8. // NOTE: All FEATURE_* structures may be extended. use of these structures
  9. // requires verification that the FeatureHeader->AdditionLength field
  10. // contains AT LEAST enough data to cover the data fields being accessed.
  11. // This is due to the design, which allows extending the size of the
  12. // various structures, which will result in these structures sizes
  13. // being changed over time.
  14. // *** Programmers beware! ***
  15. //
  16. //
  17. // NOTE: This is based on MMC 3
  18. // Further revisions will maintain backward compatibility
  19. // with the non-reserved fields listed here. If you need
  20. // to access a new field, please typecast to FEATURE_DATA_RESERVED
  21. // and access the appropriate bits there.
  22. //
  23. typedef struct _GET_CONFIGURATION_HEADER {
  24. UCHAR DataLength[4]; // [0] == MSB, [3] == LSB
  25. UCHAR Reserved[2];
  26. UCHAR CurrentProfile[2]; // [0] == MSB, [1] == LSB
  27. UCHAR Data[0]; // extra data, typically FEATURE_HEADER
  28. } GET_CONFIGURATION_HEADER, *PGET_CONFIGURATION_HEADER;
  29. typedef struct _FEATURE_HEADER {
  30. UCHAR FeatureCode[2]; // [0] == MSB, [1] == LSB
  31. UCHAR Current : 1; // The feature is currently active
  32. UCHAR Persistent : 1; // The feature is always current
  33. UCHAR Version : 4;
  34. UCHAR Reserved0 : 2;
  35. UCHAR AdditionalLength; // sizeof(Header) + AdditionalLength = size
  36. } FEATURE_HEADER, *PFEATURE_HEADER;
  37. typedef enum _FEATURE_PROFILE_TYPE {
  38. ProfileInvalid = 0x0000,
  39. ProfileNonRemovableDisk = 0x0001,
  40. ProfileRemovableDisk = 0x0002,
  41. ProfileMOErasable = 0x0003,
  42. ProfileMOWriteOnce = 0x0004,
  43. ProfileAS_MO = 0x0005,
  44. // Reserved 0x0006 - 0x0007
  45. ProfileCdrom = 0x0008,
  46. ProfileCdRecordable = 0x0009,
  47. ProfileCdRewritable = 0x000a,
  48. // Reserved 0x000b - 0x000f
  49. ProfileDvdRom = 0x0010,
  50. ProfileDvdRecordable = 0x0011,
  51. ProfileDvdRam = 0x0012,
  52. ProfileDvdRewritable = 0x0013, // restricted overwrite
  53. ProfileDvdRWSequential = 0x0014,
  54. // Reserved 0x0014 - 0x0019
  55. ProfileDvdPlusRW = 0x001A,
  56. // Reserved 0x001B - 001F
  57. ProfileDDCdrom = 0x0020,
  58. ProfileDDCdRecordable = 0x0021,
  59. ProfileDDCdRewritable = 0x0022,
  60. // Reserved 0x0023 - 0xfffe
  61. ProfileNonStandard = 0xffff
  62. } FEATURE_PROFILE_TYPE, *PFEATURE_PROFILE_TYPE;
  63. typedef enum _FEATURE_NUMBER {
  64. FeatureProfileList = 0x0000,
  65. FeatureCore = 0x0001,
  66. FeatureMorphing = 0x0002,
  67. FeatureRemovableMedium = 0x0003,
  68. FeatureWriteProtect = 0x0004,
  69. // Reserved 0x0005 - 0x000f
  70. FeatureRandomReadable = 0x0010,
  71. // Reserved 0x0011 - 0x001c
  72. FeatureMultiRead = 0x001d,
  73. FeatureCdRead = 0x001e,
  74. FeatureDvdRead = 0x001f,
  75. FeatureRandomWritable = 0x0020,
  76. FeatureIncrementalStreamingWritable = 0x0021,
  77. FeatureSectorErasable = 0x0022,
  78. FeatureFormattable = 0x0023,
  79. FeatureDefectManagement = 0x0024,
  80. FeatureWriteOnce = 0x0025,
  81. FeatureRestrictedOverwrite = 0x0026,
  82. FeatureCdrwCAVWrite = 0x0027,
  83. FeatureMrw = 0x0028,
  84. // Reserved 0x0029
  85. FeatureDvdPlusRW = 0x002A,
  86. // Reserved 0x002b
  87. FeatureRigidRestrictedOverwrite = 0x002c,
  88. FeatureCdTrackAtOnce = 0x002d,
  89. FeatureCdMastering = 0x002e,
  90. FeatureDvdRecordableWrite = 0x002f, // both -R and -RW
  91. FeatureDDCDRead = 0x0030,
  92. FeatureDDCDRWrite = 0x0031,
  93. FeatureDDCDRWWrite = 0x0032,
  94. // Reserved 0x0033 - 0x00ff
  95. FeaturePowerManagement = 0x0100,
  96. FeatureSMART = 0x0101,
  97. FeatureEmbeddedChanger = 0x0102,
  98. FeatureCDAudioAnalogPlay = 0x0103,
  99. FeatureMicrocodeUpgrade = 0x0104,
  100. FeatureTimeout = 0x0105,
  101. FeatureDvdCSS = 0x0106,
  102. FeatureRealTimeStreaming = 0x0107,
  103. FeatureLogicalUnitSerialNumber = 0x0108,
  104. // Reserved 0x0109
  105. FeatureDiscControlBlocks = 0x010a,
  106. FeatureDvdCPRM = 0x010b
  107. // Reserved 0x010c - 0xfeff
  108. // Vendor Unique 0xff00 - 0xffff
  109. } FEATURE_NUMBER, *PFEATURE_NUMBER;
  110. // 0x0000 - FeatureProfileList
  111. // an integral multiple of the _EX structures are returned for page 0000
  112. typedef struct _FEATURE_DATA_PROFILE_LIST_EX {
  113. UCHAR ProfileNumber[2]; // [0] == MSB, [1] == LSB
  114. UCHAR Current : 1;
  115. UCHAR Reserved1 : 7;
  116. UCHAR Reserved2;
  117. } FEATURE_DATA_PROFILE_LIST_EX, *PFEATURE_DATA_PROFILE_LIST_EX;
  118. typedef struct _FEATURE_DATA_PROFILE_LIST {
  119. FEATURE_HEADER Header;
  120. FEATURE_DATA_PROFILE_LIST_EX Profiles[0];
  121. } FEATURE_DATA_PROFILE_LIST, *PFEATURE_DATA_PROFILE_LIST;
  122. // 0x0001 - FeatureCore
  123. typedef struct _FEATURE_DATA_CORE {
  124. FEATURE_HEADER Header;
  125. UCHAR PhysicalInterface[4]; // [0] == MSB, [3] == LSB
  126. } FEATURE_DATA_CORE, *PFEATURE_DATA_CORE;
  127. // 0x0002 - FeatureMorphing
  128. typedef struct _FEATURE_DATA_MORPHING {
  129. FEATURE_HEADER Header;
  130. UCHAR Asynchronous : 1;
  131. UCHAR Reserved1 : 7;
  132. UCHAR Reserved2[3];
  133. } FEATURE_DATA_MORPHING, *PFEATURE_DATA_MORPHING;
  134. // 0x0003 - FeatureRemovableMedium
  135. typedef struct _FEATURE_DATA_REMOVABLE_MEDIUM {
  136. FEATURE_HEADER Header;
  137. UCHAR Lockable : 1;
  138. UCHAR Reserved1 : 1;
  139. UCHAR DefaultToPrevent : 1;
  140. UCHAR Eject : 1;
  141. UCHAR Reserved2 : 1;
  142. UCHAR LoadingMechanism : 3;
  143. UCHAR Reserved3[3];
  144. } FEATURE_DATA_REMOVABLE_MEDIUM, *PFEATURE_DATA_REMOVABLE_MEDIUM;
  145. // 0x0004 - FeatureWriteProtect
  146. typedef struct _FEATURE_DATA_WRITE_PROTECT {
  147. FEATURE_HEADER Header;
  148. UCHAR SupportsSWPPBit : 1;
  149. UCHAR SupportsPersistentWriteProtect : 1;
  150. UCHAR Reserved1 : 6;
  151. UCHAR Reserved2[3];
  152. } FEATURE_DATA_WRITE_PROTECT, *PFEATURE_DATA_WRITE_PROTECT;
  153. // 0x0005 - 0x000f are Reserved
  154. // 0x0010 - FeatureRandomReadable
  155. typedef struct _FEATURE_DATA_RANDOM_READABLE {
  156. FEATURE_HEADER Header;
  157. UCHAR LogicalBlockSize[4];
  158. UCHAR Blocking[2];
  159. UCHAR ErrorRecoveryPagePresent : 1;
  160. UCHAR Reserved1 : 7;
  161. UCHAR Reserved2;
  162. } FEATURE_DATA_RANDOM_READABLE, *PFEATURE_DATA_RANDOM_READABLE;
  163. // 0x0011 - 0x001c are Reserved
  164. // 0x001d - FeatureMultiRead
  165. typedef struct _FEATURE_DATA_MULTI_READ {
  166. FEATURE_HEADER Header;
  167. } FEATURE_DATA_MULTI_READ, *PFEATURE_DATA_MULTI_READ;
  168. // 0x001e - FeatureCdRead
  169. typedef struct _FEATURE_DATA_CD_READ {
  170. FEATURE_HEADER Header;
  171. UCHAR CDText : 1;
  172. UCHAR C2ErrorData : 1;
  173. UCHAR Reserved1 : 6;
  174. UCHAR Reserved2[3];
  175. } FEATURE_DATA_CD_READ, *PFEATURE_DATA_CD_READ;
  176. // 0x001f - FeatureDvdRead
  177. typedef struct _FEATURE_DATA_DVD_READ {
  178. FEATURE_HEADER Header;
  179. } FEATURE_DATA_DVD_READ, *PFEATURE_DATA_DVD_READ;
  180. // 0x0020 - FeatureRandomWritable
  181. typedef struct _FEATURE_DATA_RANDOM_WRITABLE {
  182. FEATURE_HEADER Header;
  183. UCHAR LastLBA[4];
  184. UCHAR LogicalBlockSize[4];
  185. UCHAR Blocking[2];
  186. UCHAR ErrorRecoveryPagePresent : 1;
  187. UCHAR Reserved1 : 7;
  188. UCHAR Reserved2;
  189. } FEATURE_DATA_RANDOM_WRITABLE, *PFEATURE_DATA_RANDOM_WRITABLE;
  190. // 0x0021 - FeatureIncrementalStreamingWritable
  191. typedef struct _FEATURE_DATA_INCREMENTAL_STREAMING_WRITABLE {
  192. FEATURE_HEADER Header;
  193. UCHAR DataTypeSupported[2]; // [0] == MSB, [1] == LSB // see also FeatureCdTrackAtOnce
  194. UCHAR BufferUnderrunFree : 1;
  195. UCHAR Reserved1 : 7;
  196. UCHAR NumberOfLinkSizes;
  197. UCHAR LinkSize[0];
  198. } FEATURE_DATA_INCREMENTAL_STREAMING_WRITABLE, *PFEATURE_DATA_INCREMENTAL_STREAMING_WRITABLE;
  199. // 0x0022 - FeatureSectorErasable
  200. typedef struct _FEATURE_DATA_SECTOR_ERASABLE {
  201. FEATURE_HEADER Header;
  202. } FEATURE_DATA_SECTOR_ERASABLE, *PFEATURE_DATA_SECTOR_ERASABLE;
  203. // 0x0023 - FeatureFormattable
  204. typedef struct _FEATURE_DATA_FORMATTABLE {
  205. FEATURE_HEADER Header;
  206. } FEATURE_DATA_FORMATTABLE, *PFEATURE_DATA_FORMATTABLE;
  207. // 0x0024 - FeatureDefectManagement
  208. typedef struct _FEATURE_DATA_DEFECT_MANAGEMENT {
  209. FEATURE_HEADER Header;
  210. UCHAR Reserved1 : 7;
  211. UCHAR SupplimentalSpareArea : 1;
  212. UCHAR Reserved2[3];
  213. } FEATURE_DATA_DEFECT_MANAGEMENT, *PFEATURE_DATA_DEFECT_MANAGEMENT;
  214. // 0x0025 - FeatureWriteOnce
  215. typedef struct _FEATURE_DATA_WRITE_ONCE {
  216. FEATURE_HEADER Header;
  217. UCHAR LogicalBlockSize[4];
  218. UCHAR Blocking[2];
  219. UCHAR ErrorRecoveryPagePresent : 1;
  220. UCHAR Reserved1 : 7;
  221. UCHAR Reserved2;
  222. } FEATURE_DATA_WRITE_ONCE, *PFEATURE_DATA_WRITE_ONCE;
  223. // 0x0026 - FeatureRestrictedOverwrite
  224. typedef struct _FEATURE_DATA_RESTRICTED_OVERWRITE {
  225. FEATURE_HEADER Header;
  226. } FEATURE_DATA_RESTRICTED_OVERWRITE, *PFEATURE_DATA_RESTRICTED_OVERWRITE;
  227. // 0x0027 - FeatureCdrwCAVWrite
  228. typedef struct _FEATURE_DATA_CDRW_CAV_WRITE {
  229. FEATURE_HEADER Header;
  230. UCHAR Reserved1[4];
  231. } FEATURE_DATA_CDRW_CAV_WRITE, *PFEATURE_DATA_CDRW_CAV_WRITE;
  232. // 0x0028 - FeatureMrw
  233. typedef struct _FEATURE_DATA_MRW {
  234. FEATURE_HEADER Header;
  235. UCHAR Write : 1;
  236. UCHAR Reserved1 : 7;
  237. UCHAR Reserved2[3];
  238. } FEATURE_DATA_MRW, *PFEATURE_DATA_MRW;
  239. // 0x0029 is Reserved
  240. // 0x002A - FeatureDvdPlusRW
  241. typedef struct _FEATURE_DATA_DVD_PLUS_RW {
  242. FEATURE_HEADER Header;
  243. UCHAR Write : 1;
  244. UCHAR Reserved1 : 7;
  245. UCHAR Reserved2[3];
  246. } FEATURE_DATA_DVD_PLUS_RW, *PFEATURE_DATA_DVD_PLUS_RW;
  247. // 0x002b is Reserved
  248. // 0x002c - FeatureDvdRwRestrictedOverwrite
  249. typedef struct _FEATURE_DATA_DVD_RW_RESTRICTED_OVERWRITE {
  250. FEATURE_HEADER Header;
  251. UCHAR Blank : 1;
  252. UCHAR Intermediate : 1;
  253. UCHAR DefectStatusDataRead : 1;
  254. UCHAR DefectStatusDataGenerate : 1;
  255. UCHAR Reserved0 : 4;
  256. UCHAR Reserved1[3];
  257. } FEATURE_DATA_DVD_RW_RESTRICTED_OVERWRITE, *PFEATURE_DATA_DVD_RW_RESTRICTED_OVERWRITE;
  258. // 0x002d - FeatureCdTrackAtOnce
  259. typedef struct _FEATURE_DATA_CD_TRACK_AT_ONCE {
  260. FEATURE_HEADER Header;
  261. UCHAR RWSubchannelsRecordable : 1;
  262. UCHAR CdRewritable : 1;
  263. UCHAR TestWriteOk : 1;
  264. UCHAR RWSubchannelPackedOk : 1; // MMC 3 +
  265. UCHAR RWSubchannelRawOk : 1; // MMC 3 +
  266. UCHAR Reserved1 : 1;
  267. UCHAR BufferUnderrunFree : 1; // MMC 3 +
  268. UCHAR Reserved3 : 1;
  269. UCHAR Reserved2;
  270. UCHAR DataTypeSupported[2]; // [0] == MSB, [1] == LSB // see also FeatureIncrementalStreamingWritable
  271. } FEATURE_DATA_CD_TRACK_AT_ONCE, *PFEATURE_DATA_CD_TRACK_AT_ONCE;
  272. // 0x002e - FeatureCdMastering
  273. typedef struct _FEATURE_DATA_CD_MASTERING {
  274. FEATURE_HEADER Header;
  275. UCHAR RWSubchannelsRecordable : 1;
  276. UCHAR CdRewritable : 1;
  277. UCHAR TestWriteOk : 1;
  278. UCHAR RawRecordingOk : 1;
  279. UCHAR RawMultiSessionOk : 1;
  280. UCHAR SessionAtOnceOk : 1;
  281. UCHAR BufferUnderrunFree : 1;
  282. UCHAR Reserved1 : 1;
  283. UCHAR MaximumCueSheetLength[3]; // [0] == MSB, [2] == LSB
  284. } FEATURE_DATA_CD_MASTERING, *PFEATURE_DATA_CD_MASTERING;
  285. // 0x002f - FeatureDvdRecordableWrite
  286. typedef struct _FEATURE_DATA_DVD_RECORDABLE_WRITE {
  287. FEATURE_HEADER Header;
  288. UCHAR Reserved1 : 1;
  289. UCHAR DVD_RW : 1;
  290. UCHAR TestWrite : 1;
  291. UCHAR Reserved2 : 3;
  292. UCHAR BufferUnderrunFree : 1;
  293. UCHAR Reserved3 : 1;
  294. UCHAR Reserved4[3];
  295. } FEATURE_DATA_DVD_RECORDABLE_WRITE, *PFEATURE_DATA_DVD_RECORDABLE_WRITE;
  296. // 0x0030 - FeatureDDCDRead
  297. typedef struct _FEATURE_DATA_DDCD_READ {
  298. FEATURE_HEADER Header;
  299. } FEATURE_DATA_DDCD_READ, *PFEATURE_DATA_DDCD_READ;
  300. // 0x0031 - FeatureDDCDRWrite
  301. typedef struct _FEATURE_DATA_DDCD_R_WRITE {
  302. FEATURE_HEADER Header;
  303. UCHAR Reserved1 : 2;
  304. UCHAR TestWrite : 1;
  305. UCHAR Reserved2 : 5;
  306. UCHAR Reserved3[3];
  307. } FEATURE_DATA_DDCD_R_WRITE, *PFEATURE_DATA_DDCD_R_WRITE;
  308. // 0x0032 - FeatureDDCDRWWrite
  309. typedef struct _FEATURE_DATA_DDCD_RW_WRITE {
  310. FEATURE_HEADER Header;
  311. UCHAR Blank : 1;
  312. UCHAR Intermediate : 1;
  313. UCHAR Reserved1 : 6;
  314. UCHAR Reserved2[3];
  315. } FEATURE_DATA_DDCD_RW_WRITE, *PFEATURE_DATA_DDCD_RW_WRITE;
  316. // 0x0033 - 0x00ff are Reserved
  317. // 0x0100 - FeaturePowerManagement
  318. typedef struct _FEATURE_DATA_POWER_MANAGEMENT {
  319. FEATURE_HEADER Header;
  320. } FEATURE_DATA_POWER_MANAGEMENT, *PFEATURE_DATA_POWER_MANAGEMENT;
  321. // 0x0101 - FeatureSMART (not in MMC 2)
  322. typedef struct _FEATURE_DATA_SMART {
  323. FEATURE_HEADER Header;
  324. UCHAR FaultFailureReportingPagePresent : 1;
  325. UCHAR Reserved1 : 7;
  326. UCHAR Reserved2;
  327. } FEATURE_DATA_SMART, *PFEATURE_DATA_SMART;
  328. // 0x0102 - FeatureEmbeddedChanger
  329. typedef struct _FEATURE_DATA_EMBEDDED_CHANGER {
  330. FEATURE_HEADER Header;
  331. UCHAR Reserved1 : 2;
  332. UCHAR SupportsDiscPresent : 1;
  333. UCHAR Reserved2 : 1;
  334. UCHAR SideChangeCapable : 1;
  335. UCHAR Reserved3 : 3;
  336. UCHAR Reserved4[2];
  337. UCHAR HighestSlotNumber : 5;
  338. UCHAR Reserved : 3;
  339. } FEATURE_DATA_EMBEDDED_CHANGER, *PFEATURE_DATA_EMBEDDED_CHANGER;
  340. // 0x0103 - FeatureCDAudioAnalogPlay
  341. typedef struct _FEATURE_DATA_CD_AUDIO_ANALOG_PLAY {
  342. FEATURE_HEADER Header;
  343. UCHAR SeperateVolume : 1;
  344. UCHAR SeperateChannelMute : 1;
  345. UCHAR ScanSupported : 1;
  346. UCHAR Reserved1 : 5;
  347. UCHAR Reserved2;
  348. UCHAR NumerOfVolumeLevels[2]; // [0] == MSB, [1] == LSB
  349. } FEATURE_DATA_CD_AUDIO_ANALOG_PLAY, *PFEATURE_DATA_CD_AUDIO_ANALOG_PLAY;
  350. // 0x0104 - FeatureMicrocodeUpgrade
  351. typedef struct _FEATURE_DATA_MICROCODE_UPDATE {
  352. FEATURE_HEADER Header;
  353. } FEATURE_DATA_MICROCODE_UPDATE, *PFEATURE_DATA_MICROCODE_UPDATE;
  354. // 0x0105 - FeatureTimeout
  355. typedef struct _FEATURE_DATA_TIMEOUT {
  356. FEATURE_HEADER Header;
  357. } FEATURE_DATA_TIMEOUT, *PFEATURE_DATA_TIMEOUT;
  358. // 0x0106 - FeatureDvdCSS
  359. typedef struct _FEATURE_DATA_DVD_CSS {
  360. FEATURE_HEADER Header;
  361. UCHAR Reserved1[3];
  362. UCHAR CssVersion;
  363. } FEATURE_DATA_DVD_CSS, *PFEATURE_DATA_DVD_CSS;
  364. // 0x0107 - FeatureRealTimeStreaming
  365. typedef struct _FEATURE_DATA_REAL_TIME_STREAMING {
  366. FEATURE_HEADER Header;
  367. UCHAR StreamRecording : 1;
  368. UCHAR WriteSpeedInGetPerf : 1;
  369. UCHAR WriteSpeedInMP2A : 1;
  370. UCHAR SetCDSpeed : 1;
  371. UCHAR ReadBufferCapacityBlock : 1;
  372. UCHAR Reserved1 : 3;
  373. UCHAR Reserved2[3];
  374. } FEATURE_DATA_REAL_TIME_STREAMING, *PFEATURE_DATA_REAL_TIME_STREAMING;
  375. // 0x0108 - FeatureLogicalUnitSerialNumber
  376. typedef struct _FEATURE_DATA_LOGICAL_UNIT_SERIAL_NUMBER {
  377. FEATURE_HEADER Header;
  378. UCHAR SerialNumber[0];
  379. } FEATURE_DATA_LOGICAL_UNIT_SERIAL_NUMBER, *PFEATURE_DATA_LOGICAL_UNIT_SERIAL_NUMBER;
  380. // 0x0109 is Reserved
  381. // 0x010a
  382. // an integral multiple of the _EX structures are returned for page 010A
  383. typedef struct _FEATURE_DATA_DISC_CONTROL_BLOCKS_EX {
  384. UCHAR ContentDescriptor[4];
  385. } FEATURE_DATA_DISC_CONTROL_BLOCKS_EX, *PFEATURE_DATA_DISC_CONTROL_BLOCKS_EX;
  386. // use a zero-sized array for this....
  387. typedef struct _FEATURE_DATA_DISC_CONTROL_BLOCKS {
  388. FEATURE_HEADER Header;
  389. FEATURE_DATA_DISC_CONTROL_BLOCKS_EX Data[0];
  390. } FEATURE_DATA_DISC_CONTROL_BLOCKS, *PFEATURE_DATA_DISC_CONTROL_BLOCKS;
  391. // 0x010b
  392. typedef struct _FEATURE_DATA_DVD_CPRM {
  393. FEATURE_HEADER Header;
  394. UCHAR Reserved0[3];
  395. UCHAR CPRMVersion;
  396. } FEATURE_DATA_DVD_CPRM, *PFEATURE_DATA_DVD_CPRM;
  397. // 0x010c - 0xfeff are Reserved
  398. typedef struct _FEATURE_DATA_RESERVED {
  399. FEATURE_HEADER Header;
  400. UCHAR Data[0];
  401. } FEATURE_DATA_RESERVED, *PFEATURE_DATA_RESERVED;
  402. // 0xff00 - 0xffff are Vendor Specific
  403. typedef struct _FEATURE_DATA_VENDOR_SPECIFIC {
  404. FEATURE_HEADER Header;
  405. UCHAR VendorSpecificData[0];
  406. } FEATURE_DATA_VENDOR_SPECIFIC, *PFEATURE_DATA_VENDOR_SPECIFIC;
  407. //
  408. // NOTE: All FEATURE_* structures may be extended. use of these structures
  409. // requires verification that the FeatureHeader->AdditionLength field
  410. // contains AT LEAST enough data to cover the data fields being accessed.
  411. // This is due to the design, which allows extending the size of the
  412. // various structures, which will result in these structures sizes
  413. // being changed over time.
  414. // *** Programmers beware! ***
  415. //
  416. //
  417. // NOTE: This is based on MMC 3
  418. // Further revisions will maintain backward compatibility
  419. // with the non-reserved fields listed here. If you need
  420. // to access a new field, please typecast to FEATURE_DATA_RESERVED
  421. // and access the appropriate bits there.
  422. //
  423. //
  424. // IOCTL_CDROM_GET_CONFIGURATION returns a FEATURE_* struct, which always
  425. // starts with a FEATURE_HEADER structure.
  426. //
  427. //
  428. // these are to be used for the request type
  429. //
  430. #define SCSI_GET_CONFIGURATION_REQUEST_TYPE_ALL 0x0
  431. #define SCSI_GET_CONFIGURATION_REQUEST_TYPE_CURRENT 0x1
  432. #define SCSI_GET_CONFIGURATION_REQUEST_TYPE_ONE 0x2
  433. typedef struct _GET_CONFIGURATION_IOCTL_INPUT {
  434. FEATURE_NUMBER Feature;
  435. ULONG RequestType; // SCSI_GET_CONFIGURATION_REQUEST_TYPE_*
  436. PVOID Reserved[2];
  437. } GET_CONFIGURATION_IOCTL_INPUT, *PGET_CONFIGURATION_IOCTL_INPUT;
  438. #if _MSC_VER >= 1200
  439. #pragma warning(pop) // un-sets any local warning changes
  440. #endif
  441. #pragma warning(default:4200) // array[0] is not a warning for this file
  442. #endif // __NTDDMMC__