ReactOS 0.4.15-dev-7924-g5949c20
scsiwmi.h
Go to the documentation of this file.
1/*
2 * scsiwmi.h
3 *
4 * SCSI WMILIB 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#pragma once
24
25#ifndef _SCSIWMI_
26#define _SCSIWMI_
27
28#include "srb.h"
29
30#ifdef __cplusplus
31extern "C" {
32#endif
33
34#pragma pack(push,4)
35
44
45#ifdef _GUID_DEFINED
46# warning _GUID_DEFINED is deprecated, use GUID_DEFINED instead
47#endif
48
49#if ! (defined _GUID_DEFINED || defined GUID_DEFINED)
50#define GUID_DEFINED
51typedef struct _GUID {
52 unsigned long Data1;
53 unsigned short Data2;
54 unsigned short Data3;
55 unsigned char Data4[8];
57#endif
58
59typedef struct _SCSIWMIGUIDREGINFO {
64
65typedef
70 _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext,
72
73typedef
82 _Inout_ PULONG InstanceLengthArray,
85
86typedef
91 _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext,
96
97typedef
102 _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext,
108
109typedef
114 _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext,
121
126
127typedef
132 _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext,
136
137typedef struct _SCSIWMILIB_CONTEXT {
147
151NTAPI
153 _In_ PSCSI_WMILIB_CONTEXT WmiLibInfo,
156 _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext,
157 _In_ PVOID DataPath,
160
161#define ScsiPortWmiFireAdapterEvent( \
162 HwDeviceExtension, \
163 Guid, \
164 InstanceIndex, \
165 EventDataSize, \
166 EventData) \
167 ScsiPortWmiFireLogicalUnitEvent( \
168 HwDeviceExtension, \
169 0xff, \
170 0, \
171 0, \
172 Guid, \
173 InstanceIndex, \
174 EventDataSize, \
175 EventData)
176
177/*
178 * ULONG
179 * ScsiPortWmiGetReturnSize(
180 * PSCSIWMI_REQUEST_CONTEXT RequestContext);
181 */
182#define ScsiPortWmiGetReturnSize(RequestContext) \
183 ((RequestContext)->ReturnSize)
184
185/* UCHAR
186 * ScsiPortWmiGetReturnStatus(
187 * PSCSIWMI_REQUEST_CONTEXT RequestContext);
188 */
189#define ScsiPortWmiGetReturnStatus(RequestContext) \
190 ((RequestContext)->ReturnStatus)
191
193VOID
194NTAPI
196 _Inout_ PSCSIWMI_REQUEST_CONTEXT RequestContext,
197 _In_ UCHAR SrbStatus,
199
201VOID
202NTAPI
204 _In_ PVOID HwDeviceExtension,
207 _In_ UCHAR Lun,
211 _In_ PVOID EventData);
212
213#pragma pack(pop)
214
215#ifdef __cplusplus
216}
217#endif
218
219#endif /* _SCSIWMI_ */
unsigned char BOOLEAN
_In_ CDROM_SCAN_FOR_SPECIAL_INFO _In_ PCDROM_SCAN_FOR_SPECIAL_HANDLER Function
Definition: cdrom.h:1156
Definition: bufpool.h:45
_In_ ULONG _In_ BOOLEAN _In_ ULONG _In_ UCHAR _In_ UCHAR _In_ UCHAR Lun
Definition: classpnp.h:1315
_In_ ULONG _In_ BOOLEAN _In_ ULONG _In_ UCHAR PathId
Definition: classpnp.h:1313
_In_ LPGUID _In_ ULONG InstanceIndex
Definition: classpnp.h:1251
_In_ ULONG _In_ BOOLEAN _In_ ULONG _In_ UCHAR _In_ UCHAR TargetId
Definition: classpnp.h:1314
_In_ PIRP _In_ ULONG GuidIndex
Definition: classpnp.h:419
_In_ PIRP _In_ ULONG _In_ ULONG BufferAvail
Definition: classpnp.h:420
#define BufferSize
Definition: mmc.h:75
#define _In_reads_bytes_(size)
Definition: ms_sal.h:321
#define _Inout_
Definition: ms_sal.h:378
#define _Out_writes_bytes_(size)
Definition: ms_sal.h:350
#define _Inout_updates_bytes_to_(size, count)
Definition: ms_sal.h:402
#define _Must_inspect_result_
Definition: ms_sal.h:558
#define _Out_
Definition: ms_sal.h:345
#define _In_
Definition: ms_sal.h:308
_In_ PNDIS_STRING _In_opt_ NDIS_HANDLE DeviceContext
Definition: ndis.h:5246
_In_ ULONGLONG _In_ ULONGLONG _In_ BOOLEAN Enable
Definition: ntddpcm.h:142
#define BOOLEAN
Definition: pedump.c:73
#define SCSIPORT_API
Definition: scsi_port.h:177
_Must_inspect_result_ BOOLEAN(NTAPI * PSCSIWMI_FUNCTION_CONTROL)(_In_ PVOID DeviceContext, _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext, _In_ ULONG GuidIndex, _In_ SCSIWMI_ENABLE_DISABLE_CONTROL Function, _In_ BOOLEAN Enable)
Definition: scsiwmi.h:130
_Must_inspect_result_ BOOLEAN(NTAPI * PSCSIWMI_SET_DATAITEM)(_In_ PVOID DeviceContext, _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext, _In_ ULONG GuidIndex, _In_ ULONG InstanceIndex, _In_ ULONG DataItemId, _In_ ULONG BufferSize, _In_reads_bytes_(BufferSize) PUCHAR Buffer)
Definition: scsiwmi.h:100
enum _SCSIWMI_ENABLE_DISABLE_CONTROL SCSIWMI_ENABLE_DISABLE_CONTROL
SCSIPORT_API VOID NTAPI ScsiPortWmiPostProcess(_Inout_ PSCSIWMI_REQUEST_CONTEXT RequestContext, _In_ UCHAR SrbStatus, _In_ ULONG BufferUsed)
_SCSIWMI_ENABLE_DISABLE_CONTROL
Definition: scsiwmi.h:122
@ ScsiWmiDataBlockControl
Definition: scsiwmi.h:124
@ ScsiWmiEventControl
Definition: scsiwmi.h:123
struct _SCSIWMILIB_CONTEXT SCSI_WMILIB_CONTEXT
struct _SCSIWMILIB_CONTEXT * PSCSI_WMILIB_CONTEXT
_Must_inspect_result_ SCSIPORT_API BOOLEAN NTAPI ScsiPortWmiDispatchFunction(_In_ PSCSI_WMILIB_CONTEXT WmiLibInfo, _In_ UCHAR MinorFunction, _In_ PVOID DeviceContext, _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext, _In_ PVOID DataPath, _In_ ULONG BufferSize, _In_ PVOID Buffer)
_Must_inspect_result_ BOOLEAN(NTAPI * PSCSIWMI_SET_DATABLOCK)(_In_ PVOID DeviceContext, _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext, _In_ ULONG GuidIndex, _In_ ULONG InstanceIndex, _In_ ULONG BufferSize, _In_reads_bytes_(BufferSize) PUCHAR Buffer)
Definition: scsiwmi.h:89
_Must_inspect_result_ BOOLEAN(NTAPI * PSCSIWMI_QUERY_DATABLOCK)(_In_ PVOID Context, _In_ PSCSIWMI_REQUEST_CONTEXT DispatchContext, _In_ ULONG GuidIndex, _In_ ULONG InstanceIndex, _In_ ULONG InstanceCount, _Inout_ PULONG InstanceLengthArray, _In_ ULONG BufferAvail, _Out_writes_bytes_(BufferAvail) PUCHAR Buffer)
Definition: scsiwmi.h:76
struct _SCSIWMI_REQUEST_CONTEXT * PSCSIWMI_REQUEST_CONTEXT
SCSIPORT_API VOID NTAPI ScsiPortWmiFireLogicalUnitEvent(_In_ PVOID HwDeviceExtension, _In_ UCHAR PathId, _In_ UCHAR TargetId, _In_ UCHAR Lun, _In_ LPGUID Guid, _In_ ULONG InstanceIndex, _In_ ULONG EventDataSize, _In_ PVOID EventData)
struct _SCSIWMIGUIDREGINFO SCSIWMIGUIDREGINFO
struct _SCSIWMIGUIDREGINFO * PSCSIWMIGUIDREGINFO
struct _GUID GUID
_Must_inspect_result_ UCHAR(NTAPI * PSCSIWMI_QUERY_REGINFO)(_In_ PVOID DeviceContext, _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext, _Out_ PWCHAR *MofResourceName)
Definition: scsiwmi.h:68
_Must_inspect_result_ BOOLEAN(NTAPI * PSCSIWMI_EXECUTE_METHOD)(_In_ PVOID DeviceContext, _In_ PSCSIWMI_REQUEST_CONTEXT RequestContext, _In_ ULONG GuidIndex, _In_ ULONG InstanceIndex, _In_ ULONG MethodId, _In_ ULONG InBufferSize, _In_ ULONG OutBufferSize, _Inout_updates_bytes_to_(InBufferSize, OutBufferSize) PUCHAR Buffer)
Definition: scsiwmi.h:112
struct _SCSIWMI_REQUEST_CONTEXT SCSIWMI_REQUEST_CONTEXT
Definition: scsiwmi.h:51
unsigned char Data4[8]
Definition: scsiwmi.h:55
unsigned long Data1
Definition: scsiwmi.h:52
unsigned short Data2
Definition: scsiwmi.h:53
unsigned short Data3
Definition: scsiwmi.h:54
ULONG InstanceCount
Definition: scsiwmi.h:61
PSCSIWMI_FUNCTION_CONTROL WmiFunctionControl
Definition: scsiwmi.h:145
PSCSIWMI_SET_DATABLOCK SetWmiDataBlock
Definition: scsiwmi.h:142
PSCSIWMI_SET_DATAITEM SetWmiDataItem
Definition: scsiwmi.h:143
PSCSIWMI_QUERY_DATABLOCK QueryWmiDataBlock
Definition: scsiwmi.h:141
PSCSIWMI_QUERY_REGINFO QueryWmiRegInfo
Definition: scsiwmi.h:140
PSCSIWMI_EXECUTE_METHOD ExecuteWmiMethod
Definition: scsiwmi.h:144
PSCSIWMIGUIDREGINFO GuidList
Definition: scsiwmi.h:139
uint32_t * PULONG
Definition: typedefs.h:59
#define NTAPI
Definition: typedefs.h:36
uint16_t * PWCHAR
Definition: typedefs.h:56
unsigned char * PUCHAR
Definition: typedefs.h:53
uint32_t ULONG
Definition: typedefs.h:59
_In_ UCHAR _In_ UCHAR _In_ ULONG _In_ WDFCONTEXT _Inout_ PIRP _In_ WDFCONTEXT DispatchContext
Definition: wdfdevice.h:1708
_Must_inspect_result_ _In_ WDFDEVICE _In_ PCUNICODE_STRING MofResourceName
Definition: wdfdevice.h:2464
_In_ UCHAR _In_ UCHAR MinorFunction
Definition: wdfdevice.h:1699
_In_ WDFMEMORY _Out_opt_ size_t * BufferSize
Definition: wdfmemory.h:254
_Must_inspect_result_ _In_ WDFOBJECT _In_ CONST GUID * Guid
Definition: wdfobject.h:762
_In_ ULONG OutBufferSize
Definition: wdfwmi.h:87
_In_ ULONG _Out_ PULONG BufferUsed
Definition: wdfwmi.h:92
_In_ ULONG InBufferSize
Definition: wdfwmi.h:106
_In_ ULONG MethodId
Definition: wdfwmi.h:142
_In_ ULONG DataItemId
Definition: wdfwmi.h:123
_Must_inspect_result_ _In_ WDFWMIINSTANCE _In_opt_ ULONG EventDataSize
Definition: wdfwmi.h:617
_In_ ULONG InstanceCount
Definition: iofuncs.h:1323
unsigned char UCHAR
Definition: xmlstorage.h:181