ReactOS 0.4.15-dev-7924-g5949c20
storahci.h
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS Kernel
3 * LICENSE: GNU GPLv2 only as published by the Free Software Foundation
4 * PURPOSE: To Implement AHCI Miniport driver targeting storport NT 5.2
5 * PROGRAMMERS: Aman Priyadarshi (aman.eureka@gmail.com)
6 */
7
8#include <ntddk.h>
9#include <ata.h>
10#include <storport.h>
11
12#define NDEBUG
13#include <debug.h>
14
15#define DEBUG 1
16#if defined(_MSC_VER)
17#pragma warning(disable:4214) // bit field types other than int
18#pragma warning(disable:4201) // nameless struct/union
19#endif
20
21#define MAXIMUM_AHCI_PORT_COUNT 32
22#define MAXIMUM_AHCI_PRDT_ENTRIES 32
23#define MAXIMUM_AHCI_PORT_NCS 30
24#define MAXIMUM_QUEUE_BUFFER_SIZE 255
25#define MAXIMUM_TRANSFER_LENGTH (128*1024) // 128 KB
26
27#define DEVICE_ATA_BLOCK_SIZE 512
28
29// device type (DeviceParams)
30#define AHCI_DEVICE_TYPE_ATA 1
31#define AHCI_DEVICE_TYPE_ATAPI 2
32#define AHCI_DEVICE_TYPE_NODEVICE 3
33
34// section 3.1.2
35#define AHCI_Global_HBA_CAP_S64A (1 << 31)
36
37// FIS Types : http://wiki.osdev.org/AHCI
38#define FIS_TYPE_REG_H2D 0x27 // Register FIS - host to device
39#define FIS_TYPE_REG_D2H 0x34 // Register FIS - device to host
40#define FIS_TYPE_DMA_ACT 0x39 // DMA activate FIS - device to host
41#define FIS_TYPE_DMA_SETUP 0x41 // DMA setup FIS - bidirectional
42#define FIS_TYPE_BIST 0x58 // BIST activate FIS - bidirectional
43#define FIS_TYPE_PIO_SETUP 0x5F // PIO setup FIS - device to host
44#define FIS_TYPE_DEV_BITS 0xA1 // Set device bits FIS - device to host
45
46#define AHCI_ATA_CFIS_FisType 0
47#define AHCI_ATA_CFIS_PMPort_C 1
48#define AHCI_ATA_CFIS_CommandReg 2
49#define AHCI_ATA_CFIS_FeaturesLow 3
50#define AHCI_ATA_CFIS_LBA0 4
51#define AHCI_ATA_CFIS_LBA1 5
52#define AHCI_ATA_CFIS_LBA2 6
53#define AHCI_ATA_CFIS_Device 7
54#define AHCI_ATA_CFIS_LBA3 8
55#define AHCI_ATA_CFIS_LBA4 9
56#define AHCI_ATA_CFIS_LBA5 10
57#define AHCI_ATA_CFIS_FeaturesHigh 11
58#define AHCI_ATA_CFIS_SectorCountLow 12
59#define AHCI_ATA_CFIS_SectorCountHigh 13
60
61// ATA Functions
62#define ATA_FUNCTION_ATA_COMMAND 0x100
63#define ATA_FUNCTION_ATA_IDENTIFY 0x101
64#define ATA_FUNCTION_ATA_READ 0x102
65
66// ATAPI Functions
67#define ATA_FUNCTION_ATAPI_COMMAND 0x200
68
69// ATA Flags
70#define ATA_FLAGS_DATA_IN (1 << 1)
71#define ATA_FLAGS_DATA_OUT (1 << 2)
72#define ATA_FLAGS_48BIT_COMMAND (1 << 3)
73#define ATA_FLAGS_USE_DMA (1 << 4)
74
75#define IsAtaCommand(AtaFunction) (AtaFunction & ATA_FUNCTION_ATA_COMMAND)
76#define IsAtapiCommand(AtaFunction) (AtaFunction & ATA_FUNCTION_ATAPI_COMMAND)
77#define IsDataTransferNeeded(SrbExtension) (SrbExtension->Flags & (ATA_FLAGS_DATA_IN | ATA_FLAGS_DATA_OUT))
78#define IsAdapterCAPS64(CAP) (CAP & AHCI_Global_HBA_CAP_S64A)
79
80// 3.1.1 NCS = CAP[12:08] -> Align
81#define AHCI_Global_Port_CAP_NCS(x) (((x) & 0xF00) >> 8)
82
83#define ROUND_UP(N, S) ((((N) + (S) - 1) / (S)) * (S))
84//#define AhciDebugPrint(format, ...) StorPortDebugPrint(0, format, __VA_ARGS__)
85#define AhciDebugPrint(format, ...) DbgPrint("(%s:%d) " format, __RELFILE__, __LINE__, ##__VA_ARGS__)
86
87typedef
90 __in PVOID PortExtension,
92 );
93
95// ---- Support Structures --- //
97
98// section 3.3.5
100{
101 struct
102 {
103 ULONG DHRS:1; //Device to Host Register FIS Interrupt
104 ULONG PSS :1; //PIO Setup FIS Interrupt
105 ULONG DSS :1; //DMA Setup FIS Interrupt
106 ULONG SDBS :1; //Set Device Bits Interrupt
107 ULONG UFS :1; //Unknown FIS Interrupt
108 ULONG DPS :1; //Descriptor Processed
109 ULONG PCS :1; //Port Connect Change Status
110 ULONG DMPS :1; //Device Mechanical Presence Status (DMPS)
112 ULONG PRCS :1; //PhyRdy Change Status
113 ULONG IPMS :1; //Incorrect Port Multiplier Status
114 ULONG OFS :1; //Overflow Status
116 ULONG INFS :1; //Interface Non-fatal Error Status
117 ULONG IFS :1; //Interface Fatal Error Status
118 ULONG HBDS :1; //Host Bus Data Error Status
119 ULONG HBFS :1; //Host Bus Fatal Error Status
120 ULONG TFES :1; //Task File Error Status
121 ULONG CPDS :1; //Cold Port Detect Status
122 };
123
126
128{
129 ULONG ULONG0_1; // FIS_TYPE_DMA_SETUP
130 // Port multiplier
131 // Reserved
132 // Data transfer direction, 1 - device to host
133 // Interrupt bit
134 // Auto-activate. Specifies if DMA Activate FIS is needed
135 UCHAR Reserved[2]; // Reserved
136 ULONG DmaBufferLow; // DMA Buffer Identifier. Used to Identify DMA buffer in host memory. SATA Spec says host specific and not in Spec. Trying AHCI spec might work.
138 ULONG Reserved2; // More reserved
139 ULONG DmaBufferOffset; // Byte offset into buffer. First 2 bits must be 0
140 ULONG TranferCount; // Number of bytes to transfer. Bit 0 must be 0
141 ULONG Reserved3; // Reserved
143
145{
153
158
163
168
172
174{
181
186
191
195
198
200{
202
207
212
214
217
218typedef struct _AHCI_QUEUE
219{
220 PVOID Buffer[MAXIMUM_QUEUE_BUFFER_SIZE]; // because Storahci hold Srb queue of 255 size
224
226// --------------------------- //
228
230{
231 struct
232 {
233 ULONG CFL : 5; // Command FIS Length
234 ULONG A : 1; // IsATAPI
235 ULONG W : 1; // Write
236 ULONG P : 1; // Prefetchable
237
238 ULONG R : 1; // Reset
239 ULONG B : 1; // BIST
240 ULONG C : 1; //Clear Busy upon R_OK
242 ULONG PMP : 4; //Port Multiplier Port
243
244 ULONG PRDTL : 16; //Physical Region Descriptor Table Length
245 };
246
249
250typedef union _AHCI_GHC
251{
252 struct
253 {
259 };
260
263
264// section 3.3.7
265typedef union _AHCI_PORT_CMD
266{
267 struct
268 {
292 };
293
296
298{
299 struct
300 {
307 };
308
311
313{
314 struct
315 {
320 };
321
324
326{
327 struct
328 {
329 struct _STS
330 {
337 UCHAR ERR;
339 };
340
343
344typedef struct _AHCI_PRDT
345{
349
350 ULONG DBC : 22;
352 ULONG I : 1;
354
355// 4.2.3 Command Table
357{
358 // (16 * 32) + 64 + 16 + 48 = 648
359 // 128 byte aligned :D
365
366// 4.2.2 Command Header
368{
370 ULONG PRDBC; // DW 1
371 ULONG CTBA; // DW 2
372 ULONG CTBA_U; // DW 3
373 ULONG Reserved[4]; // DW 4-7
375
376// Received FIS
377typedef struct _AHCI_RECEIVED_FIS
378{
379 struct _AHCI_FIS_DMA_SETUP DmaSetupFIS; // 0x00 -- DMA Setup FIS
380 ULONG pad0; // 4 BYTE padding
381 struct _AHCI_PIO_SETUP_FIS PioSetupFIS; // 0x20 -- PIO Setup FIS
382 ULONG pad1[3]; // 12 BYTE padding
383 struct _AHCI_D2H_REGISTER_FIS RegisterFIS; // 0x40 -- Register – Device to Host FIS
384 ULONG pad2; // 4 BYTE padding
385 struct _AHCI_SET_DEVICE_BITS_FIS SetDeviceFIS; // 0x58 -- Set Device Bit FIS
386 ULONG UnknowFIS[16]; // 0x60 -- Unknown FIS
387 ULONG Reserved[24]; // 0xA0 -- Reserved
389
390// Holds Port Information
391typedef struct _AHCI_PORT
392{
393 ULONG CLB; // 0x00, command list base address, 1K-byte aligned
394 ULONG CLBU; // 0x04, command list base address upper 32 bits
395 ULONG FB; // 0x08, FIS base address, 256-byte aligned
396 ULONG FBU; // 0x0C, FIS base address upper 32 bits
397 ULONG IS; // 0x10, interrupt status
398 ULONG IE; // 0x14, interrupt enable
399 ULONG CMD; // 0x18, command and status
400 ULONG RSV0; // 0x1C, Reserved
401 ULONG TFD; // 0x20, task file data
402 ULONG SIG; // 0x24, signature
403 ULONG SSTS; // 0x28, SATA status (SCR0:SStatus)
404 ULONG SCTL; // 0x2C, SATA control (SCR2:SControl)
405 ULONG SERR; // 0x30, SATA error (SCR1:SError)
406 ULONG SACT; // 0x34, SATA active (SCR3:SActive)
407 ULONG CI; // 0x38, command issue
408 ULONG SNTF; // 0x3C, SATA notification (SCR4:SNotification)
409 ULONG FBS; // 0x40, FIS-based switch control
410 ULONG RSV1[11]; // 0x44 ~ 0x6F, Reserved
411 ULONG Vendor[4]; // 0x70 ~ 0x7F, vendor specific
413
415{
416 struct
417 {
437 };
438
441
443{
444 // 0x00 - 0x2B, Generic Host Control
445 ULONG CAP; // 0x00, Host capability
446 ULONG GHC; // 0x04, Global host control
447 ULONG IS; // 0x08, Interrupt status
448 ULONG PI; // 0x0C, Port implemented
449 ULONG VS; // 0x10, Version
450 ULONG CCC_CTL; // 0x14, Command completion coalescing control
451 ULONG CCC_PTS; // 0x18, Command completion coalescing ports
452 ULONG EM_LOC; // 0x1C, Enclosure management location
453 ULONG EM_CTL; // 0x20, Enclosure management control
454 ULONG CAP2; // 0x24, Host capabilities extended
455 ULONG BOHC; // 0x28, BIOS/OS handoff control and status
456 ULONG Reserved[0x1d]; // 0x2C - 0x9F, Reserved
457 ULONG VendorSpecific[0x18]; // 0xA0 - 0xFF, Vendor specific registers
460
461// Holds information for each attached attached port to a given adapter.
463{
465 ULONG QueueSlots; // slots which we have already assigned task (Slot)
466 ULONG CommandIssuedSlots; // slots which has been programmed
468
469 struct
470 {
483
485 PAHCI_PORT Port; // AHCI Port Infomation
486 AHCI_QUEUE SrbQueue; // pending Srbs
488 PSCSI_REQUEST_BLOCK Slot[MAXIMUM_AHCI_PORT_NCS]; // Srbs which has been alloted a port
494 struct _AHCI_ADAPTER_EXTENSION* AdapterExtension; // Port's Adapter Information
496
497// Holds Adapter Information
499{
503 PULONG IS;// Interrupt Status, In case of MSIM == `1`
504 ULONG PortImplemented;// bit-mapping of ports which are implemented
506
510
516
517 PVOID NonCachedExtension; // holds virtual address to noncached buffer allocated for Port Extension
518
519 struct
520 {
521 // Message per port or shared port?
524 ULONG Reserved : 30; // not in use -- maintain 4 byte alignment
526
530
532{
537
539{
543
554
557
562
563 // for alignment purpose -- 128 byte alignment
564 // do not try to access (R/W) this field
567
569// Declarations //
571
572VOID
574 __in PAHCI_ADAPTER_EXTENSION AdapterExtension,
577 );
578
581 __in PAHCI_ADAPTER_EXTENSION AdapterExtension
582 );
583
585VOID
589 );
590
594 __in PAHCI_ADAPTER_EXTENSION AdapterExtension,
595 __in ULONG pathId
596 );
597
599 __in PAHCI_ADAPTER_EXTENSION AdapterExtension,
602 );
603
605 __in PAHCI_ADAPTER_EXTENSION AdapterExtension,
608 );
609
611 __in PAHCI_ADAPTER_EXTENSION AdapterExtension,
614 );
615
616UCHAR
618 __in PAHCI_ADAPTER_EXTENSION AdapterExtension,
621 );
622
624 __in PAHCI_ADAPTER_EXTENSION AdapterExtension,
627 );
628
630 __in PAHCI_ADAPTER_EXTENSION AdapterExtension,
633 );
634
637AddQueue (
640 );
641
643PVOID
646 );
647
652 );
653
657 __in PCDB Cdb,
658 __in ULONG CdbLength
659 );
660
662// Assertions //
664
665// I assert every silly mistake I can do while coding
666// because god never help me debugging the code
667// but these asserts do :')
668
683
703
704C_ASSERT((sizeof(AHCI_COMMAND_TABLE) % 128) == 0);
705
706C_ASSERT(sizeof(AHCI_GHC) == sizeof(ULONG));
707C_ASSERT(sizeof(AHCI_PORT_CMD) == sizeof(ULONG));
713
unsigned char BOOLEAN
#define VOID
Definition: acefi.h:82
#define PI
Definition: appview.h:57
_In_ PSCSI_REQUEST_BLOCK Srb
Definition: cdrom.h:989
Definition: bufpool.h:45
_In_ ULONG _In_ BOOLEAN _In_ ULONG _In_ UCHAR PathId
Definition: classpnp.h:1313
#define __in
Definition: dbghelp.h:35
#define __inout
Definition: dbghelp.h:50
#define __out
Definition: dbghelp.h:62
#define CI(cs)
Definition: fontdlg.c:68
#define C_ASSERT(e)
Definition: intsafe.h:73
unsigned __int64 ULONG64
Definition: imports.h:198
unsigned short USHORT
Definition: pedump.c:61
_In_opt_ WDFREQUEST _In_ ULONG _In_ BOOLEAN _In_ PCDB Cdb
Definition: scratch.h:159
enum _STOR_DEVICE_POWER_STATE STOR_DEVICE_POWER_STATE
#define CMD
Definition: stat64.c:23
UCHAR DeviceReportLuns(__in PAHCI_ADAPTER_EXTENSION AdapterExtension, __in PSCSI_REQUEST_BLOCK Srb, __in PCDB Cdb)
Definition: storahci.c:2196
union _AHCI_INTERRUPT_STATUS AHCI_INTERRUPT_STATUS
BOOLEAN AhciAdapterReset(__in PAHCI_ADAPTER_EXTENSION AdapterExtension)
Definition: storahci.c:2393
union _AHCI_COMMAND_HEADER_DESCRIPTION AHCI_COMMAND_HEADER_DESCRIPTION
UCHAR DeviceInquiryRequest(__in PAHCI_ADAPTER_EXTENSION AdapterExtension, __in PSCSI_REQUEST_BLOCK Srb, __in PCDB Cdb)
Definition: storahci.c:2250
struct _AHCI_FIS_DMA_SETUP AHCI_FIS_DMA_SETUP
struct _AHCI_COMMAND_TABLE * PAHCI_COMMAND_TABLE
struct _AHCI_PRDT AHCI_PRDT
struct _AHCI_PORT * PAHCI_PORT
#define MAXIMUM_AHCI_PORT_COUNT
Definition: storahci.h:21
union _AHCI_PORT_CMD AHCI_PORT_CMD
struct _AHCI_COMMAND_TABLE AHCI_COMMAND_TABLE
struct _AHCI_PORT_EXTENSION * PAHCI_PORT_EXTENSION
FORCEINLINE BOOLEAN AddQueue(__inout PAHCI_QUEUE Queue, __in PVOID Srb)
Definition: storahci.c:2501
struct _AHCI_QUEUE * PAHCI_QUEUE
struct _AHCI_MEMORY_REGISTERS AHCI_MEMORY_REGISTERS
FORCEINLINE ULONG64 AhciGetLba(__in PCDB Cdb, __in ULONG CdbLength)
Definition: storahci.c:2595
struct _AHCI_PORT_EXTENSION AHCI_PORT_EXTENSION
union _AHCI_INTERRUPT_ENABLE AHCI_INTERRUPT_ENABLE
UCHAR DeviceRequestSense(__in PAHCI_ADAPTER_EXTENSION AdapterExtension, __in PSCSI_REQUEST_BLOCK Srb, __in PCDB Cdb)
Definition: storahci.c:1933
struct _AHCI_D2H_REGISTER_FIS AHCI_D2H_REGISTER_FIS
union _AHCI_TASK_FILE_DATA AHCI_TASK_FILE_DATA
struct _AHCI_PIO_SETUP_FIS AHCI_PIO_SETUP_FIS
FORCEINLINE BOOLEAN IsPortValid(__in PAHCI_ADAPTER_EXTENSION AdapterExtension, __in ULONG pathId)
Definition: storahci.c:2471
UCHAR DeviceRequestReadWrite(__in PAHCI_ADAPTER_EXTENSION AdapterExtension, __in PSCSI_REQUEST_BLOCK Srb, __in PCDB Cdb)
Definition: storahci.c:1988
struct _AHCI_RECEIVED_FIS AHCI_RECEIVED_FIS
struct _AHCI_COMMAND_HEADER * PAHCI_COMMAND_HEADER
struct _AHCI_PORT AHCI_PORT
struct _LOCAL_SCATTER_GATHER_LIST LOCAL_SCATTER_GATHER_LIST
FORCEINLINE PVOID RemoveQueue(__inout PAHCI_QUEUE Queue)
Definition: storahci.c:2532
#define MAXIMUM_AHCI_PORT_NCS
Definition: storahci.h:23
union _AHCI_SERIAL_ATA_STATUS AHCI_SERIAL_ATA_STATUS
union _AHCI_SERIAL_ATA_CONTROL AHCI_SERIAL_ATA_CONTROL
struct _AHCI_RECEIVED_FIS * PAHCI_RECEIVED_FIS
struct _AHCI_SRB_EXTENSION AHCI_SRB_EXTENSION
struct _AHCI_QUEUE AHCI_QUEUE
struct _AHCI_SRB_EXTENSION * PAHCI_SRB_EXTENSION
VOID(* PAHCI_COMPLETION_ROUTINE)(__in PVOID PortExtension, __in PVOID Srb)
Definition: storahci.h:89
FORCEINLINE VOID AhciZeroMemory(__out PCHAR Buffer, __in ULONG BufferSize)
Definition: storahci.c:2443
struct _LOCAL_SCATTER_GATHER_LIST * PLOCAL_SCATTER_GATHER_LIST
struct _AHCI_ADAPTER_EXTENSION AHCI_ADAPTER_EXTENSION
struct _AHCI_MEMORY_REGISTERS * PAHCI_MEMORY_REGISTERS
FORCEINLINE PAHCI_SRB_EXTENSION GetSrbExtension(__in PSCSI_REQUEST_BLOCK Srb)
Definition: storahci.c:2564
union _AHCI_GHC AHCI_GHC
struct _AHCI_ADAPTER_EXTENSION * PAHCI_ADAPTER_EXTENSION
VOID AhciProcessIO(__in PAHCI_ADAPTER_EXTENSION AdapterExtension, __in UCHAR PathId, __in PSCSI_REQUEST_BLOCK Srb)
Definition: storahci.c:1555
UCHAR DeviceRequestCapacity(__in PAHCI_ADAPTER_EXTENSION AdapterExtension, __in PSCSI_REQUEST_BLOCK Srb, __in PCDB Cdb)
Definition: storahci.c:2098
struct _AHCI_PRDT * PAHCI_PRDT
struct _AHCI_COMMAND_HEADER AHCI_COMMAND_HEADER
struct _AHCI_SET_DEVICE_BITS_FIS AHCI_SET_DEVICE_BITS_FIS
#define MAXIMUM_QUEUE_BUFFER_SIZE
Definition: storahci.h:24
#define MAXIMUM_AHCI_PRDT_ENTRIES
Definition: storahci.h:22
@ DeviceRequestComplete
Definition: strmini.h:330
PAHCI_MEMORY_REGISTERS ABAR_Address
Definition: storahci.h:527
struct _AHCI_ADAPTER_EXTENSION::@1345 StateFlags
AHCI_PORT_EXTENSION PortExtension[MAXIMUM_AHCI_PORT_COUNT]
Definition: storahci.h:528
AHCI_COMMAND_HEADER_DESCRIPTION DI
Definition: storahci.h:369
UCHAR CFIS[64]
Definition: storahci.h:360
UCHAR ACMD[16]
Definition: storahci.h:361
AHCI_PRDT PRDT[MAXIMUM_AHCI_PRDT_ENTRIES]
Definition: storahci.h:363
UCHAR RSV0[48]
Definition: storahci.h:362
AHCI_PORT PortList[MAXIMUM_AHCI_PORT_COUNT]
Definition: storahci.h:458
ULONG VendorSpecific[0x18]
Definition: storahci.h:457
UCHAR Reserved5[2]
Definition: storahci.h:170
USHORT TransferCount
Definition: storahci.h:169
ULONG BytesPerPhysicalSector
Definition: storahci.h:478
struct _AHCI_PORT_EXTENSION::@1344 DeviceParams
PAHCI_PORT Port
Definition: storahci.h:485
struct _AHCI_ADAPTER_EXTENSION * AdapterExtension
Definition: storahci.h:494
UCHAR SerialNumber[21]
Definition: storahci.h:481
PIDENTIFY_DEVICE_DATA IdentifyDeviceData
Definition: storahci.h:492
AHCI_QUEUE CompletionQueue
Definition: storahci.h:487
STOR_PHYSICAL_ADDRESS IdentifyDeviceDataPhysicalAddress
Definition: storahci.h:493
LARGE_INTEGER MaxLba
Definition: storahci.h:476
STOR_DEVICE_POWER_STATE DevicePowerState
Definition: storahci.h:491
ULONG CommandIssuedSlots
Definition: storahci.h:466
PAHCI_RECEIVED_FIS ReceivedFIS
Definition: storahci.h:489
PSCSI_REQUEST_BLOCK Slot[MAXIMUM_AHCI_PORT_NCS]
Definition: storahci.h:488
PAHCI_COMMAND_HEADER CommandList
Definition: storahci.h:490
ULONG BytesPerLogicalSector
Definition: storahci.h:477
UCHAR RevisionID[9]
Definition: storahci.h:480
UCHAR VendorId[41]
Definition: storahci.h:479
STOR_DPC CommandCompletion
Definition: storahci.h:484
AHCI_QUEUE SrbQueue
Definition: storahci.h:486
ULONG CLB
Definition: storahci.h:393
ULONG SCTL
Definition: storahci.h:404
ULONG IE
Definition: storahci.h:398
ULONG IS
Definition: storahci.h:397
ULONG FB
Definition: storahci.h:395
ULONG FBS
Definition: storahci.h:409
ULONG RSV0
Definition: storahci.h:400
ULONG CI
Definition: storahci.h:407
ULONG Vendor[4]
Definition: storahci.h:411
ULONG RSV1[11]
Definition: storahci.h:410
ULONG SSTS
Definition: storahci.h:403
ULONG SNTF
Definition: storahci.h:408
ULONG SIG
Definition: storahci.h:402
ULONG FBU
Definition: storahci.h:396
ULONG TFD
Definition: storahci.h:401
ULONG SACT
Definition: storahci.h:406
ULONG CMD
Definition: storahci.h:399
ULONG SERR
Definition: storahci.h:405
ULONG CLBU
Definition: storahci.h:394
ULONG DBA
Definition: storahci.h:346
ULONG DBAU
Definition: storahci.h:347
ULONG I
Definition: storahci.h:352
ULONG RSV1
Definition: storahci.h:351
ULONG RSV0
Definition: storahci.h:348
ULONG DBC
Definition: storahci.h:350
ULONG Tail
Definition: storahci.h:222
ULONG Head
Definition: storahci.h:221
struct _AHCI_PIO_SETUP_FIS PioSetupFIS
Definition: storahci.h:381
struct _AHCI_SET_DEVICE_BITS_FIS SetDeviceFIS
Definition: storahci.h:385
struct _AHCI_FIS_DMA_SETUP DmaSetupFIS
Definition: storahci.h:379
ULONG UnknowFIS[16]
Definition: storahci.h:386
struct _AHCI_D2H_REGISTER_FIS RegisterFIS
Definition: storahci.h:383
PAHCI_COMPLETION_ROUTINE CompletionRoutine
Definition: storahci.h:561
PLOCAL_SCATTER_GATHER_LIST pSgl
Definition: storahci.h:560
AHCI_COMMAND_TABLE CommandTable
Definition: storahci.h:540
LOCAL_SCATTER_GATHER_LIST Sgl
Definition: storahci.h:559
uint32_t * PULONG
Definition: typedefs.h:59
#define FIELD_OFFSET(t, f)
Definition: typedefs.h:255
uint32_t ULONG_PTR
Definition: typedefs.h:65
uint32_t ULONG
Definition: typedefs.h:59
char * PCHAR
Definition: typedefs.h:51
ULONG Status
Definition: storahci.h:261
ULONG IE
Definition: storahci.h:255
ULONG HR
Definition: storahci.h:254
ULONG AE
Definition: storahci.h:258
ULONG RSV0
Definition: storahci.h:257
ULONG MRSM
Definition: storahci.h:256
ULONG Status
Definition: storahci.h:294
struct _AHCI_TASK_FILE_DATA::@1340::_STS STS
Definition: cdrw_hw.h:28
_Must_inspect_result_ _In_ WDFDEVICE _In_ PIRP _In_ WDFQUEUE Queue
Definition: wdfdevice.h:2225
_In_ WDFMEMORY _Out_opt_ size_t * BufferSize
Definition: wdfmemory.h:254
_Must_inspect_result_ _In_ WDFCMRESLIST List
Definition: wdfresource.h:550
#define FORCEINLINE
Definition: wdftypes.h:67
_Reserved_ PVOID Reserved
Definition: winddi.h:3974
unsigned char UCHAR
Definition: xmlstorage.h:181