Should fix PR/36939 and make the rlimit code MP safe.
Posted for comment to tech-kern (non received!)
The p_limit field (for a process) is only be changed once (on the first
write), and a reference to the old structure is kept (for code paths
that have cached the pointer).
Only p->p_limit is now locked by p->p_mutex, and since the referenced memory
will not go away, is only needed if the pointer is to be changed.
The contents of 'struct plimit' are all locked by pl_mutex, except that the
code doesn't bother to acquire it for reads (which are basically atomic).
Add FORK_SHARELIMIT that causes fork1() to share the limits between parent
and child, use it for the IRIX_PR_SULIMIT.
Fix borked test for both IRIX_PR_SUMASK and IRIX_PR_SDIR being set.
Clamp b_resid to b_bcount in case the info field is larger. Fix a KASSERT
in physio() when a media error occurs on my SDLT320 drive (maybe this drive
is bogus for not setting the highter bits to 0 in the INFO field in this
case).
and there's no intermediate sequence point! We actually hit this on
sh3 with -O2 where gcc4 caches tlst in a register prior to recursive
call to inptype() and if you are unlucky the recursive call needs to
realloc tlst.
Introduce a temp variable to force a sequence point.
locked. Ideally the function should be rewritten to do things in
a different order, but this tries to keep changes minimal aiming
for a possible netbsd-4 pullup.
fixes PR kern/37034
1) Move a magic number writing code.
Fix a watchdog timeout and "block failed to stop" problem on BCM5701 B5 card.
2) Fix incorrect register write.
Fix a watchdog timeout "block failed to stop" problem on BCM5700 B2 card.
3) Wait more long time for PCISTATE register to return to its original
pre-reset state.
Fix "pcistate failed to revert" problem on BCM5703 A2 card.
kernel to the file server for silly things the file server did,
e.g. attempting to create a file with size VSIZENOTSET. The file
server can handle these as it chooses, but the default action is
for it to throw its hands in the air and sing "goodbye, cruel world,
it's over, walk on by".
a number of changes have been made for LKM and
preemption safety. [ad 20070927]
i386: i386 bootblocks are now able to boot amd64 kernels.
support for a.out kernels has been removed [ad 20070927]