The FltApplyPriorityInfoThread routine is used by a minifilter driver to apply priority information to a thread.
NTSTATUS FLTAPI FltApplyPriorityInfoThread( PIO_PRIORITY_INFO InputPriorityInfo, PIO_PRIORITY_INFO OutputPriorityInfo, PETHREAD Thread );
A pointer to an IO_PRIORITY_INFO structure that is used to set the priority state of the given thread. This IO_PRIORITY_INFO structure must have its members set by an appropriate routine - see the following Remarks section. This parameter is required and cannot be NULL.
An optional pointer to an IO_PRIORITY_INFO structure used to receive the priority state of the thread before the InputPriorityInfo priority information is applied to the thread by FltApplyPriorityInfoThread. This parameter is optional and can be NULL.
A pointer to the thread in which to apply the InputPriorityInfo priority information to. This parameter is required and cannot be NULL.
If the thread priority information, pointed to by the InputPriorityInfo parameter, is successfully applied to the given thread, the FltApplyPriorityInfoThread routine returns STATUS_SUCCESS. Otherwise, it returns an appropriate NTSTATUS value, such as one of the following:
||The structure pointed to by the InputPriorityInfo parameter was initialized but one or more of its member values are invalid. This is an error code.|
This routine is available starting with Windows Vista.
The FltApplyPriorityInfoThread routine sets the I/O priority, paging priority and thread priority of the given thread based on the member values of the IO_PRIORITY_INFO structure pointed to by the InputPriorityInfo parameter. This allows a previously saved set of priority information, acquired by the FltRetrieveIoPriorityInfo or FltApplyPriorityInfoThread routine, to be applied to a thread.
The original values of the target thread, before the InputPriorityInfo priority values are applied by the FltApplyPriorityInfoThread routine, can be saved if a valid OutputPriorityInfo pointer is supplied. Note that the structure pointed to by the OutputPriorityInfo parameter need not be initialized.
It is safe to provide the same pointer to a single IO_PRIORITY_INFO structure for both the InputPriorityInfo and OutputPriorityInfo parameters.
- Call the FltRetrieveIoPriorityInfo routine.
- Ensure that the current InputPriorityInfo parameter was the OutputPriorityInfo parameter in a prior call to the FltApplyPriorityInfoThread routine.
|Windows version||Available in Microsoft Windows Vista and later versions of Windows operating systems.|
|Header||fltkernel.h (include Fltkernel.h)|