Mercurial > games > semicongine
comparison fuhtark_test/include/winapi/ntddscsi.h @ 1500:91c8c3b7cbf0
add: futhark tests for generating vulkan api
| author | sam <sam@basx.dev> |
|---|---|
| date | Wed, 26 Nov 2025 21:36:48 +0700 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| 1499:1f58458b7ef7 | 1500:91c8c3b7cbf0 |
|---|---|
| 1 /** | |
| 2 * This file has no copyright assigned and is placed in the Public Domain. | |
| 3 * This file is part of the w64 mingw-runtime package. | |
| 4 * No warranty is given; refer to the file DISCLAIMER within this package. | |
| 5 */ | |
| 6 #ifdef DEFINE_GUID | |
| 7 | |
| 8 #ifndef FAR | |
| 9 #define FAR | |
| 10 #endif | |
| 11 | |
| 12 DEFINE_GUID(ScsiRawInterfaceGuid,0x53f56309L,0xb6bf,0x11d0,0x94,0xf2,0x00,0xa0,0xc9,0x1e,0xfb,0x8b); | |
| 13 DEFINE_GUID(WmiScsiAddressGuid,0x53f5630fL,0xb6bf,0x11d0,0x94,0xf2,0x00,0xa0,0xc9,0x1e,0xfb,0x8b); | |
| 14 #endif | |
| 15 | |
| 16 #ifndef _NTDDSCSIH_ | |
| 17 #define _NTDDSCSIH_ | |
| 18 | |
| 19 #ifdef __cplusplus | |
| 20 extern "C" { | |
| 21 #endif | |
| 22 | |
| 23 #define IOCTL_SCSI_BASE FILE_DEVICE_CONTROLLER | |
| 24 | |
| 25 #define DD_SCSI_DEVICE_NAME "\\Device\\ScsiPort" | |
| 26 | |
| 27 #define IOCTL_SCSI_PASS_THROUGH CTL_CODE(IOCTL_SCSI_BASE,0x0401,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) | |
| 28 #define IOCTL_SCSI_MINIPORT CTL_CODE(IOCTL_SCSI_BASE,0x0402,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) | |
| 29 #define IOCTL_SCSI_GET_INQUIRY_DATA CTL_CODE(IOCTL_SCSI_BASE,0x0403,METHOD_BUFFERED,FILE_ANY_ACCESS) | |
| 30 #define IOCTL_SCSI_GET_CAPABILITIES CTL_CODE(IOCTL_SCSI_BASE,0x0404,METHOD_BUFFERED,FILE_ANY_ACCESS) | |
| 31 #define IOCTL_SCSI_PASS_THROUGH_DIRECT CTL_CODE(IOCTL_SCSI_BASE,0x0405,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) | |
| 32 #define IOCTL_SCSI_GET_ADDRESS CTL_CODE(IOCTL_SCSI_BASE,0x0406,METHOD_BUFFERED,FILE_ANY_ACCESS) | |
| 33 #define IOCTL_SCSI_RESCAN_BUS CTL_CODE(IOCTL_SCSI_BASE,0x0407,METHOD_BUFFERED,FILE_ANY_ACCESS) | |
| 34 #define IOCTL_SCSI_GET_DUMP_POINTERS CTL_CODE(IOCTL_SCSI_BASE,0x0408,METHOD_BUFFERED,FILE_ANY_ACCESS) | |
| 35 #define IOCTL_SCSI_FREE_DUMP_POINTERS CTL_CODE(IOCTL_SCSI_BASE,0x0409,METHOD_BUFFERED,FILE_ANY_ACCESS) | |
| 36 #define IOCTL_IDE_PASS_THROUGH CTL_CODE(IOCTL_SCSI_BASE,0x040a,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) | |
| 37 #define IOCTL_ATA_PASS_THROUGH CTL_CODE(IOCTL_SCSI_BASE,0x040b,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) | |
| 38 #define IOCTL_ATA_PASS_THROUGH_DIRECT CTL_CODE(IOCTL_SCSI_BASE,0x040c,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) | |
| 39 | |
| 40 typedef struct _SCSI_PASS_THROUGH { | |
| 41 USHORT Length; | |
| 42 UCHAR ScsiStatus; | |
| 43 UCHAR PathId; | |
| 44 UCHAR TargetId; | |
| 45 UCHAR Lun; | |
| 46 UCHAR CdbLength; | |
| 47 UCHAR SenseInfoLength; | |
| 48 UCHAR DataIn; | |
| 49 ULONG DataTransferLength; | |
| 50 ULONG TimeOutValue; | |
| 51 ULONG_PTR DataBufferOffset; | |
| 52 ULONG SenseInfoOffset; | |
| 53 UCHAR Cdb[16]; | |
| 54 }SCSI_PASS_THROUGH,*PSCSI_PASS_THROUGH; | |
| 55 | |
| 56 typedef struct _SCSI_PASS_THROUGH_DIRECT { | |
| 57 USHORT Length; | |
| 58 UCHAR ScsiStatus; | |
| 59 UCHAR PathId; | |
| 60 UCHAR TargetId; | |
| 61 UCHAR Lun; | |
| 62 UCHAR CdbLength; | |
| 63 UCHAR SenseInfoLength; | |
| 64 UCHAR DataIn; | |
| 65 ULONG DataTransferLength; | |
| 66 ULONG TimeOutValue; | |
| 67 PVOID DataBuffer; | |
| 68 ULONG SenseInfoOffset; | |
| 69 UCHAR Cdb[16]; | |
| 70 }SCSI_PASS_THROUGH_DIRECT,*PSCSI_PASS_THROUGH_DIRECT; | |
| 71 | |
| 72 #if defined(_WIN64) | |
| 73 typedef struct _SCSI_PASS_THROUGH32 { | |
| 74 USHORT Length; | |
| 75 UCHAR ScsiStatus; | |
| 76 UCHAR PathId; | |
| 77 UCHAR TargetId; | |
| 78 UCHAR Lun; | |
| 79 UCHAR CdbLength; | |
| 80 UCHAR SenseInfoLength; | |
| 81 UCHAR DataIn; | |
| 82 ULONG DataTransferLength; | |
| 83 ULONG TimeOutValue; | |
| 84 ULONG32 DataBufferOffset; | |
| 85 ULONG SenseInfoOffset; | |
| 86 UCHAR Cdb[16]; | |
| 87 } SCSI_PASS_THROUGH32,*PSCSI_PASS_THROUGH32; | |
| 88 | |
| 89 typedef struct _SCSI_PASS_THROUGH_DIRECT32 { | |
| 90 USHORT Length; | |
| 91 UCHAR ScsiStatus; | |
| 92 UCHAR PathId; | |
| 93 UCHAR TargetId; | |
| 94 UCHAR Lun; | |
| 95 UCHAR CdbLength; | |
| 96 UCHAR SenseInfoLength; | |
| 97 UCHAR DataIn; | |
| 98 ULONG DataTransferLength; | |
| 99 ULONG TimeOutValue; | |
| 100 VOID *DataBuffer; | |
| 101 ULONG SenseInfoOffset; | |
| 102 UCHAR Cdb[16]; | |
| 103 } SCSI_PASS_THROUGH_DIRECT32,*PSCSI_PASS_THROUGH_DIRECT32; | |
| 104 #endif | |
| 105 | |
| 106 typedef struct _ATA_PASS_THROUGH_EX { | |
| 107 USHORT Length; | |
| 108 USHORT AtaFlags; | |
| 109 UCHAR PathId; | |
| 110 UCHAR TargetId; | |
| 111 UCHAR Lun; | |
| 112 UCHAR ReservedAsUchar; | |
| 113 ULONG DataTransferLength; | |
| 114 ULONG TimeOutValue; | |
| 115 ULONG ReservedAsUlong; | |
| 116 ULONG_PTR DataBufferOffset; | |
| 117 UCHAR PreviousTaskFile[8]; | |
| 118 UCHAR CurrentTaskFile[8]; | |
| 119 } ATA_PASS_THROUGH_EX,*PATA_PASS_THROUGH_EX; | |
| 120 | |
| 121 typedef struct _ATA_PASS_THROUGH_DIRECT { | |
| 122 USHORT Length; | |
| 123 USHORT AtaFlags; | |
| 124 UCHAR PathId; | |
| 125 UCHAR TargetId; | |
| 126 UCHAR Lun; | |
| 127 UCHAR ReservedAsUchar; | |
| 128 ULONG DataTransferLength; | |
| 129 ULONG TimeOutValue; | |
| 130 ULONG ReservedAsUlong; | |
| 131 PVOID DataBuffer; | |
| 132 UCHAR PreviousTaskFile[8]; | |
| 133 UCHAR CurrentTaskFile[8]; | |
| 134 } ATA_PASS_THROUGH_DIRECT,*PATA_PASS_THROUGH_DIRECT; | |
| 135 | |
| 136 #if defined(_WIN64) | |
| 137 | |
| 138 typedef struct _ATA_PASS_THROUGH_EX32 { | |
| 139 USHORT Length; | |
| 140 USHORT AtaFlags; | |
| 141 UCHAR PathId; | |
| 142 UCHAR TargetId; | |
| 143 UCHAR Lun; | |
| 144 UCHAR ReservedAsUchar; | |
| 145 ULONG DataTransferLength; | |
| 146 ULONG TimeOutValue; | |
| 147 ULONG ReservedAsUlong; | |
| 148 ULONG32 DataBufferOffset; | |
| 149 UCHAR PreviousTaskFile[8]; | |
| 150 UCHAR CurrentTaskFile[8]; | |
| 151 } ATA_PASS_THROUGH_EX32,*PATA_PASS_THROUGH_EX32; | |
| 152 | |
| 153 typedef struct _ATA_PASS_THROUGH_DIRECT32 { | |
| 154 USHORT Length; | |
| 155 USHORT AtaFlags; | |
| 156 UCHAR PathId; | |
| 157 UCHAR TargetId; | |
| 158 UCHAR Lun; | |
| 159 UCHAR ReservedAsUchar; | |
| 160 ULONG DataTransferLength; | |
| 161 ULONG TimeOutValue; | |
| 162 ULONG ReservedAsUlong; | |
| 163 VOID *DataBuffer; | |
| 164 UCHAR PreviousTaskFile[8]; | |
| 165 UCHAR CurrentTaskFile[8]; | |
| 166 } ATA_PASS_THROUGH_DIRECT32,*PATA_PASS_THROUGH_DIRECT32; | |
| 167 #endif | |
| 168 | |
| 169 #define ATA_FLAGS_DRDY_REQUIRED (1 << 0) | |
| 170 #define ATA_FLAGS_DATA_IN (1 << 1) | |
| 171 #define ATA_FLAGS_DATA_OUT (1 << 2) | |
| 172 #define ATA_FLAGS_48BIT_COMMAND (1 << 3) | |
| 173 #define ATA_FLAGS_USE_DMA (1 << 4) | |
| 174 | |
| 175 typedef struct _SCSI_BUS_DATA { | |
| 176 UCHAR NumberOfLogicalUnits; | |
| 177 UCHAR InitiatorBusId; | |
| 178 ULONG InquiryDataOffset; | |
| 179 }SCSI_BUS_DATA,*PSCSI_BUS_DATA; | |
| 180 | |
| 181 typedef struct _SCSI_ADAPTER_BUS_INFO { | |
| 182 UCHAR NumberOfBuses; | |
| 183 SCSI_BUS_DATA BusData[1]; | |
| 184 } SCSI_ADAPTER_BUS_INFO,*PSCSI_ADAPTER_BUS_INFO; | |
| 185 | |
| 186 typedef struct _SCSI_INQUIRY_DATA { | |
| 187 UCHAR PathId; | |
| 188 UCHAR TargetId; | |
| 189 UCHAR Lun; | |
| 190 BOOLEAN DeviceClaimed; | |
| 191 ULONG InquiryDataLength; | |
| 192 ULONG NextInquiryDataOffset; | |
| 193 UCHAR InquiryData[1]; | |
| 194 }SCSI_INQUIRY_DATA,*PSCSI_INQUIRY_DATA; | |
| 195 | |
| 196 typedef struct _SRB_IO_CONTROL { | |
| 197 ULONG HeaderLength; | |
| 198 UCHAR Signature[8]; | |
| 199 ULONG Timeout; | |
| 200 ULONG ControlCode; | |
| 201 ULONG ReturnCode; | |
| 202 ULONG Length; | |
| 203 } SRB_IO_CONTROL,*PSRB_IO_CONTROL; | |
| 204 | |
| 205 typedef struct _IO_SCSI_CAPABILITIES { | |
| 206 ULONG Length; | |
| 207 ULONG MaximumTransferLength; | |
| 208 ULONG MaximumPhysicalPages; | |
| 209 ULONG SupportedAsynchronousEvents; | |
| 210 ULONG AlignmentMask; | |
| 211 BOOLEAN TaggedQueuing; | |
| 212 BOOLEAN AdapterScansDown; | |
| 213 BOOLEAN AdapterUsesPio; | |
| 214 } IO_SCSI_CAPABILITIES,*PIO_SCSI_CAPABILITIES; | |
| 215 | |
| 216 typedef struct _SCSI_ADDRESS { | |
| 217 ULONG Length; | |
| 218 UCHAR PortNumber; | |
| 219 UCHAR PathId; | |
| 220 UCHAR TargetId; | |
| 221 UCHAR Lun; | |
| 222 } SCSI_ADDRESS,*PSCSI_ADDRESS; | |
| 223 | |
| 224 struct _ADAPTER_OBJECT; | |
| 225 | |
| 226 typedef struct _DUMP_POINTERS { | |
| 227 struct _ADAPTER_OBJECT *AdapterObject; | |
| 228 PVOID MappedRegisterBase; | |
| 229 PVOID DumpData; | |
| 230 PVOID CommonBufferVa; | |
| 231 LARGE_INTEGER CommonBufferPa; | |
| 232 ULONG CommonBufferSize; | |
| 233 BOOLEAN AllocateCommonBuffers; | |
| 234 BOOLEAN UseDiskDump; | |
| 235 UCHAR Spare1[2]; | |
| 236 PVOID DeviceObject; | |
| 237 } DUMP_POINTERS,*PDUMP_POINTERS; | |
| 238 | |
| 239 #define SCSI_IOCTL_DATA_OUT 0 | |
| 240 #define SCSI_IOCTL_DATA_IN 1 | |
| 241 #define SCSI_IOCTL_DATA_UNSPECIFIED 2 | |
| 242 | |
| 243 #ifdef __cplusplus | |
| 244 } | |
| 245 #endif | |
| 246 #endif |
