Home | History | Annotate | Download | only in libsysproxy
History log of /src/sys/rump/kern/lib/libsysproxy/sysproxy.c
RevisionDateAuthorComments
 1.10  16-Jul-2023  riastradh rump: Use l_sched.info, not l_private, for cv waits.

- l_sched is scheduler-private, used only by sched_m2.c, should be safe
- l_private is lwp-private, used by tls in user threads, would like to
reuse for kthreads too
 1.9  21-Aug-2022  riastradh rump libsysproxy: More workarounds for pmap abuse.
 1.8  06-Oct-2019  uwe xc_barrier - convenience function to xc_broadcast() a nop.

Make the intent more clear and also avoid a bunch of (xcfunc_t)nullop
casts that gcc 8 -Wcast-function-type is not happy about.
 1.7  17-May-2019  ozaki-r Implement an aggressive psref leak detector

It is yet another psref leak detector that enables to tell where a leak occurs
while a simpler version that is already committed just tells an occurrence of a
leak.

Investigating of psref leaks is hard because once a leak occurs a percpu list of
psref that tracks references can be corrupted. A reference to a tracking object
is memorized in the list via an intermediate object (struct psref) that is
normally allocated on a stack of a thread. Thus, the intermediate object can be
overwritten on a leak resulting in corruption of the list.

The tracker makes a shadow entry to an intermediate object and stores some hints
into it (currently it's a caller address of psref_acquire). We can detect a
leak by checking the entries on certain points where any references should be
released such as the return point of syscalls and the end of each softint
handler.

The feature is expensive and enabled only if the kernel is built with
PSREF_DEBUG.

Proposed on tech-kern
 1.6  19-Apr-2019  ozaki-r Implement a simple psref leak detector

It detects leaks by counting up the number of held psref by an LWP and checking
its zeroness at the end of syscalls and softint handlers. For the counter, a
unused field of struct lwp is reused.

The detector runs only if DIAGNOSTIC is turned on.
 1.5  18-Apr-2019  ozaki-r rump: add missing sanity checks at the end of syscalls
 1.4  26-Jan-2016  pooka branches: 1.4.16; 1.4.20;
Put the kernelside rump kernel headers into <rump-sys> instead of
sprinkling them around the faction directories. Avoids having
to add a CPPFLAGS (or several) to pretty much every component
Makefile.

Leave compat headers around in the old locations.

The commit changes some autogenerated files, but I'll fix the
generators shortly and regen.
 1.3  18-Apr-2015  pooka Give remote clients struct pmap storage. Although the pmap is unused,
that way we can sure that the pmap macro framework doesn't access all
the wrong places.
 1.2  03-Apr-2015  pooka branches: 1.2.2;
Use a different vmspace for rump kernel proc0 and local clients.
While the rump kernel and local clients are by definition in the same
host vmspace, there are subtle differences in how in-kernel code works
in case accessing the kernel vmspace or a user process vmspace.

Problem discovered by riastradh's "read(fd, NULL, 1)" test.
 1.1  07-Jan-2015  pooka Move sysproxy support into a separate component, rumpkern_sysproxy,
instead of it being always provided by the rump kernel base. This
move accomplishes two things:

1) it is no longer necessary to provide sysproxy hypercall stubs for
platforms which do not want to use sysproxy
2) it is easier to reason about the security aspects, since configurations
not linking the sysproxy component simply do not support remote
system calls

discussed on rumpkernel-users
 1.2.2.4  19-Mar-2016  skrll Sync with HEAD
 1.2.2.3  06-Jun-2015  skrll Sync with HEAD
 1.2.2.2  06-Apr-2015  skrll Sync with HEAD
 1.2.2.1  03-Apr-2015  skrll file sysproxy.c was added on branch nick-nhusb on 2015-04-06 15:18:30 +0000
 1.4.20.2  13-Apr-2020  martin Mostly merge changes from HEAD upto 20200411
 1.4.20.1  10-Jun-2019  christos Sync with HEAD
 1.4.16.2  03-Dec-2017  jdolecek update from HEAD
 1.4.16.1  26-Jan-2016  jdolecek file sysproxy.c was added on branch tls-maxphys on 2017-12-03 11:39:15 +0000

RSS XML Feed