]> git.karo-electronics.de Git - karo-tx-uboot.git/blobdiff - arch/x86/include/asm/io.h
Merge branch 'master' of git://git.denx.de/u-boot-samsung
[karo-tx-uboot.git] / arch / x86 / include / asm / io.h
index 84a638da78df17ca46d8c62c4750d17bc6d97d28..86bac90e8e882650829b7ce9177e5198339237a5 100644 (file)
@@ -1,6 +1,8 @@
 #ifndef _ASM_IO_H
 #define _ASM_IO_H
 
+#include <compiler.h>
+
 /*
  * This file contains the definitions for the x86 IO instructions
  * inb/inw/inl/outb/outw/outl and the "string versions" of the same
@@ -220,7 +222,7 @@ static inline void sync(void)
 static inline void *
 map_physmem(phys_addr_t paddr, unsigned long len, unsigned long flags)
 {
-       return (void *)paddr;
+       return (void *)(uintptr_t)paddr;
 }
 
 /*
@@ -233,7 +235,7 @@ static inline void unmap_physmem(void *vaddr, unsigned long flags)
 
 static inline phys_addr_t virt_to_phys(void * vaddr)
 {
-       return (phys_addr_t)(vaddr);
+       return (phys_addr_t)(uintptr_t)(vaddr);
 }
 
 /*