ReactOS  0.4.15-dev-3173-g40ee59d
fxinterruptapi.cpp File Reference
#include "pnppriv.hpp"
Include dependency graph for fxinterruptapi.cpp:

Go to the source code of this file.

Classes

struct  _WDF_INTERRUPT_CONFIG_V1_9
 
struct  _WDF_INTERRUPT_CONFIG_V1_11_BETA
 
struct  _WDF_INTERRUPT_CONFIG_V1_11
 

Typedefs

typedef struct _WDF_INTERRUPT_CONFIG_V1_9 WDF_INTERRUPT_CONFIG_V1_9
 
typedef struct _WDF_INTERRUPT_CONFIG_V1_9PWDF_INTERRUPT_CONFIG_V1_9
 
typedef struct _WDF_INTERRUPT_CONFIG_V1_11_BETA WDF_INTERRUPT_CONFIG_V1_11_BETA
 
typedef struct _WDF_INTERRUPT_CONFIG_V1_11_BETAPWDF_INTERRUPT_CONFIG_V1_11_BETA
 
typedef struct _WDF_INTERRUPT_CONFIG_V1_11 WDF_INTERRUPT_CONFIG_V1_11
 
typedef struct _WDF_INTERRUPT_CONFIG_V1_11PWDF_INTERRUPT_CONFIG_V1_11
 

Functions

