minix/lib/libsys/sys_out.c

20 lines
546 B
C
Raw Normal View History

2005-04-21 16:53:53 +02:00
#include "syslib.h"
/*===========================================================================*
* sys_out *
*===========================================================================*/
2012-03-25 20:25:53 +02:00
int sys_out(port, value, type)
2005-04-21 16:53:53 +02:00
int port; /* port address to write to */
2012-03-05 00:11:41 +01:00
u32_t value; /* value to write */
2005-04-21 16:53:53 +02:00
int type; /* byte, word, long */
{
message m_io;
m_io.DIO_REQUEST = _DIO_OUTPUT | type;
2005-04-21 16:53:53 +02:00
m_io.DIO_PORT = port;
m_io.DIO_VALUE = value;
return _kernel_call(SYS_DEVIO, &m_io);
2005-04-21 16:53:53 +02:00
}