Commit Graph

196 Commits

Author SHA1 Message Date
ad a19a515177 Put kqueue/kevent back as MPSAFE. 2008-03-27 17:13:25 +00:00
yamt f725bfefcf after yamt-lazymbuf merge, mark send/recv syscalls MPSAFE.
pointed out by Andrew Doran.
2008-03-24 23:46:43 +00:00
yamt 9a4b7dd279 merge yamt-lazymbuf branch. 2008-03-24 12:24:37 +00:00
ad f5405b27b2 Unmark kevent/kqueue as MPSAFE. There seems to be some kind of deadlock
involving kernel_lock.
2008-03-22 14:20:09 +00:00
ad bc370563bc Mark kqueue/kevent MPSAFE. 2008-03-21 21:58:57 +00:00
pooka f2976c3905 Generate syscalls entry points which can be called directly without
going through a syscall trap.  These are currently useful for rumps.
As all the standard syscalls are not compiled into librump, mark
relevant ones with RUMP in syscalls.master.  To do e.g. a mkdir
"system call" from a rump, one would call

  rump_sys_mkdir("/dir", mode, &eval);

where the last value represents something to store errno into.
2008-03-11 22:50:10 +00:00
martin a8ed8bb731 Desupport compatibility for the old posix_fadvise syscall per yamt's
request and just ignore it.
2008-02-24 12:52:54 +00:00
ad 653195d46d Mark mount/unmount MPSAFE. PR kern/38034. 2008-02-15 13:09:57 +00:00
yamt 16b042cbdb from rmind@,
- revert struct sched_param changes to restore ABI.
- instead, add 'policy' arguments to _sched_{get,set}param syscalls.
  (this is an API/ABI change.)
- correct kauth_authorize_process arguments.

while i'm here,
- don't bother to kmem_alloc for 4-byte structure.
2008-02-09 16:58:01 +00:00
martin 65badb72df Version the posix_fadvise syscall and add the missing "pad" argument,
so that it does not only work on i386 (no padding) and 64bit archs (all
args padded to 64bit).
2008-01-27 16:13:39 +00:00
ad baa4a2209f Mark the extattr syscalls MPSAFE. 2008-01-25 13:38:57 +00:00
ad bbc79e58a6 Pull in my modules code for review/test/hacking. 2008-01-16 12:34:50 +00:00
rmind 5c71a4d49f Implementation of processor-sets, affinity and POSIX real-time extensions.
Add schedctl(8) - a program to control scheduling of processes and threads.

Notes:
- This is supported only by SCHED_M2;
- Migration of LWP mechanism will be revisited;

Proposed on: <tech-kern>. Reviewed by: <ad>.
2008-01-15 03:37:10 +00:00
ad fe8aceeb5e More MPSAFE syscalls. 2008-01-07 16:15:36 +00:00
ad b4284a686b Merge vmlocking2 to head. 2008-01-02 11:57:13 +00:00
dsl 7e2790cf6f Convert all the system call entry points from:
int foo(struct lwp *l, void *v, register_t *retval)
to:
    int foo(struct lwp *l, const struct foo_args *uap, register_t *retval)
Fixup compat code to not write into 'uap' and (in some cases) to actually
pass a correctly formatted 'uap' structure with the right name to the
next routine.
A few 'compat' routines that just call standard ones have been deleted.
All the 'compat' code compiles (along with the kernels required to test
build it).
98% done by automated scripts.
2007-12-20 23:02:38 +00:00
ad b668a9a05f Add _lwp_ctl() system call: provides a bidirectional, per-LWP communication
area between processes and the kernel.
2007-11-12 23:11:58 +00:00
dsl fb82085e57 Add the 'args' argument to sys_syscall and sys___syscall. 2007-11-09 14:57:33 +00:00
ad f1c6cfe4f6 Add _lwp_setname, _lwp_getname. Proposed on tech-kern. 2007-11-07 00:37:21 +00:00
rmind 2cecf9bbe9 Implementation of POSIX message queues.
Reviewed by: <ad>, <tech-kern>
2007-09-07 18:56:02 +00:00
ad df7945cf28 - Update for ktrace changes.
- Mark a few more syscalls MPSAFE.
2007-08-15 12:08:38 +00:00
ad 830ab6bb3c - Fix a bug with _lwp_park() where if the computed wakeup time was under
1 microsecond into the future, the thread could enter an untimed sleep.
- Change the signature of _lwp_park() to accept an lwpid_t and second
  hint pointer, but do so in a way that remains compatible with older
  pthread libraries. This can be used to wake another thread before the
  calling thread goes asleep, saving at least one syscall + involuntary
  context switch. This turns out to be a fairly large win on the condvar
  benchmarks that I have tried.