_Must_inspect_result_ __drv_maxIRQL (DISPATCH_LEVEL) NTSTATUS STDCALL WDFEXPORT(WdfInterruptCreate)(__in PWDF_DRIVER_GLOBALS DriverGlobals
 
 FxObjectHandleGetPtrAndGlobals (GetFxDriverGlobals(DriverGlobals), Device, FX_TYPE_DEVICE,(PVOID *)&pDevice, &pFxDriverGlobals)
 
 FxPointerNotNull (pFxDriverGlobals, Configuration)
 
 FxPointerNotNull (pFxDriverGlobals, Interrupt)
 
 if (pFxDriverGlobals->IsVersionGreaterThanOrEqualTo(1, 13))
 
else if (pFxDriverGlobals->IsVersionGreaterThanOrEqualTo(1, 11))
 
 if (Configuration->Size !=sizeof(WDF_INTERRUPT_CONFIG) &&Configuration->Size !=sizeof(WDF_INTERRUPT_CONFIG_V1_11) &&Configuration->Size !=sizeof(WDF_INTERRUPT_CONFIG_V1_11_BETA) &&Configuration->Size !=sizeof(WDF_INTERRUPT_CONFIG_V1_9))
 
 if (Configuration->Size< sizeof(WDF_INTERRUPT_CONFIG))
 
 FX_VERIFY_WITH_NAME (DRIVER(BadArgument, TODO), CHECK(ERROR_STRING_HW_ACCESS_NOT_ALLOWED,(pDevice->IsInterruptAccessAllowed()==TRUE)), DriverGlobals->DriverName)
 
 FX_VERIFY_WITH_NAME (DRIVER(BadArgument, TODO), CHECK("PassiveHandling not set to TRUE in WDF_INTERRUPT_CONFIG structure",(Configuration->PassiveHandling==TRUE)), DriverGlobals->DriverName)
 
 if (Configuration->EvtInterruptIsr==NULL)
 
 if (!NT_SUCCESS(status))
 
 if (Attributes !=NULL &&Attributes->ParentObject !=NULL)
 
 if (devicePnpState !=WdfDevStatePnpInit &&0x0==(pDevice->GetCallbackFlags() &FXDEVICE_CALLBACK_IN_PREPARE_HARDWARE))
 
 if (devicePnpState==WdfDevStatePnpInit)
 
 if (Configuration->EvtInterruptDpc !=NULL &&Configuration->EvtInterruptWorkItem !=NULL)
 
 if (NT_SUCCESS(status))
 
BOOLEAN STDCALL WDFEXPORT() WdfInterruptQueueDpcForIsr (__in PWDF_DRIVER_GLOBALS DriverGlobals, __in WDFINTERRUPT Interrupt)
 
BOOLEAN STDCALL WDFEXPORT() WdfInterruptQueueWorkItemForIsr (__in PWDF_DRIVER_GLOBALS DriverGlobals, __in WDFINTERRUPT Interrupt)
 
 FxObjectHandleGetPtr (GetFxDriverGlobals(DriverGlobals), Interrupt, FX_TYPE_INTERRUPT,(PVOID *)&pFxInterrupt)
 
 if (pFxInterrupt->IsPassiveHandling())
 
 FxPointerNotNull (pFxInterrupt->GetDriverGlobals(), Callback)
 
return pFxInterrupt Synchronize (Callback, Context)
 
__in _Requires_lock_not_held_ (_Curr_) _Acquires_lock_(_Curr_) WDFINTERRUPT Interrupt)
 
 __drv_maxIRQL (DISPATCH_LEVEL+1) VOID STDCALL WDFEXPORT(WdfInterruptReleaseLock)(__in PWDF_DRIVER_GLOBALS DriverGlobals
 
__in _Requires_lock_held_ (_Curr_) _Releases_lock_(_Curr_) WDFINTERRUPT Interrupt)
 
 __drv_maxIRQL (PASSIVE_LEVEL) VOID STDCALL WDFEXPORT(WdfInterruptEnable)(__in PWDF_DRIVER_GLOBALS DriverGlobals
 
VOID pFxInterrupt ForceReconnect ()
 
VOID pFxInterrupt ForceDisconnect ()
 
_Must_inspect_result_ struct _KINTERRUPT *STDCALL WDFEXPORT() WdfInterruptWdmGetInterrupt (__in PWDF_DRIVER_GLOBALS DriverGlobals, __in WDFINTERRUPT Interrupt)
 
 FxObjectHandleGetPtrAndGlobals (GetFxDriverGlobals(DriverGlobals), Interrupt, FX_TYPE_INTERRUPT,(PVOID *)&pFxInterrupt, &pFxDriverGlobals)
 
 FxPointerNotNull (pFxDriverGlobals, Info)
 
 if (sizeof(WDF_INTERRUPT_INFO_V1_7)==Info->Size)
 
else if (sizeof(WDF_INTERRUPT_INFO)==Info->Size)
 
 FxVerifierDbgBreakPoint (pFxDriverGlobals)
 
 RtlCopyMemory (Info, pFxInterrupt->GetInfo(), size)
 
WDFDEVICE STDCALL WDFEXPORT() WdfInterruptGetDevice (__in PWDF_DRIVER_GLOBALS DriverGlobals, __in WDFINTERRUPT Interrupt)
 
 if (Policy< WdfIrqPolicyMachineDefault||Policy > WdfIrqPolicySpreadMessagesAcrossAllProcessors)
 
 if (Priority< WdfIrqPriorityLow||Priority > WdfIrqPriorityHigh)
 
RtlZeroMemoryprocessorSet (processorSet)
 
pFxInterrupt SetPolicy (Policy, Priority, &processorSet)
 
 if (PolicyAndGroup->Size !=sizeof(WDF_INTERRUPT_EXTENDED_POLICY))
 
 if (policy< WdfIrqPolicyMachineDefault||policy > WdfIrqPolicySpreadMessagesAcrossAllProcessors)
 
 if (priority< WdfIrqPriorityLow||priority > WdfIrqPriorityHigh)
 
 if (processorSet->Reserved[0] !=0||processorSet->Reserved[1] !=0||processorSet->Reserved[2] !=0)
 
pFxInterrupt SetPolicy (policy, priority, processorSet)
 

Variables

_Must_inspect_result_ __in WDFDEVICE Device
 
_Must_inspect_result_ __in WDFDEVICE __in PWDF_INTERRUPT_CONFIG Configuration
 
_Must_inspect_result_ __in WDFDEVICE __in PWDF_INTERRUPT_CONFIG __in_opt PWDF_OBJECT_ATTRIBUTES Attributes
 
_Must_inspect_result_ __in WDFDEVICE __in PWDF_INTERRUPT_CONFIG __in_opt PWDF_OBJECT_ATTRIBUTES __out WDFINTERRUPT * Interrupt
 
PFX_DRIVER_GLOBALS pFxDriverGlobals = NULL
 
FxInterruptpFxInterrupt = NULL
 
FxDevicepDevice
 
FxObjectpParent
 
NTSTATUS status
 
WDF_DEVICE_PNP_STATE devicePnpState = pDevice->GetDevicePnpState()
 
ULONG expectedConfigSize
 
WDF_INTERRUPT_CONFIG intConfig
 
 else
 
__in WDFINTERRUPT __in PFN_WDF_INTERRUPT_SYNCHRONIZE Callback
 
__in WDFINTERRUPT __in PFN_WDF_INTERRUPT_SYNCHRONIZE __in WDFCONTEXT Context
 
__in WDFINTERRUPT __out PWDF_INTERRUPT_INFO Info
 
ULONG size = 0
 
 return
 
Info Size = size
 
__in WDFINTERRUPT __in WDF_INTERRUPT_POLICY Policy
 
__in WDFINTERRUPT __in WDF_INTERRUPT_POLICY __in WDF_INTERRUPT_PRIORITY Priority
 
__in WDFINTERRUPT __in WDF_INTERRUPT_POLICY __in WDF_INTERRUPT_PRIORITY __in KAFFINITY TargetProcessorSet
 
GROUP_AFFINITY processorSet = NULL
 
processorSet Mask = TargetProcessorSet
 
__in WDFINTERRUPT __in PWDF_INTERRUPT_EXTENDED_POLICY PolicyAndGroup
 
WDF_INTERRUPT_POLICY policy = PolicyAndGroup->Policy
 
WDF_INTERRUPT_PRIORITY priority = PolicyAndGroup->Priority
 

Typedef Documentation

◆ PWDF_INTERRUPT_CONFIG_V1_11

◆ PWDF_INTERRUPT_CONFIG_V1_11_BETA

◆ PWDF_INTERRUPT_CONFIG_V1_9

◆ WDF_INTERRUPT_CONFIG_V1_11

◆ WDF_INTERRUPT_CONFIG_V1_11_BETA

◆ WDF_INTERRUPT_CONFIG_V1_9

Function Documentation

◆ __drv_maxIRQL() [1/3]

◆ __drv_maxIRQL() [2/3]

__drv_maxIRQL ( DISPATCH_LEVEL 1)

◆ __drv_maxIRQL() [3/3]

__drv_maxIRQL ( PASSIVE_LEVEL  )

◆ _Requires_lock_held_()

__in _Requires_lock_held_ ( _Curr_  )

Definition at line 815 of file fxinterruptapi.cpp.

834 {
835  DDI_ENTRY();
836 
839 
841  Interrupt,
843  (PVOID*)&pFxInterrupt);
844 
847  PASSIVE_LEVEL);
848  if (!NT_SUCCESS(status)) {
849  return;
850  }
851  }
852 
854 }
#define DDI_ENTRY()
Definition: fxglobalskm.h:56
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFINTERRUPT * Interrupt
Definition: wdfinterrupt.h:372
LONG NTSTATUS
Definition: precomp.h:26
DriverGlobals
NTSTATUS status
__inline NTSTATUS FxVerifierCheckIrqlLevel(__in PFX_DRIVER_GLOBALS FxDriverGlobals, __in KIRQL Irql)
Definition: fxverifier.h:158
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
FxInterrupt * pFxInterrupt
VOID ReleaseLock(VOID)
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
__inline BOOLEAN IsPassiveHandling(VOID)
__inline PFX_DRIVER_GLOBALS GetDriverGlobals(VOID)
Definition: fxobject.hpp:734
FxObjectHandleGetPtr(GetFxDriverGlobals(DriverGlobals), Interrupt, FX_TYPE_INTERRUPT,(PVOID *)&pFxInterrupt)
__inline PFX_DRIVER_GLOBALS GetFxDriverGlobals(__in PWDF_DRIVER_GLOBALS DriverGlobals)
Definition: fxglobals.h:597
Definition: ps.c:97

