StorPortSetPriorityThread - NtDoc

Native API online documentation, based on the System Informer (formerly Process Hacker) phnt headers
// storport.h

ULONG StorPortSetPriorityThread(
  [in] PVOID                HwDeviceExtension,
  [in] PVOID                ThreadContext,
  [in] STOR_THREAD_PRIORITY Priority
);
View the official Windows Driver Kit DDI reference

NtDoc

No description available.

Windows Driver Kit DDI reference (nf-storport-storportsetprioritythread)

Description

StorPortSetPriorityThread sets the run-time priority of a miniport-created thread.

Parameters

HwDeviceExtension [in]

Pointer to the miniport's hardware device extension.

ThreadContext [in]

Pointer to the thread context received in a prior call to StorPortCreateSystemThread.

Priority [in]

A STOR_THREAD_PRIORITY enum value that specifies the thread priority to set.

Return value

StorPortSetPriorityThread returns one of the following values:

Return code Description
STOR_STATUS_SUCCESS The specified thread priority was set successfully.
STOR_STATUS_INVALID_IRQL IRQL level must equal PASSIVE_LEVEL.
STOR_STATUS_INVALID_PARAMETER One or more of the provided parameters are invalid.
STOR_STATUS_UNSUCCESSFUL Returned for other internal system reasons.

Remarks

A miniport can call StorPortSetPriorityThread to change the priority of the thread specified by ThreadContext.

Threads, whatever their respective run-time priorities, are run at IRQL = PASSIVE_LEVEL. See Thread Priorities for more information.

A miniport should specify a thread priority value that avoids run-time priority inversions. See Device-dedicated Threads for more information.

See also

STOR_THREAD_PRIORITY

StorPortCreateSystemThread