Subject: cpu_fork(), it bends my brain
To: None <port-vax@netbsd.org>
From: Jason R Thorpe <thorpej@zembu.com>
List: port-vax
Date: 05/24/2000 22:38:50
Hi folks...

I'm hoping that someone here (HI RAGGE! :-) can explain to me how
the VAX port's cpu_fork() works.  I've figured out cpu_fork() on
every other patform, but the VAX has me stumped.

In particular, almost every other platform has a child_return that
is used to dump the process into userspace for the first time.

However, on the VAX, it sems to be "Go directly to userspace, do
not pass GO, do not collect $200."  Now, cpu_set_kpc() does reference
`sret' (eek, some historical name?) ... however, all users of
cpu_set_kpc() never return to userspace ... aaaaaah, except for
start_init()!

Ok, so is it the case that init's PCB is used to seed all of the
others in cpu_fork()?

Basically, I'm needing to eliminate cpu_set_kpc() (sort of) -- cpu_fork()
needs to take the function and argument to eliminate a race in a
multiprocessor environment.

Thanks for any enlightenment you can provide.

-- 
        -- Jason R. Thorpe <thorpej@zembu.com>