WdfInterruptReportActive 함수(wdfinterrupt.h)

[KMDF에만 적용]

WdfInterruptReportActive는 인터럽트가 활성 상태이며 드라이버가 연결된 줄에서 인터럽트 요청을 처리할 준비가 되었음을 시스템에 알릴 수 있습니다.

구문

void WdfInterruptReportActive(
  [in] WDFINTERRUPT Interrupt
);

매개 변수

[in] Interrupt

프레임워크 인터럽트 개체에 대한 핸들입니다.

반환 값

없음

설명

기능 상태 전원 관리를 구현하는 드라이버만 WdfInterruptReportActive를 호출합니다.

드라이버는 인터럽트를 만든 직후 WdfInterruptReportActive 를 호출할 필요가 없습니다. 드라이버는 이전에 WdfInterruptReportInactive 를 호출한 후에만 WdfInterruptReportActive를 호출해야 합니다.

일반적으로 드라이버는 상태가 0일 때 ComponentActiveConditionCallback 루틴 또는 ComponentIdleStateCallback에서 WdfInterruptReportActive를 호출합니다(F0 상태의 전체 표시).

드라이버가 Windows 8 이전의 운영 체제에서 이 메서드를 호출하는 경우 프레임워크의 검증 도구는 오류를 보고합니다.

자세한 내용은 기능 전원 상태 지원을 참조하세요.

예제

다음 예제에서는 드라이버가 KMDF 드라이버의 ComponentIdleStateCallback 루틴에서 WdfInterruptReportActive를 호출하는 방법을 보여 줍니다. 드라이버는 WdfDeviceWdmAssignPowerFrameworkSettings를 호출하여 단일 구성 요소를 등록합니다.

VOID
MyComponentIdleStateCallback(
    _In_ PVOID Context,
    _In_ ULONG Component,
    _In_ ULONG State
    )
{
    PFDO_DEVICE_DATA deviceData;
    PINTERRUPT_CONTEXT interruptContext;

    deviceData = FdoGetData((WDFDEVICE)Context);
    interruptContext = InterruptGetData(deviceData->Interrupt);

    switch (State) {
        case 0:
            if (interruptContext->ReportedInactive) {

                //
                // the interrupt was reported inactive earlier. We need to report active now.
                //
                WdfInterruptReportActive(deviceData->Interrupt);
                interruptContext->ReportedInactive = FALSE;

                //
                // Enable interrupt generation at hardware.
                // 
                WdfInterruptAcquireLock(deviceData->Interrupt);
                EnableInterruptInHardware();
                WdfInterruptReleaseLock(deviceData->Interrupt);

            }

        break;


    …

}

요구 사항

요구 사항
지원되는 최소 클라이언트 Windows 8
대상 플랫폼 유니버설
최소 KMDF 버전 1.11
머리글 wdfinterrupt.h(Wdf.h 포함)
라이브러리 Wdf01000.sys(프레임워크 라이브러리 버전 관리 참조)
IRQL <=DISPATCH_LEVEL
DDI 규정 준수 규칙 DriverCreate(kmdf)

추가 정보

WdfInterruptReportInactive