libc_FILES=" \
__pm_findproc.c \
+ _adddma.c \
_brk.c \
_cprofile.c \
+ _deldma.c \
_devctl.c \
_getdents.c \
+ _getdma.c \
_getnpid.c \
_getnprocnr.c \
_getpprocnr.c \
--- /dev/null
+/* adddma.c
+ */
+
+#include <lib.h>
+#define adddma _adddma
+#include <unistd.h>
+#include <stdarg.h>
+
+int adddma(proc_e, start, size)
+endpoint_t proc_e;
+phys_bytes start;
+phys_bytes size;
+{
+ message m;
+
+ m.m2_i1= proc_e;
+ m.m2_l1= start;
+ m.m2_l2= size;
+
+ return _syscall(MM, ADDDMA, &m);
+}
--- /dev/null
+/* deldma.c
+ */
+
+#include <lib.h>
+#define deldma _deldma
+#include <unistd.h>
+#include <stdarg.h>
+
+int deldma(proc_e, start, size)
+endpoint_t proc_e;
+phys_bytes start;
+phys_bytes size;
+{
+ message m;
+
+ m.m2_i1= proc_e;
+ m.m2_l1= start;
+ m.m2_l2= size;
+
+ return _syscall(MM, DELDMA, &m);
+}
--- /dev/null
+/* getdma.c
+ */
+
+#include <lib.h>
+#define getdma _getdma
+#include <unistd.h>
+#include <stdarg.h>
+
+int getdma(procp, basep, sizep)
+endpoint_t *procp;
+phys_bytes *basep;
+phys_bytes *sizep;
+{
+ int r;
+ message m;
+
+ r= _syscall(MM, GETDMA, &m);
+ if (r == 0)
+ {
+ *procp= m.m2_i1;
+ *basep= m.m2_l1;
+ *sizep= m.m2_l2;
+ }
+ return r;
+}
_exit.s \
_pm_findproc.s \
access.s \
+ adddma.s \
alarm.s \
brk.s \
cfgetispeed.s \
closedir.s \
cprofile.s \
creat.s \
+ deldma.s \
devctl.s \
dup.s \
dup2.s \
fstatfs.s \
getcwd.s \
getdents.s \
+ getdma.s \
getegid.s \
geteuid.s \
getgid.s \
--- /dev/null
+.sect .text
+.extern __adddma
+.define _adddma
+.align 2
+
+_adddma:
+ jmp __adddma
--- /dev/null
+.sect .text
+.extern __deldma
+.define _deldma
+.align 2
+
+_deldma:
+ jmp __deldma
--- /dev/null
+.sect .text
+.extern __getdma
+.define _getdma
+.align 2
+
+_getdma:
+ jmp __getdma
--- /dev/null
+#include "syslib.h"
+
+/*===========================================================================*
+ * sys_mapdma *
+ *===========================================================================*/
+PUBLIC int sys_mapdma(vir_addr, bytes)
+vir_bytes vir_addr; /* address in bytes with segment*/
+vir_bytes bytes; /* number of bytes to be copied */
+{
+ message m;
+ int result;
+
+ m.CP_SRC_ADDR = vir_addr;
+ m.CP_NR_BYTES = bytes;
+
+ result = _taskcall(SYSTASK, SYS_MAPDMA, &m);
+ return(result);
+}
+