System Worker Threads

Somewhere I have read that all system worker threads ( who call the
drivers callback upon the call to ‘ExQueueWorkItem’ ) are shared among all
drivers within a particular group ( QueueType !? ).

My questions :

  1. how many ‘system worker threads’ are available, or are all
    driver-callbacks for a particular group serialized by the OS ?

  2. Can I lower my callback priority excution within this callback by means
    of calling ‘KeSetBasePriorityThread’? Calling ‘KeSetBasePriorityThread’
    within a private thread created by means of ‘PsCreateSystemThread’ is
    possible …

Christiaan

603-321-1032
“Ghijselinck” wrote in message
news:xxxxx@ntdev…

> 1. how many ‘system worker threads’ are available, or are all
> driver-callbacks for a particular group serialized by the OS ?
>

A small number per queue, but starting with w2k, new threads may be added if
the executive decides that they are needed (for example to prevent
deadlock.)

Only N-cpu threads will run per queue at any time.

> 2. Can I lower my callback priority excution within this callback by means
> of calling ‘KeSetBasePriorityThread’? Calling ‘KeSetBasePriorityThread’
> within a private thread created by means of ‘PsCreateSystemThread’ is
> possible …
>

Well you can, although this is unusual, I have no idea what the implications
are.


===
Mark Roddy
Consultant, Microsoft DDK MVP
Hollis Technology Solutions
xxxxx@hollistech.com
www.hollistech.com
For Windows Driver training see www.azius.com

> 1. how many ‘system worker threads’ are available,

Some static number on NT4, dynamically growing pool on w2k.

or are all
driver-callbacks for a particular group serialized by the OS ?

No.

  1. Can I lower my callback priority excution within this callback by means
    of calling ‘KeSetBasePriorityThread’?

If you have a thread handle - yes, but it is better to not do this on NT4, since this can cause priority inversion.

Max