2 int ioperm(unsigned long, unsigned long, int);
4 static __inline void outb(unsigned char __val, unsigned short __port)
6 __asm__ volatile ("outb %0,%1" : : "a" (__val), "dN" (__port));
9 static __inline void outw(unsigned short __val, unsigned short __port)
11 __asm__ volatile ("outw %0,%1" : : "a" (__val), "dN" (__port));
14 static __inline void outl(unsigned int __val, unsigned short __port)
16 __asm__ volatile ("outl %0,%1" : : "a" (__val), "dN" (__port));
19 static __inline unsigned char inb(unsigned short __port)
22 __asm__ volatile ("inb %1,%0" : "=a" (__val) : "dN" (__port));
26 static __inline unsigned short inw(unsigned short __port)
29 __asm__ volatile ("inw %1,%0" : "=a" (__val) : "dN" (__port));
33 static __inline unsigned int inl(unsigned short __port)
36 __asm__ volatile ("inl %1,%0" : "=a" (__val) : "dN" (__port));
40 static __inline void outsb(unsigned short __port, const void *__buf, unsigned long __n)
42 __asm__ volatile ("cld; rep; outsb"
43 : "+S" (__buf), "+c" (__n)
47 static __inline void outsw(unsigned short __port, const void *__buf, unsigned long __n)
49 __asm__ volatile ("cld; rep; outsw"
50 : "+S" (__buf), "+c" (__n)
54 static __inline void outsl(unsigned short __port, const void *__buf, unsigned long __n)
56 __asm__ volatile ("cld; rep; outsl"
57 : "+S" (__buf), "+c"(__n)
61 static __inline void insb(unsigned short __port, void *__buf, unsigned long __n)
63 __asm__ volatile ("cld; rep; insb"
64 : "+D" (__buf), "+c" (__n)
68 static __inline void insw(unsigned short __port, void *__buf, unsigned long __n)
70 __asm__ volatile ("cld; rep; insw"
71 : "+D" (__buf), "+c" (__n)
75 static __inline void insl(unsigned short __port, void *__buf, unsigned long __n)
77 __asm__ volatile ("cld; rep; insl"
78 : "+D" (__buf), "+c" (__n)