◆ _Requires_lock_not_held_()

__in _Requires_lock_not_held_ ( _Curr_  )

Definition at line 767 of file fxinterruptapi.cpp.

786 {
787  DDI_ENTRY();
788 
791 
793  Interrupt,
795  (PVOID*)&pFxInterrupt);
796 
799  PASSIVE_LEVEL);
800  if (!NT_SUCCESS(status)) {
801  return;
802  }
803  }
804 
806 }
#define DDI_ENTRY()
Definition: fxglobalskm.h:56
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFINTERRUPT * Interrupt
Definition: wdfinterrupt.h:372
LONG NTSTATUS
Definition: precomp.h:26
DriverGlobals
NTSTATUS status
__inline NTSTATUS FxVerifierCheckIrqlLevel(__in PFX_DRIVER_GLOBALS FxDriverGlobals, __in KIRQL Irql)
Definition: fxverifier.h:158
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
FxInterrupt * pFxInterrupt
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
__inline BOOLEAN IsPassiveHandling(VOID)
__inline PFX_DRIVER_GLOBALS GetDriverGlobals(VOID)
Definition: fxobject.hpp:734
FxObjectHandleGetPtr(GetFxDriverGlobals(DriverGlobals), Interrupt, FX_TYPE_INTERRUPT,(PVOID *)&pFxInterrupt)
__inline PFX_DRIVER_GLOBALS GetFxDriverGlobals(__in PWDF_DRIVER_GLOBALS DriverGlobals)
Definition: fxglobals.h:597
VOID AcquireLock(VOID)
Definition: ps.c:97

◆ ForceDisconnect()

VOID pFxInterrupt ForceDisconnect ( )

◆ ForceReconnect()

VOID pFxInterrupt ForceReconnect ( )

◆ FX_VERIFY_WITH_NAME() [1/2]

