sh: sh7785lcr: fix PCI address map for 32-bit mode
authorYoshihiro Shimoda <shimoda.yoshihiro@renesas.com>
Mon, 6 Apr 2009 11:37:15 +0000 (11:37 +0000)
committerPaul Mundt <lethal@linux-sh.org>
Mon, 6 Apr 2009 15:55:51 +0000 (08:55 -0700)
Fix the problem that cannot work PCI device on 32-bit mode because
influence of the commit 68b42d1b548be1840aff7122fdebeb804daf0fa3
("sh: sh7785lcr: Map whole PCI address space."). So this patch was
implement like a 29-bit mode, map whole physical address space of
DDR-SDRAM.

Signed-off-by: Yoshihiro Shimoda <shimoda.yoshihiro@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
arch/sh/drivers/pci/ops-sh7785lcr.c
arch/sh/drivers/pci/pci-sh7780.h

index e8b7446..fb0869f 100644 (file)
@@ -48,8 +48,13 @@ EXPORT_SYMBOL(board_pci_channels);
 
 static struct sh4_pci_address_map sh7785_pci_map = {
        .window0        = {
+#if defined(CONFIG_32BIT)
+               .base   = SH7780_32BIT_DDR_BASE_ADDR,
+               .size   = 0x40000000,
+#else
                .base   = SH7780_CS0_BASE_ADDR,
                .size   = 0x20000000,
+#endif
        },
 
        .flags  = SH4_PCIC_NO_RESET,
index 97b2c98..93adc71 100644 (file)
 #define SH7780_CS5_BASE_ADDR   (SH7780_CS4_BASE_ADDR + SH7780_MEM_REGION_SIZE)
 #define SH7780_CS6_BASE_ADDR   (SH7780_CS5_BASE_ADDR + SH7780_MEM_REGION_SIZE)
 
+#define SH7780_32BIT_DDR_BASE_ADDR     0x40000000
+
 struct sh4_pci_address_map;
 
 /* arch/sh/drivers/pci/pci-sh7780.c */