Clean up interface to PM and VFS

- introduce new call numbers, names, and field aliases;
- initialize request messages to zero for all ABI calls;
- format callnr.h in the same way as com.h;
- redo call tables in both servers;
- remove param.h namespace pollution in the servers;
- make brk(2) go to VM directly, rather than through PM;
- remove obsolete BRK, UTIME, and WAIT calls;
- clean up path copying routine in VFS;
- move remaining system calls from libminlib to libc;
- correct some errno-related mistakes in libc routines.

Change-Id: I2d8ec5d061cd7e0b30c51ffd77aa72ebf84e2565
This commit is contained in:
David van Moolenbroek
2013-11-04 22:48:08 +01:00
committed by Lionel Sambuc
parent 2c8310fce6
commit 24ec0d73b5
164 changed files with 1615 additions and 1778 deletions

View File

@@ -21,9 +21,6 @@ SRCS+= gcov.c gcov_flush.c
# Various utils
SRCS+= itoa.c u64util.c read_tsc_64.c
# svrctl
SRCS+= svrctl.c
# servxcheck
SRCS+= servxcheck.c

View File

@@ -4,22 +4,6 @@
#include <minix/gcov.h>
int gcov_flush_svr(char *buff, int buff_sz, int server_nr)
{
message msg;
msg.GCOV_BUFF_P = buff;
msg.GCOV_BUFF_SZ = buff_sz;
msg.GCOV_PID = server_nr;
/* Make the call to server. It will call the gcov library,
* buffer the stdio requests, and copy the buffer to this user
* space
*/
return _syscall(VFS_PROC_NR, GCOV_FLUSH, &msg);
}
/* wrappers for file system calls from gcc libgcov library.
Default calls are wrapped. In libsys, an alternative
implementation for servers is used.

View File

@@ -1,28 +0,0 @@
/* svrctl() - special server control functions. Author: Kees J. Bot
* 24 Apr 1994
*/
#include <lib.h>
#include <stdio.h>
#include <sys/svrctl.h>
int svrctl(int request, void *argp)
{
message m;
m.m2_i1 = request;
m.m2_p1 = argp;
switch ((request >> 8) & 0xFF) {
case 'M':
case 'S':
/* PM handles calls for itself and the kernel. */
return _syscall(PM_PROC_NR, PM_SVRCTL, &m);
case 'F':
case 'I':
/* VFS handles calls for itself and inet. */
return _syscall(VFS_PROC_NR, VFS_SVRCTL, &m);
default:
errno = EINVAL;
return -1;
}
}