FX_VERIFY_WITH_NAME ( DRIVER(BadArgument, TODO ,
CHECK(ERROR_STRING_HW_ACCESS_NOT_ALLOWED,(pDevice->IsInterruptAccessAllowed()==TRUE))  ,
DriverGlobals->  DriverName 
)

◆ FX_VERIFY_WITH_NAME() [2/2]

FX_VERIFY_WITH_NAME ( DRIVER(BadArgument, TODO ,
CHECK("PassiveHandling not set to TRUE in WDF_INTERRUPT_CONFIG structure",(Configuration->PassiveHandling==TRUE))  ,
DriverGlobals->  DriverName 
)

◆ FxObjectHandleGetPtr()

◆ FxObjectHandleGetPtrAndGlobals() [1/2]

FxObjectHandleGetPtrAndGlobals ( GetFxDriverGlobals(DriverGlobals ,
Device  ,
FX_TYPE_DEVICE  ,
(PVOID *)&  pDevice,
pFxDriverGlobals 
)

◆ FxObjectHandleGetPtrAndGlobals() [2/2]

FxObjectHandleGetPtrAndGlobals ( GetFxDriverGlobals(DriverGlobals ,
Interrupt  ,
FX_TYPE_INTERRUPT  ,
(PVOID *)&  pFxInterrupt,
pFxDriverGlobals 
)

◆ FxPointerNotNull() [1/4]

FxPointerNotNull ( pFxDriverGlobals  ,
Configuration   
)

◆ FxPointerNotNull() [2/4]

FxPointerNotNull ( pFxDriverGlobals  ,
Interrupt   
)

◆ FxPointerNotNull() [3/4]

FxPointerNotNull ( pFxInterrupt->  GetDriverGlobals(),
Callback   
)

◆ FxPointerNotNull() [4/4]

FxPointerNotNull ( pFxDriverGlobals  ,
Info   
)

◆ FxVerifierDbgBreakPoint()

FxVerifierDbgBreakPoint ( pFxDriverGlobals  )

Referenced by if().

◆ if() [1/20]

if ( pFxDriverGlobals->  IsVersionGreaterThanOrEqualTo1, 13)

Definition at line 251 of file fxinterruptapi.cpp.

251  {
struct _WDF_INTERRUPT_CONFIG WDF_INTERRUPT_CONFIG
_Must_inspect_result_ BOOLEAN IsVersionGreaterThanOrEqualTo(__in ULONG Major, __in ULONG Minor)
Definition: globalskm.cpp:92
ULONG expectedConfigSize
PFX_DRIVER_GLOBALS pFxDriverGlobals

◆ if() [2/20]

else if ( pFxDriverGlobals->  IsVersionGreaterThanOrEqualTo1, 11)

Definition at line 253 of file fxinterruptapi.cpp.

253  {
255  } else {
struct _WDF_INTERRUPT_CONFIG_V1_11 WDF_INTERRUPT_CONFIG_V1_11
ULONG expectedConfigSize

◆ if() [3/20]

Definition at line 264 of file fxinterruptapi.cpp.

267  {
268 
271  "WDF_INTERRUPT_CONFIG size 0x%x incorrect, expected 0x%x",
273 
275  }
#define STATUS_INFO_LENGTH_MISMATCH
Definition: udferr_usr.h:133
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG Configuration
Definition: wdfinterrupt.h:372
ULONG expectedConfigSize
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)

◆ if() [4/20]

if ( )

Definition at line 280 of file fxinterruptapi.cpp.

280  {
281  //
282  // Init new fields to default values.
283  //
286  Configuration->EvtInterruptDpc);
287  //
288  // Copy over existing fields and readjust the struct size.
289  //
291  intConfig.Size = sizeof(intConfig);
292 
293  //
294  // Use new config structure from now on.
295  //
297  }
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG Configuration
Definition: wdfinterrupt.h:372
RtlCopyMemory(Info, pFxInterrupt->GetInfo(), size)
FORCEINLINE VOID WDF_INTERRUPT_CONFIG_INIT(_Out_ PWDF_INTERRUPT_CONFIG Configuration, _In_ PFN_WDF_INTERRUPT_ISR EvtInterruptIsr, _In_opt_ PFN_WDF_INTERRUPT_DPC EvtInterruptDpc)
Definition: wdfinterrupt.h:271
PFN_WDF_INTERRUPT_ISR EvtInterruptIsr
Definition: wdfinterrupt.h:225
WDF_INTERRUPT_CONFIG intConfig

◆ if() [5/20]

if ( Configuration->  EvtInterruptIsr = NULL)

Definition at line 322 of file fxinterruptapi.cpp.

322  {
325  "NULL EvtInterruptIsr in WDF_INTERRUPT_CONFIG structure 0x%p"
326  " passed", Configuration);
328  }
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG Configuration
Definition: wdfinterrupt.h:372
#define STATUS_INVALID_PARAMETER
Definition: udferr_usr.h:135
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)

◆ if() [6/20]

if ( NT_SUCCESSstatus)

Definition at line 339 of file fxinterruptapi.cpp.

339  {
340  return status;
341  }
NTSTATUS status

◆ if() [7/20]

if ( Attributes = NULL && Attributes->ParentObject != NULL)

Definition at line 343 of file fxinterruptapi.cpp.

343  {
345  Attributes->ParentObject,
347  (PVOID*)&pParent);
348  }
PFX_DRIVER_GLOBALS pFxDriverGlobals
FxObject * pParent
FxObjectHandleGetPtr(GetFxDriverGlobals(DriverGlobals), Interrupt, FX_TYPE_INTERRUPT,(PVOID *)&pFxInterrupt)
_Must_inspect_result_ _In_ WDFDMAENABLER _In_ _In_opt_ PWDF_OBJECT_ATTRIBUTES Attributes

◆ if() [8/20]

if ( devicePnpState = WdfDevStatePnpInit && 0x0 == (pDevice->GetCallbackFlags() &                    FXDEVICE_CALLBACK_IN_PREPARE_HARDWARE))

Definition at line 355 of file fxinterruptapi.cpp.

357  {
358 
360 
363  "WDFINTERRUPTs can only be created during: "
364  "(1) EvtDriverDeviceAdd when the WDFDEVICE %p is initially created, or "
365  "(2) EvtDevicePrepareHardware, %!STATUS!", Device, status);
366 
367  return status;
368  }
#define STATUS_INVALID_DEVICE_STATE
Definition: udferr_usr.h:178
NTSTATUS status
_Must_inspect_result_ _In_ WDFDEVICE Device
Definition: wdfchildlist.h:474
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)
Definition: ps.c:97

◆ if() [9/20]

Definition at line 374 of file fxinterruptapi.cpp.

