etc/services - sync with NetBSD-8
[minix.git] / minix / lib / libsys / arch / i386 / sys_in.c
blob4a792ac3d27a8057c6161b8e5cb1c0722a0d5f22
1 #include "syslib.h"
3 /*===========================================================================*
4 * sys_in *
5 *===========================================================================*/
6 int sys_in(port, value, type)
7 int port; /* port address to read from */
8 u32_t *value; /* pointer where to store value */
9 int type; /* byte, word, long */
11 message m_io;
12 int result;
14 m_io.m_lsys_krn_sys_devio.request = _DIO_INPUT | type;
15 m_io.m_lsys_krn_sys_devio.port = port;
17 result = _kernel_call(SYS_DEVIO, &m_io);
18 *value = m_io.m_krn_lsys_sys_devio.value;
19 return(result);