LONG
KeSetBasePriorityThread(
IN PKTHREAD Thread,
IN LONG Increment
);
KeSetBasePriorityThread sets the runtime priority, relative to the current process, for a given thread.
KeSetBasePriorityThread returns the previous base priority increment of the given thread. The previous base priority increment is defined as the difference between the specified thread’s old base priority and the base priority of the thread’s process.
The new base priority is computed by adding the given Increment, which can be a negative value, to the base priority of the specified thread’s process. The resultant value is stored as the base priority of the specified thread.
Drivers that set up device-dedicated threads with variable priority attributes can call this routine to set such a thread’s priority relative to the system process in which the thread is created.
The new base priority is restricted to the priority class of the given thread’s process. Therefore, the base priority is not allowed to cross over from a variable priority class to a real-time priority class or vice versa.
Callers of KeSetBasePriorityThread must be running at IRQL PASSIVE_LEVEL.