374  {
375 
376  if (Configuration->InterruptRaw != NULL ||
377  Configuration->InterruptTranslated != NULL) {
378 
380 
383  "Not NULL InterruptRaw or InterruptTranslated in "
384  "WDF_INTERRUPT_CONFIG structure 0x%p passed, %!STATUS!",
386 
387  return status;
388  }
389 
390  //
391  // Wake Interrupts can not be created in AddDevice as it is
392  // not known if they are actually marked as wake capable
393  //
394  if (Configuration->CanWakeDevice) {
396 
399  "CanWakeDevice set in WDF_INTERRUPT_CONFIG structure 0x%p"
400  "during EvtDriverDeviceAdd, %!STATUS!",
402 
403  return status;
404  }
405  }
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG Configuration
Definition: wdfinterrupt.h:372
#define STATUS_INVALID_PARAMETER
Definition: udferr_usr.h:135
NTSTATUS status
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)
#define NULL
Definition: types.h:112
Definition: ps.c:97

◆ if() [10/20]

if ( Configuration->EvtInterruptDpc !  = NULL && Configuration->EvtInterruptWorkItem != NULL)

Definition at line 495 of file fxinterruptapi.cpp.

496  {
500  "Driver can provide either EvtInterruptDpc or "
501  "EvtInterruptWorkItem callback but not both. "
502  "WDF_INTERRUPT_CONFIG structure 0x%p passed, %!STATUS!",
504 
505  return status;
506  }
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG Configuration
Definition: wdfinterrupt.h:372
#define STATUS_INVALID_PARAMETER
Definition: udferr_usr.h:135
NTSTATUS status
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)
Definition: ps.c:97

◆ if() [11/20]

if ( NT_SUCCESS(status )

Definition at line 614 of file fxinterruptapi.cpp.

614  {
615  *Interrupt = (WDFINTERRUPT) pFxInterrupt->GetObjectHandle();
616  }
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFINTERRUPT * Interrupt
Definition: wdfinterrupt.h:372
PVOID __inline GetObjectHandle(VOID)
Definition: fxobject.hpp:603
FxInterrupt * pFxInterrupt

◆ if() [12/20]

if ( pFxInterrupt->  IsPassiveHandling())

Definition at line 747 of file fxinterruptapi.cpp.

747  {
749  PASSIVE_LEVEL);
750  if (!NT_SUCCESS(status)) {
751  return FALSE;
752  }
753  }
#define FALSE
Definition: types.h:117
__inline NTSTATUS FxVerifierCheckIrqlLevel(__in PFX_DRIVER_GLOBALS FxDriverGlobals, __in KIRQL Irql)
Definition: fxverifier.h:158
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
FxInterrupt * pFxInterrupt
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
__inline PFX_DRIVER_GLOBALS GetDriverGlobals(VOID)
Definition: fxobject.hpp:734
Definition: ps.c:97

◆ if() [13/20]

Definition at line 1029 of file fxinterruptapi.cpp.

1029  {
1030  size = sizeof(WDF_INTERRUPT_INFO_V1_7);
1031  }
struct _WDF_INTERRUPT_INFO_V1_7 WDF_INTERRUPT_INFO_V1_7
GLsizeiptr size
Definition: glext.h:5919

◆ if() [14/20]

Definition at line 1032 of file fxinterruptapi.cpp.

1032  {
1033  size = sizeof(WDF_INTERRUPT_INFO);
1034  }
struct _WDF_INTERRUPT_INFO WDF_INTERRUPT_INFO
GLsizeiptr size
Definition: glext.h:5919

◆ if() [15/20]

if ( Policy< WdfIrqPolicyMachineDefault||Policy WdfIrqPolicySpreadMessagesAcrossAllProcessors)

Definition at line 1134 of file fxinterruptapi.cpp.

1135  {
1138  "Policy %d is out of range", Policy);
1140  return;
1141  }
FxVerifierDbgBreakPoint(pFxDriverGlobals)
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)
_In_ WDFINTERRUPT _In_ WDF_INTERRUPT_POLICY Policy
Definition: wdfinterrupt.h:651

◆ if() [16/20]

if ( Priority< WdfIrqPriorityLow||Priority WdfIrqPriorityHigh)

Definition at line 1143 of file fxinterruptapi.cpp.

1143  {
1146  "Priority %d is out of range", Priority);
1148  return;
1149  }
FxVerifierDbgBreakPoint(pFxDriverGlobals)
_In_ WDFINTERRUPT _In_ WDF_INTERRUPT_POLICY _In_ WDF_INTERRUPT_PRIORITY Priority
Definition: wdfinterrupt.h:651
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)

◆ if() [17/20]

Definition at line 1204 of file fxinterruptapi.cpp.

1204  {
1207  "WDF_INTERRUPT_EXTENDED_POLICY %p Size %d invalid, expected %d",
1209  PolicyAndGroup->Size,
1212  return;
1213  }
FxVerifierDbgBreakPoint(pFxDriverGlobals)
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)
_In_ WDFINTERRUPT _In_ PWDF_INTERRUPT_EXTENDED_POLICY PolicyAndGroup
Definition: wdfinterrupt.h:688

◆ if() [18/20]

