Bewerken

Delen via


ReqCompletionRoutine rule (kmdf)

The ReqCompletionRoutine rule specifies that a completion routine must be set before a request is sent to an I/O target.

If a request is not sent synchronously, or is not sent as send and forget, (specified by the WDF_REQUEST_SEND_OPTION_SEND_AND_FORGET flag), the driver should set a completion routine so that the I/O target can notify the driver when the request is completed.

Driver model: KMDF

How to test

At compile time

Run Static Driver Verifier and specify the ReqCompletionRoutine rule.

Use the following steps to run an analysis of your code:
  1. Prepare your code (use role type declarations).
  2. Run Static Driver Verifier.
  3. View and analyze the results.

For more information, see Using Static Driver Verifier to Find Defects in Drivers.

Applies to

WdfRequestSend WdfRequestSetCompletionRoutine

See also

Completing I/O Requests Synchronizing Cancel and Completion Code WDF_REQUEST_SEND_OPTIONS_FLAGS WDF_REQUEST_SEND_OPTIONS