- Mark some more syscalls MP safe.
2007-08-07 19:00:42 +00:00
ad b9d8ad095d wait() can't yet be MPSAFE since it's impractical to hold proclist_mutex
across exit(), and so there is a short race against cv_wait_sig(). This
can be reverted when proclist_mutex/proclist_lock merge.
2007-08-07 12:48:30 +00:00
ad 9dab7d5077 gettimeofday() doesn't need locks, and MySQL seems to make heavy use of it. 2007-08-07 09:46:24 +00:00
ad e4f6da7b0c Mark the SysV semaphore syscalls MP safe. 2007-08-04 10:52:57 +00:00
joerg e4fc1154a4 Add native mremap system call based on the UVM implementation for
Linux compat. Add code to enforce alignment of the new location.
Special thanks to wizd for helping with the man page.
2007-07-17 17:42:07 +00:00
dsl 9326e3a3ef Add sys___mount50() that includes an extra parameter for thre data length.
Mark sys_mount() as COMPAT_40.
Hmmm... the aio calls should have started at 400, not 399.
I've left 407-409 free.
2007-07-14 15:38:40 +00:00
rmind 67d703cf25 Import of POSIX Asynchronous I/O.
Seems to be quite stable. Some work still left to do.

Please note, that syscalls are not yet MP-safe, because
of the file and vnode subsystems.

Reviewed by: <tech-kern>, <ad>
2007-04-30 14:44:28 +00:00
drochner 067e5852ea make the first argument to profil(2) char*, for consistency with <unistd.h> 2007-03-06 16:09:21 +00:00
christos 53524e44ef Kill caddr_t; there will be some MI fallout, but it will be fixed shortly. 2007-03-04 05:59:00 +00:00
drochner 8b8213b508 sync with lwp.h: _lwp_unpark_all() returns ssize_t 2007-02-26 12:19:00 +00:00
ad b6ab00c330 A quick hack to get things building again: put back the SA system calls
with no arguments, and alias them to sys_nosys. To be revisited.
2007-02-10 11:32:21 +00:00
ad f7c038012b Fix arguments to _lwp_park/unpark/unpark_all to match userland. 2007-02-10 10:24:44 +00:00
ad b07ec3fc38 Merge newlock2 to head. 2007-02-09 21:55:00 +00:00
ad 606e323b3e Add sched_yield(). 2007-01-16 05:28:45 +00:00
ad b9b02583e6 Add prototypes for: _lwp_kill, _lwp_detach, _lwp_park, _lwp_unpark,
_lwp_unpark_all, sched_yield.
2007-01-16 01:30:45 +00:00
christos 152eb5a9c3 according to the manual, the last argument of quotactl(2) is a void *,
not a caddr_t.
2006-10-17 15:06:18 +00:00
matt 30183e299f Don't conditionalize *sys_ptrace. The lack of sys_ptrace will be dealt
with differently.
2006-09-01 20:58:18 +00:00
matt 0cf3f9db4e Add || defined(_KERNEL) to ptrace entry (like ktrace). 2006-08-30 11:34:26 +00:00
matt 9e0ec4816e Make PTRACE and COREDUMP optional. Make the default (status quo) by putting
them in conf/std.
2006-08-29 23:34:48 +00:00
martin f956f13e21 Step 1 to make filehandles completely opaque to userland 2006-07-31 16:32:51 +00:00
martin a3b5baed42 Fix alignement problems for fhandle_t, exposed by gcc4.1.
While touching all vptofh/fhtovp functions, get rid of VFS_MAXFIDSIZ,
version the getfh(2) syscall and explicitly pass the size available in
the filehandle from userland.

Discussed on tech-kern, with lots of help from yamt (thanks!).
2006-07-13 12:00:24 +00:00
mrg e2eb31d3a3 version the socket(2) syscall. for compat30 socket, we use
EPROTONOSUPPORT instead of EAFNOSUPPORT.

from pavel@ with a little bit of clean up from myself.

XXX: netbsd32 (and perhaps other emulations) should be able
XXX: to call the standard socket calls for this i think, but
XXX: revisit this at another time.
2006-06-26 21:23:56 +00:00
drochner 42a3bd3098 Extend "struct ntptimeval" for the needs of "timecounters".
Allocate a new syscall for ntp_gettime() and set up COMPAT_30 for
the old one.
2006-05-29 09:57:54 +00:00
christos 9ec9aed92e fhstat needs to be versioned too (for ino_t). Pointed out by Izumi Tsutsui 2006-05-04 17:48:56 +00:00
drochner e4c5c3aea6 constify the __sysctl() kernel side 2006-02-24 19:20:20 +00:00
yamt 221616873d merge yamt-readahead branch. 2005-11-29 22:52:02 +00:00
christos 65a3ca6215 some of the extattr syscalls return ssize_t not int. 2005-09-26 03:02:19 +00:00
christos 50f8955b6e 64 bit inode changes. 2005-08-19 02:04:03 +00:00
thorpej ccbebfaaf1 Add Linux-compatible {,fl}{get,set,list}xattr() system call interface
to the VFS extended attribute subsystem.
2005-07-10 22:04:20 +00:00