| Age | Commit message (Collapse) | Author |
|
|
|
also s/beyound/beyond/ and few others along the way, mainly in comments.
|
|
In one comment I assume that it was meant to be pull-up resistor.
|
|
implementation visibility of these relocations.
Currently all implementations resolve local symbol relocations in the first
pass and simply skip them in the second. The RISC-V implementation will
make use of this visiblity.
|
|
When we are triggering a softint, it can't already hold any mutexes.
So any path to mutex_exit(mtx) must go via mutex_enter(mtx), which is
always done with atomic r/m/w, and we need not issue any explicit
barrier between ci->ci_curlwp = softlwp and a potential load of
mtx->mtx_owner in mutex_exit.
PR kern/57240
XXX pullup-8
XXX pullup-9
XXX pullup-10
|
|
Details in comments.
PR kern/57240
XXX pullup-8
XXX pullup-9
XXX pullup-10
|
|
No functional change intended.
|
|
XXX pullup-8
XXX pullup-9
XXX pullup-10
|
|
- Ensure always at end
- Use tab rather than spaces
- Add consistent comment
"Pull in optional local configuration - always at end"
The only functional change is that a local file which tried to
override an existing setting (eg with "no foo") would have failed
in some cases before, but now will work
|
|
Where a GENERIC config had an existing inclusion of GENERIC.local,
ensure it is always at the end of the file, with a consistent
comment:
# Pull in optional local configuration
cinclude "arch/landisk/conf/GENERIC.local"
This allows GENERIC.local to correctly override all options
(This pass does not affect any GENERIC which did not already have
an include of GENERIC.local)
|
|
the next page boundary gives 0 and instead make the VA space end one
page earlier.
Fixes PR sparc64/57219.
|
|
Makes crash(8) and ddb match, and avoids crashing in ddb when you
feed in a bad lwp pointer!
|
|
No functional change intended.
|
|
|
|
|
|
This can be included unconditionally, and db_active can then be
queried unconditionally; if DDB is not in the kernel, then db_active
is a constant zero. Reduces need for #include opt_ddb.h, #ifdef DDB.
|
|
|
|
Plus a handful of others that I'm familiar with. Lots of special-
purpose kernels should probably have this too but I'm not going
through all the arm, mips, and ppc evaluation board kernels to see
which ones are relevant.
Omitted from systems I know to be very small:
- sun2/GENERIC
- dreamcast/GENERIC
Feel free to remove it from others that need to be kept smaller.
Compile-tested a few of these just in case:
- alpha/GENERIC
- amd64/GENERIC
- evbmips/OCTEON
- i386/GENERIC
- riscv/GENERIC
PR kern/29702
|
|
|
|
- Enable UFS_DIRHASH if the architecture or kernel model specific config
file can use 128MB of RAM or more.
- Remove experimental tag from UFS_DIRHASH; it's been with RUMP kernel
and by a number of NetBSD developers for years.
- Add LFS_DIRHASH if LFS was enabled.
- Be somewhat consistent with FS options order.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
i had a sunblade 2500 reset with this trap recently, and the
manual says it should have been recoverable. in particular,
the US IIIv2 manual says in section 12.4.4.2 that the i-cache
won't see this data ever (so nothing needed there), and that
the d-cache needs to be disabled, and all the entries flushed,
and then re-enabled.
tested with a "trap 0x70" from kernel space, that trap.c
converted the "0x170" back to "0x70" (with an ADVANCE). this
code not commited.
|
|
|
|
This unbreaks miniroot.fs.
Thanks to Björn Johannesson for originally pointing this out and to
mrg@ for pointing out the actual issue and suggesting a fix.
|
|
|
|
|
|
This just goes through my recent reference count membar audit and
changes membar_exit to membar_release and membar_enter to
membar_acquire -- this should make everything cheaper on most CPUs
without hurting correctness, because membar_acquire is generally
cheaper than membar_enter.
|
|
|
|
Will be touching many of these files soon for functional changes.
No functional change intended.
|
|
way".
|
|
|
|
If two threads are using an object that is freed when the reference
count goes to zero, we need to ensure that all memory operations
related to the object happen before freeing the object.
Using an atomic_dec_uint_nv(&refcnt) == 0 ensures that only one
thread takes responsibility for freeing, but it's not enough to
ensure that the other thread's memory operations happen before the
freeing.
Consider:
Thread A Thread B
obj->foo = 42; obj->baz = 73;
mumble(&obj->bar); grumble(&obj->quux);
/* membar_exit(); */ /* membar_exit(); */
atomic_dec -- not last atomic_dec -- last
/* membar_enter(); */
KASSERT(invariant(obj->foo,
obj->bar));
free_stuff(obj);
The memory barriers ensure that
obj->foo = 42;
mumble(&obj->bar);
in thread A happens before
KASSERT(invariant(obj->foo, obj->bar));
free_stuff(obj);
in thread B. Without them, this ordering is not guaranteed.
So in general it is necessary to do
membar_exit();
if (atomic_dec_uint_nv(&obj->refcnt) != 0)
return;
membar_enter();
to release a reference, for the `last one out hit the lights' style
of reference counting. (This is in contrast to the style where one
thread blocks new references and then waits under a lock for existing
ones to drain with a condvar -- no membar needed thanks to mutex(9).)
I searched for atomic_dec to find all these. Obviously we ought to
have a better abstraction for this because there's so much copypasta.
This is a stop-gap measure to fix actual bugs until we have that. It
would be nice if an abstraction could gracefully handle the different
styles of reference counting in use -- some years ago I drafted an
API for this, but making it cover everything got a little out of hand
(particularly with struct vnode::v_usecount) and I ended up setting
it aside to work on psref/localcount instead for better scalability.
I got bored of adding #ifdef __HAVE_ATOMIC_AS_MEMBAR everywhere, so I
only put it on things that look performance-critical on 5sec review.
We should really adopt membar_enter_preatomic/membar_exit_postatomic
or something (except they are applicable only to atomic r/m/w, not to
atomic_load/store_*, making the naming annoying) and get rid of all
the ifdefs.
|
|
as well shared and recently fixed typos in OpenBSD code by Jonathan Grey.
|
|
|
|
from which the newly created handle will inherit it's implementation.
The root implementation for a new handle type is used if an invalid
"super handle" is passed.
|
|
our own node; use device_handle(self) instead.
|
|
|
|
|
|
|
|
Note that the sun4v_intr_devino_to_sysino() function is adapted to match OpenBSD version 1.57 (the introduction of INTR_DEVINO is done in revision 1.58)
|
|
|
|
|
|
If we're in ddb, the scheduler and all other CPUs are quiesced
anyway. But suspendsched will try to take an adaptive lock, which
causes it to crash and re-enter ddb, which isn't very useful for
rebooting.
|
|
another copyright claim line. again. (i did this in 2008 and then
did not update all of my personal templates.)
|