minix/minix/lib/libsys/vm_fork.c
Lionel Sambuc 433d6423c3 New sources layout
Change-Id: Ic716f336b7071063997cf5b4dae6d50e0b4631e9
2014-07-31 16:00:30 +02:00

25 lines
560 B
C

#include "syslib.h"
#include <string.h>
#include <minix/vm.h>
/*===========================================================================*
* vm_fork *
*===========================================================================*/
int vm_fork(endpoint_t ep, int slot, endpoint_t *childep)
{
message m;
int result;
memset(&m, 0, sizeof(m));
m.VMF_ENDPOINT = ep;
m.VMF_SLOTNO = slot;
result = _taskcall(VM_PROC_NR, VM_FORK, &m);
*childep = m.VMF_CHILD_ENDPOINT;
return(result);
}