if ( policy< WdfIrqPolicyMachineDefault||policy WdfIrqPolicySpreadMessagesAcrossAllProcessors)

Definition at line 1219 of file fxinterruptapi.cpp.

1220  {
1223  "Policy %d is out of range", policy);
1225  return;
1226  }
FxVerifierDbgBreakPoint(pFxDriverGlobals)
WDF_INTERRUPT_POLICY policy
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)

◆ if() [19/20]

if ( priority< WdfIrqPriorityLow||priority WdfIrqPriorityHigh)

Definition at line 1228 of file fxinterruptapi.cpp.

1228  {
1231  "Priority %d is out of range", priority);
1233  return;
1234  }
FxVerifierDbgBreakPoint(pFxDriverGlobals)
WDF_INTERRUPT_PRIORITY priority
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)

◆ if() [20/20]

if ( processorSet->Reserved [0] = 0 || processorSet->Reserved[1] != 0 || processorSet->Reserved[2] != 0)

Definition at line 1236 of file fxinterruptapi.cpp.

1237  {
1240  "TargetProcessorSet's reserved fields are not zero");
1242  return;
1243  }
FxVerifierDbgBreakPoint(pFxDriverGlobals)
#define TRACE_LEVEL_ERROR
Definition: storswtr.h:27
PFX_DRIVER_GLOBALS pFxDriverGlobals
#define TRACINGPNP
Definition: dbgtrace.h:67
DoTraceLevelMessage(pFxDriverGlobals, TRACE_LEVEL_VERBOSE, TRACINGPNP, "Enter, WDFDEVICE %p", Device)

◆ processorSet()

RtlZeroMemory& processorSet ( processorSet  )

◆ RtlCopyMemory()

RtlCopyMemory ( Info  ,
pFxInterrupt->  GetInfo(),
size   
)

Referenced by if().

◆ SetPolicy() [1/2]

pFxInterrupt SetPolicy ( Policy  ,
Priority  ,
processorSet 
)

◆ SetPolicy() [2/2]

pFxInterrupt SetPolicy ( policy  ,
priority  ,
processorSet   
)

◆ Synchronize()

return pFxInterrupt Synchronize ( Callback  ,
Context   
)

◆ WdfInterruptGetDevice()

WDFDEVICE STDCALL WDFEXPORT() WdfInterruptGetDevice ( __in PWDF_DRIVER_GLOBALS  DriverGlobals,
__in WDFINTERRUPT  Interrupt 
)

Definition at line 1051 of file fxinterruptapi.cpp.

1074 {
1075  DDI_ENTRY();
1076 
1078 
1080  Interrupt,
1082  (PVOID*)&pFxInterrupt);
1083 
1084  return pFxInterrupt->GetDevice()->GetHandle();
1085 }
#define DDI_ENTRY()
Definition: fxglobalskm.h:56
WDFDEVICE __inline GetHandle(VOID)
Definition: fxdevice.hpp:237
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFINTERRUPT * Interrupt
Definition: wdfinterrupt.h:372
DriverGlobals
CfxDevice * GetDevice(VOID)
FxInterrupt * pFxInterrupt
FxObjectHandleGetPtr(GetFxDriverGlobals(DriverGlobals), Interrupt, FX_TYPE_INTERRUPT,(PVOID *)&pFxInterrupt)
__inline PFX_DRIVER_GLOBALS GetFxDriverGlobals(__in PWDF_DRIVER_GLOBALS DriverGlobals)
Definition: fxglobals.h:597

◆ WdfInterruptQueueDpcForIsr()

BOOLEAN STDCALL WDFEXPORT() WdfInterruptQueueDpcForIsr ( __in PWDF_DRIVER_GLOBALS  DriverGlobals,
__in WDFINTERRUPT  Interrupt 
)

Definition at line 623 of file fxinterruptapi.cpp.

648 {
649  DDI_ENTRY();
650 
652 
654  Interrupt,
656  (PVOID*)&pFxInterrupt);
657 
659 }
#define DDI_ENTRY()
Definition: fxglobalskm.h:56
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFINTERRUPT * Interrupt
Definition: wdfinterrupt.h:372
DriverGlobals
__inline BOOLEAN QueueDeferredRoutineForIsr(VOID)
FxInterrupt * pFxInterrupt
FxObjectHandleGetPtr(GetFxDriverGlobals(DriverGlobals), Interrupt, FX_TYPE_INTERRUPT,(PVOID *)&pFxInterrupt)
__inline PFX_DRIVER_GLOBALS GetFxDriverGlobals(__in PWDF_DRIVER_GLOBALS DriverGlobals)
Definition: fxglobals.h:597

◆ WdfInterruptQueueWorkItemForIsr()

BOOLEAN STDCALL WDFEXPORT() WdfInterruptQueueWorkItemForIsr ( __in PWDF_DRIVER_GLOBALS  DriverGlobals,
__in WDFINTERRUPT  Interrupt 
)

Definition at line 663 of file fxinterruptapi.cpp.

689 {
690  DDI_ENTRY();
691 
693 
695  Interrupt,
697  (PVOID*)&pFxInterrupt);
698 
700 }
#define DDI_ENTRY()
Definition: fxglobalskm.h:56
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFINTERRUPT * Interrupt
Definition: wdfinterrupt.h:372
DriverGlobals
FxInterrupt * pFxInterrupt
FxObjectHandleGetPtr(GetFxDriverGlobals(DriverGlobals), Interrupt, FX_TYPE_INTERRUPT,(PVOID *)&pFxInterrupt)
BOOLEAN QueueWorkItemForIsr(VOID)
__inline PFX_DRIVER_GLOBALS GetFxDriverGlobals(__in PWDF_DRIVER_GLOBALS DriverGlobals)
Definition: fxglobals.h:597

◆ WdfInterruptWdmGetInterrupt()

_Must_inspect_result_ struct _KINTERRUPT* STDCALL WDFEXPORT() WdfInterruptWdmGetInterrupt ( __in PWDF_DRIVER_GLOBALS  DriverGlobals,
__in WDFINTERRUPT  Interrupt 
)

Definition at line 953 of file fxinterruptapi.cpp.

974 {
975  DDI_ENTRY();
976 
978 
980  Interrupt,
982  (PVOID*)&pFxInterrupt);
983 
984  return pFxInterrupt->GetInterruptPtr();
985 }
#define DDI_ENTRY()
Definition: fxglobalskm.h:56
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ WDFINTERRUPT * Interrupt
Definition: wdfinterrupt.h:372
DriverGlobals
FxInterrupt * pFxInterrupt
FxObjectHandleGetPtr(GetFxDriverGlobals(DriverGlobals), Interrupt, FX_TYPE_INTERRUPT,(PVOID *)&pFxInterrupt)
__inline PFX_DRIVER_GLOBALS GetFxDriverGlobals(__in PWDF_DRIVER_GLOBALS DriverGlobals)
Definition: fxglobals.h:597
struct _KINTERRUPT * GetInterruptPtr(VOID)

Variable Documentation

◆ Attributes

◆ Callback

Definition at line 709 of file fxinterruptapi.cpp.

◆ Configuration

◆ Context

