summaryrefslogtreecommitdiffstats
path: root/arch/arm/include/asm/io.h
diff options
context:
space:
mode:
authorRob Herring <rob.herring@calxeda.com>2012-04-04 17:48:04 -0500
committerOlof Johansson <olof@lixom.net>2012-04-05 11:29:55 -0700
commit1ac02d795889d1828a66d4b3a3fd66492d1d7cf2 (patch)
treee77b927029ba0280754936c5a75941bfdfa8ec8d /arch/arm/include/asm/io.h
parent00bd60fe33f3b9e0d790a5e3eebbaa50ac89ead2 (diff)
downloadop-kernel-dev-1ac02d795889d1828a66d4b3a3fd66492d1d7cf2.zip
op-kernel-dev-1ac02d795889d1828a66d4b3a3fd66492d1d7cf2.tar.gz
ARM: fix __io macro for PCMCIA
With commit c334bc1 (ARM: make mach/io.h include optional), PCMCIA was broken. PCMCIA depends on __io() returning a valid i/o address, and most ARM platforms require IO_SPACE_LIMIT be set to 0xffffffff for PCMCIA. This needs a better fix with a fixed i/o address mapping, but for now we just restore things to the previous behavior. This fixes at91, omap1, pxa and sa11xx. pxa needs io.h if PCI is enabled, but PCMCIA is not. sa11xx already has IO_SPACE_LIMIT set to 0xffffffff, so it doesn't need an io.h. Signed-off-by: Rob Herring <rob.herring@calxeda.com> Cc: Joachim Eastwood <joachim.eastwood@jotron.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: Andrew Victor <linux@maxim.org.za> Cc: Nicolas Ferre <nicolas.ferre@atmel.com> Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com> Tested-by: Paul Parsons <lost.distance@yahoo.com> (pxa270) Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Olof Johansson <olof@lixom.net>
Diffstat (limited to 'arch/arm/include/asm/io.h')
-rw-r--r--arch/arm/include/asm/io.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/include/asm/io.h b/arch/arm/include/asm/io.h
index df0ac0b..9af5563 100644
--- a/arch/arm/include/asm/io.h
+++ b/arch/arm/include/asm/io.h
@@ -119,7 +119,7 @@ static inline void __iomem *__typesafe_io(unsigned long addr)
#ifdef CONFIG_NEED_MACH_IO_H
#include <mach/io.h>
#else
-#define __io(a) ({ (void)(a); __typesafe_io(0); })
+#define __io(a) __typesafe_io((a) & IO_SPACE_LIMIT)
#endif
/*
OpenPOWER on IntegriCloud