Windows System Software -- Consulting, Training, Development -- Unique Expertise, Guaranteed Results

Home NTDEV

Before Posting...

Please check out the Community Guidelines in the Announcements and Administration Category.

More Info on Driver Writing and Debugging


The free OSR Learning Library has more than 50 articles on a wide variety of topics about writing and debugging device drivers and Minifilters. From introductory level to advanced. All the articles have been recently reviewed and updated, and are written using the clear and definitive style you've come to expect from OSR over the years.


Check out The OSR Learning Library at: https://www.osr.com/osr-learning-library/


Timeout for IRPs in Manual Queue

remyavu10remyavu10 Member Posts: 63
edited August 3 in NTDEV

For UMDF based Virtual Serial Driver, I am checking to implement read timeouts.

In IO Read routine, if data not available to read, IRPs are put into a manual queue using WdfRequestForwardToIoQueue. Later when data is available from backend IPC, the IRPs are fetched from manual queue and read request completes.

I am trying to check if there any way so that IRPs which are in manual queue shall be completed (may be automatically OR getting some callback notification) after some time (timeout condition).

I saw some option like:

WDF_REQUEST_SEND_OPTIONS syncReqOptions;

WDF_REQUEST_SEND_OPTIONS_INIT(
&syncReqOptions,
0
);
WDF_REQUEST_SEND_OPTIONS_SET_TIMEOUT(
&syncReqOptions,
WDF_REL_TIMEOUT_IN_SEC(10)
);

I tried, but did not get much details on how to use 'syncReqOptions' so that IRPs in manual queue got finished/timeout-out when timeout happens.

Does any one has any idea?

Thanks,
Prasanth

Post edited by remyavu10 on

Comments

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. Sign in or register to get started.

Upcoming OSR Seminars
OSR has suspended in-person seminars due to the Covid-19 outbreak. But, don't miss your training! Attend via the internet instead!
Kernel Debugging 30 January 2023 Live, Online
Developing Minifilters 20 March 2023 Live, Online
Writing WDF Drivers TBD 2023 Live, Online
Internals & Software Drivers 17 April 2023 Live, Online