Initial value:
{
#define DDI_ENTRY()
Definition: fxglobalskm.h:56

Definition at line 736 of file fxinterruptapi.cpp.

◆ Device

Definition at line 198 of file fxinterruptapi.cpp.

◆ devicePnpState

devicePnpState = pDevice->GetDevicePnpState()

Definition at line 238 of file fxinterruptapi.cpp.

◆ else

else
Initial value:
{
struct _WDF_INTERRUPT_CONFIG_V1_9 WDF_INTERRUPT_CONFIG_V1_9
ULONG expectedConfigSize

Definition at line 255 of file fxinterruptapi.cpp.

◆ expectedConfigSize

ULONG expectedConfigSize

Definition at line 239 of file fxinterruptapi.cpp.

Referenced by if().

◆ Info

Initial value:
{
#define DDI_ENTRY()
Definition: fxglobalskm.h:56

Definition at line 1014 of file fxinterruptapi.cpp.

◆ intConfig

Definition at line 240 of file fxinterruptapi.cpp.

Referenced by if().

◆ Interrupt

__in WDFINTERRUPT Interrupt
Initial value:
{
#define DDI_ENTRY()
Definition: fxglobalskm.h:56

Definition at line 230 of file fxinterruptapi.cpp.

◆ Mask

Definition at line 1152 of file fxinterruptapi.cpp.

Referenced by $include(), __ll_lshift(), __ll_rshift(), __ull_rshift(), _BitScanForward(), _BitScanReverse(), _CountLeadingZeros(), _CountTrailingZeros(), _HalpDismissIrqGeneric(), _HalpDismissIrqLevel(), AcpiExInsertIntoField(), AcpiExWriteWithUpdateRule(), AcpiRsDecodeBitmask(), AcpiRsEncodeBitmask(), addIPAddress(), BitScanForward(), BitScanReverse(), CallDibStretchBlt(), co_IntGetScrollInfo(), co_IntTranslateAccelerator(), ConsoleFirmwareTextSetState(), ConsoleGraphicalSetTextState(), ConsoleTextLocalSetTextState(), d3dcompiler_parse_signature(), DECLSPEC_ALIGN(), doSymEnumSymbols(), doSymSearch(), DrvBitBlt(), EngStretchBlt(), EngStretchBltROP(), ExDupHandleTable(), GetBitValue(), HalEndSystemInterrupt2(), HalpDispatchInterrupt2(), HalpEndSoftwareInterrupt2(), HidParser_SignRange(), i8042MouHandleButtons(), IntGdiCreateMaskFromRLE(), KeFindConfigurationNextEntry(), KeStartThread(), KfLowerIrql(), KiNpxHandler(), KiRecordDr7(), LdrpSnapThunk(), MiniportHandleInterrupt(), NEWco_IntGetScrollInfo(), NewCtxInit(), NtGdiEngStretchBlt(), NtQueryDebugFilterState(), NtSetDebugFilterState(), PciIsSuiteVersion(), PciSize(), RcvBufRegisterMask(), read_bitmap_patterns(), read_metadata_patterns(), RtlClearBits(), RtlSetBits(), SepPropagateAcl(), SetBitValue(), sym_enum(), SymEnumSourceFiles(), SymEnumSourceFilesW(), SymEnumSymbols(), SymEnumSymbolsW(), SymSearch(), SymSearchW(), test_componentinfo(), test_FileContents1(), test_FileContents2(), test_FileDescriptor(), test_FileDescriptor_Folder(), test_pack_ACCESS_ALLOWED_ACE(), test_pack_ACCESS_DENIED_ACE(), test_pack_SYSTEM_ALARM_ACE(), test_pack_SYSTEM_AUDIT_ACE(), UDFBuildHashEntry(), VCheckAcl__(), VGADDI_BltBrush(), VGADDI_BltMask(), VGADDI_BltPointerToVGA(), WTSWaitSystemEvent(), and XboxVideoOutputChar().

◆ pDevice

FxDevice* pDevice

Definition at line 235 of file fxinterruptapi.cpp.

◆ pFxDriverGlobals

PFX_DRIVER_GLOBALS pFxDriverGlobals = NULL

Definition at line 233 of file fxinterruptapi.cpp.

Referenced by if().

◆ pFxInterrupt

◆ Policy

Definition at line 1094 of file fxinterruptapi.cpp.

◆ policy

◆ PolicyAndGroup

Initial value:
{
#define DDI_ENTRY()
Definition: fxglobalskm.h:56

Definition at line 1189 of file fxinterruptapi.cpp.

◆ pParent

FxObject* pParent

Definition at line 236 of file fxinterruptapi.cpp.

Referenced by if().

◆ Priority

◆ priority

priority = PolicyAndGroup->Priority

Definition at line 1196 of file fxinterruptapi.cpp.

Referenced by bind_callback_GetPriority(), BindProtocol_StartEx(), component_SetCurrentPriority(), d3d8_indexbuffer_GetPriority(), d3d8_indexbuffer_SetPriority(), d3d8_texture_2d_SetPriority(), d3d8_texture_3d_SetPriority(), d3d8_texture_cube_SetPriority(), d3d8_vertexbuffer_GetPriority(), d3d8_vertexbuffer_SetPriority(), d3d9_device_GetGPUThreadPriority(), d3d9_device_SetGPUThreadPriority(), d3d9_indexbuffer_GetPriority(), d3d9_indexbuffer_SetPriority(), d3d9_surface_SetPriority(), d3d9_texture_2d_SetPriority(), d3d9_texture_3d_SetPriority(), d3d9_texture_cube_SetPriority(), d3d9_vertexbuffer_GetPriority(), d3d9_vertexbuffer_SetPriority(), d3dx9_animation_controller_SetTrackPriority(), ddraw_surface7_GetPriority(), ddraw_surface7_SetPriority(), DECLARE_INTERFACE_(), do_test_about_protocol(), do_write_file(), do_write_file_prealloc(), DoSetPriority(), downloadcb_GetPriority(), IDirectPlay4AImpl_SendEx(), IDirectPlay4Impl_SendEx(), if(), InstallEngine_SetAction(), InternetSetOptionW(), iso9660_file_length(), map_user_buffer(), midi_IDirectMusicPort_GetChannelPriority(), midi_IDirectMusicPort_SetChannelPriority(), prepare_raid5_write(), prepare_raid6_write(), read_data(), ServiceTransferRequest(), SetPriorityData(), SlideWindow(), SynthPortImpl_IDirectMusicPort_GetChannelPriority(), SynthPortImpl_IDirectMusicPort_SetChannelPriority(), TCPSleep(), test_CreateBinding(), test_priority(), test_query_process_priority(), test_res_protocol(), timelinegrp_GetPriority(), TransferPktComplete(), wined3d_resource_set_priority(), write_data(), write_data_complete(), xsltAddTemplate(), xsltGetTemplate(), and xsltParseStylesheetTemplate().

◆ processorSet

PGROUP_AFFINITY processorSet = NULL

Definition at line 1126 of file fxinterruptapi.cpp.

◆ return

return

Definition at line 1041 of file fxinterruptapi.cpp.

◆ size

ULONG size = 0

Definition at line 1019 of file fxinterruptapi.cpp.

◆ Size

Definition at line 1046 of file fxinterruptapi.cpp.

◆ status

Initial value:
Configuration->AutomaticSerialization ?
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_INTERRUPT_CONFIG Configuration
Definition: wdfinterrupt.h:372
_Must_inspect_result_ NTSTATUS FxValidateObjectAttributes(__in PFX_DRIVER_GLOBALS FxDriverGlobals, __in PWDF_OBJECT_ATTRIBUTES Attributes, __in ULONG Flags=FX_VALIDATE_OPTION_NONE_SPECIFIED)
PFX_DRIVER_GLOBALS pFxDriverGlobals
_Must_inspect_result_ _In_ WDFDMAENABLER _In_ _In_opt_ PWDF_OBJECT_ATTRIBUTES Attributes

Definition at line 237 of file fxinterruptapi.cpp.

Referenced by _Requires_lock_held_(), _Requires_lock_not_held_(), and if().

◆ TargetProcessorSet

Initial value:
{
#define DDI_ENTRY()
Definition: fxglobalskm.h:56

Definition at line 1121 of file fxinterruptapi.cpp.