Warner Losh wrote:
> In message <[email protected]> "Daniel J. O'Connor" writ
    es:
> : I don't suppose someone could post an explanation of how kernel threads wor
    k
> : could they? :)
> 
> Looks like it just does a fork like thing so it can do context
> switches...
> 
> Warner

When I looked last time, it was effectively a callable interface to what we
do from SYSINIT_KT(), ie: fork proc0, which runs in kernel space with it's
own stack etc.

kthread_create_deferred() is not really anything to do with those sort of
threads.  It's just a generic callback registration system that happens to
be called after the basic processes have started so that proc0,1,2 etc are
not disturbed.  It's similar to the config_intrhook() stuff but is run
later.

You can probably cut/paste our SYSINIT_KT() code into some compatable
function interfaces pretty easily to avoid yet another new file.

Cheers,
-Peter
--
Peter Wemm - [email protected]; [email protected]; [email protected]



To Unsubscribe: send mail to [email protected]
with "unsubscribe freebsd-hackers" in the body of the message

Reply via email to