aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-x86_64/io.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-x86_64/io.h')
-rw-r--r--include/asm-x86_64/io.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/include/asm-x86_64/io.h b/include/asm-x86_64/io.h
index 37fc3f149a5a..52ff269fe054 100644
--- a/include/asm-x86_64/io.h
+++ b/include/asm-x86_64/io.h
@@ -48,7 +48,7 @@
48 * Talk about misusing macros.. 48 * Talk about misusing macros..
49 */ 49 */
50#define __OUT1(s,x) \ 50#define __OUT1(s,x) \
51extern inline void out##s(unsigned x value, unsigned short port) { 51static inline void out##s(unsigned x value, unsigned short port) {
52 52
53#define __OUT2(s,s1,s2) \ 53#define __OUT2(s,s1,s2) \
54__asm__ __volatile__ ("out" #s " %" s1 "0,%" s2 "1" 54__asm__ __volatile__ ("out" #s " %" s1 "0,%" s2 "1"
@@ -58,7 +58,7 @@ __OUT1(s,x) __OUT2(s,s1,"w") : : "a" (value), "Nd" (port)); } \
58__OUT1(s##_p,x) __OUT2(s,s1,"w") __FULL_SLOW_DOWN_IO : : "a" (value), "Nd" (port));} \ 58__OUT1(s##_p,x) __OUT2(s,s1,"w") __FULL_SLOW_DOWN_IO : : "a" (value), "Nd" (port));} \
59 59
60#define __IN1(s) \ 60#define __IN1(s) \
61extern inline RETURN_TYPE in##s(unsigned short port) { RETURN_TYPE _v; 61static inline RETURN_TYPE in##s(unsigned short port) { RETURN_TYPE _v;
62 62
63#define __IN2(s,s1,s2) \ 63#define __IN2(s,s1,s2) \
64__asm__ __volatile__ ("in" #s " %" s2 "1,%" s1 "0" 64__asm__ __volatile__ ("in" #s " %" s2 "1,%" s1 "0"
@@ -68,12 +68,12 @@ __IN1(s) __IN2(s,s1,"w") : "=a" (_v) : "Nd" (port) ,##i ); return _v; } \
68__IN1(s##_p) __IN2(s,s1,"w") __FULL_SLOW_DOWN_IO : "=a" (_v) : "Nd" (port) ,##i ); return _v; } \ 68__IN1(s##_p) __IN2(s,s1,"w") __FULL_SLOW_DOWN_IO : "=a" (_v) : "Nd" (port) ,##i ); return _v; } \
69 69
70#define __INS(s) \ 70#define __INS(s) \
71extern inline void ins##s(unsigned short port, void * addr, unsigned long count) \ 71static inline void ins##s(unsigned short port, void * addr, unsigned long count) \
72{ __asm__ __volatile__ ("rep ; ins" #s \ 72{ __asm__ __volatile__ ("rep ; ins" #s \
73: "=D" (addr), "=c" (count) : "d" (port),"0" (addr),"1" (count)); } 73: "=D" (addr), "=c" (count) : "d" (port),"0" (addr),"1" (count)); }
74 74
75#define __OUTS(s) \ 75#define __OUTS(s) \
76extern inline void outs##s(unsigned short port, const void * addr, unsigned long count) \ 76static inline void outs##s(unsigned short port, const void * addr, unsigned long count) \
77{ __asm__ __volatile__ ("rep ; outs" #s \ 77{ __asm__ __volatile__ ("rep ; outs" #s \
78: "=S" (addr), "=c" (count) : "d" (port),"0" (addr),"1" (count)); } 78: "=S" (addr), "=c" (count) : "d" (port),"0" (addr),"1" (count)); }
79 79
@@ -110,12 +110,12 @@ __OUTS(l)
110 * Change virtual addresses to physical addresses and vv. 110 * Change virtual addresses to physical addresses and vv.
111 * These are pretty trivial 111 * These are pretty trivial
112 */ 112 */
113extern inline unsigned long virt_to_phys(volatile void * address) 113static inline unsigned long virt_to_phys(volatile void * address)
114{ 114{
115 return __pa(address); 115 return __pa(address);
116} 116}
117 117
118extern inline void * phys_to_virt(unsigned long address) 118static inline void * phys_to_virt(unsigned long address)
119{ 119{
120 return __va(address); 120 return __va(address);
121} 121}
@@ -130,7 +130,7 @@ extern inline void * phys_to_virt(unsigned long address)
130 130
131extern void __iomem *__ioremap(unsigned long offset, unsigned long size, unsigned long flags); 131extern void __iomem *__ioremap(unsigned long offset, unsigned long size, unsigned long flags);
132 132
133extern inline void __iomem * ioremap (unsigned long offset, unsigned long size) 133static inline void __iomem * ioremap (unsigned long offset, unsigned long size)
134{ 134{
135 return __ioremap(offset, size, 0); 135 return __ioremap(offset, size, 0);
136} 136}