From 7af2b107d4fb3ba3bfb0ae445f808011da6d9771 Mon Sep 17 00:00:00 2001 From: Jorrit Herder Date: Tue, 2 Aug 2005 15:50:00 +0000 Subject: [PATCH] *** empty log message *** --- lib/other/_devctl.c | 16 ++++++++++++++++ lib/syscall/devctl.s | 7 +++++++ 2 files changed, 23 insertions(+) create mode 100644 lib/other/_devctl.c create mode 100644 lib/syscall/devctl.s diff --git a/lib/other/_devctl.c b/lib/other/_devctl.c new file mode 100644 index 000000000..a7454c854 --- /dev/null +++ b/lib/other/_devctl.c @@ -0,0 +1,16 @@ +#include +#define devctl _devctl +#include + + +PUBLIC int devctl(int ctl_req, int proc_nr, int dev_nr, int dev_style) +{ + message m; + m.m4_l1 = ctl_req; + m.m4_l2 = proc_nr; + m.m4_l3 = dev_nr; + m.m4_l4 = dev_style; + if (_syscall(FS, DEVCTL, &m) < 0) return(-1); + return(0); +} + diff --git a/lib/syscall/devctl.s b/lib/syscall/devctl.s new file mode 100644 index 000000000..43aa9ece9 --- /dev/null +++ b/lib/syscall/devctl.s @@ -0,0 +1,7 @@ +.sect .text +.extern __devctl +.define _devctl +.align 2 + +_devctl: + jmp __devctl -- 2.44.0