]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
powerpc: fix io.h build warning with CONFIG_PHYS_64BIT
authorBecky Bruce <beckyb@kernel.crashing.org>
Thu, 4 Dec 2008 05:04:37 +0000 (23:04 -0600)
committerWolfgang Denk <wd@denx.de>
Tue, 16 Dec 2008 15:54:41 +0000 (16:54 +0100)
Casting a pointer to a phys_addr_t when it's an unsigned long long
on a 32-bit system without first casting to a non-pointer type
generates a compiler warning. Fix this.

Signed-off-by: Becky Bruce <beckyb@kernel.crashing.org>
include/asm-ppc/io.h

index c00de452d6d479d9bc39ae5337c705aa2f310782..64cb746b1079d4a1310cdfe299bb2d8f7ebad4e3 100644 (file)
@@ -300,7 +300,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)((unsigned long)vaddr);
 }
 
 #endif