add port io functions to sys/io.h
based on proposal by Isaac Dunham. nonexistance of bits/io.h will cause inclusion of sys/io.h to produce an error on archs that are not supposed to have it. this is probably the desired behavior, but the error message may be a bit unusual.
This commit is contained in:
parent
f54ac2446a
commit
61aa6324af
5 changed files with 167 additions and 4 deletions
|
|
@ -1,7 +1,8 @@
|
|||
#include <sys/io.h>
|
||||
#include "syscall.h"
|
||||
|
||||
#ifdef SYS_ioperm
|
||||
#include <sys/io.h>
|
||||
|
||||
int ioperm(unsigned long from, unsigned long num, int turn_on)
|
||||
{
|
||||
return syscall(SYS_ioperm, from, num, turn_on);
|
||||
|
|
|
|||
|
|
@ -1,7 +1,8 @@
|
|||
#include <sys/io.h>
|
||||
#include "syscall.h"
|
||||
|
||||
#ifdef SYS_iopl
|
||||
#include <sys/io.h>
|
||||
|
||||
int iopl(int level)
|
||||
{
|
||||
return syscall(SYS_iopl, level);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue