diff options
author | RajithaY <rajithax.yerrumsetty@intel.com> | 2017-04-25 03:31:15 -0700 |
---|---|---|
committer | Rajitha Yerrumchetty <rajithax.yerrumsetty@intel.com> | 2017-05-22 06:48:08 +0000 |
commit | bb756eebdac6fd24e8919e2c43f7d2c8c4091f59 (patch) | |
tree | ca11e03542edf2d8f631efeca5e1626d211107e3 /qemu/roms/openbios/include/arch/x86/io.h | |
parent | a14b48d18a9ed03ec191cf16b162206998a895ce (diff) |
Adding qemu as a submodule of KVMFORNFV
This Patch includes the changes to add qemu as a submodule to
kvmfornfv repo and make use of the updated latest qemu for the
execution of all testcase
Change-Id: I1280af507a857675c7f81d30c95255635667bdd7
Signed-off-by:RajithaY<rajithax.yerrumsetty@intel.com>
Diffstat (limited to 'qemu/roms/openbios/include/arch/x86/io.h')
-rw-r--r-- | qemu/roms/openbios/include/arch/x86/io.h | 74 |
1 files changed, 0 insertions, 74 deletions
diff --git a/qemu/roms/openbios/include/arch/x86/io.h b/qemu/roms/openbios/include/arch/x86/io.h deleted file mode 100644 index 76fa4f23a..000000000 --- a/qemu/roms/openbios/include/arch/x86/io.h +++ /dev/null @@ -1,74 +0,0 @@ -#ifndef _ASM_IO_H -#define _ASM_IO_H - -#include "asm/types.h" - -extern char _start, _end; -extern unsigned long virt_offset; - -#define phys_to_virt(phys) ((void *) ((unsigned long) (phys) - virt_offset)) -#define virt_to_phys(virt) ((unsigned long) (virt) + virt_offset) - -#ifndef BOOTSTRAP -#define __SLOW_DOWN_IO "outb %%al,$0x80;" -static inline void slow_down_io(void) -{ - __asm__ __volatile__( - __SLOW_DOWN_IO -#ifdef REALLY_SLOW_IO - __SLOW_DOWN_IO __SLOW_DOWN_IO __SLOW_DOWN_IO -#endif - : : ); -} - -#define BUILDIO(bwl,bw,type) \ -static inline void out##bwl(unsigned type value, int port) { \ - __asm__ __volatile__("out" #bwl " %" #bw "0, %w1" : : "a"(value), "Nd"(port)); \ -} \ -static inline unsigned type in##bwl(int port) { \ - unsigned type value; \ - __asm__ __volatile__("in" #bwl " %w1, %" #bw "0" : "=a"(value) : "Nd"(port)); \ - return value; \ -} \ -static inline void out##bwl##_p(unsigned type value, int port) { \ - out##bwl(value, port); \ - slow_down_io(); \ -} \ -static inline unsigned type in##bwl##_p(int port) { \ - unsigned type value = in##bwl(port); \ - slow_down_io(); \ - return value; \ -} \ -static inline void outs##bwl(int port, const void *addr, unsigned long count) { \ - __asm__ __volatile__("rep; outs" #bwl : "+S"(addr), "+c"(count) : "d"(port)); \ -} \ -static inline void ins##bwl(int port, void *addr, unsigned long count) { \ - __asm__ __volatile__("rep; ins" #bwl : "+D"(addr), "+c"(count) : "d"(port)); \ -} - -#ifndef BOOTSTRAP -BUILDIO(b,b,char) -BUILDIO(w,w,short) -BUILDIO(l,,int) -#endif - -#else /* BOOTSTRAP */ -#ifdef FCOMPILER -#define inb(reg) ((u8)0xff) -#define inw(reg) ((u16)0xffff) -#define inl(reg) ((u32)0xffffffff) -#define outb(reg, val) do{} while(0) -#define outw(reg, val) do{} while(0) -#define outl(reg, val) do{} while(0) -#else -extern u8 inb(u32 reg); -extern u16 inw(u32 reg); -extern u32 inl(u32 reg); -extern void insw(u32 reg, void *addr, unsigned long count); -extern void outb(u32 reg, u8 val); -extern void outw(u32 reg, u16 val); -extern void outl(u32 reg, u32 val); -extern void outsw(u32 reg, const void *addr, unsigned long count); -#endif -#endif -#endif |