summaryrefslogtreecommitdiff
path: root/arch/mips/loongson/common
diff options
context:
space:
mode:
Diffstat (limited to 'arch/mips/loongson/common')
-rw-r--r--arch/mips/loongson/common/init.c2
-rw-r--r--arch/mips/loongson/common/mem.c8
-rw-r--r--arch/mips/loongson/common/pci.c2
3 files changed, 6 insertions, 6 deletions
diff --git a/arch/mips/loongson/common/init.c b/arch/mips/loongson/common/init.c
index 743d3571f010..2b92a23d29dd 100644
--- a/arch/mips/loongson/common/init.c
+++ b/arch/mips/loongson/common/init.c
@@ -21,7 +21,7 @@ void __init prom_init(void)
set_io_port_base((unsigned long)
ioremap(LOONGSON_PCIIO_BASE, LOONGSON_PCIIO_SIZE));
-#if defined(CONFIG_CPU_LOONGSON2F) && defined(CONFIG_64BIT)
+#ifdef CONFIG_CPU_SUPPORTS_ADDRWINCFG
_loongson_addrwincfg_base = (unsigned long)
ioremap(LOONGSON_ADDRWINCFG_BASE, LOONGSON_ADDRWINCFG_SIZE);
#endif
diff --git a/arch/mips/loongson/common/mem.c b/arch/mips/loongson/common/mem.c
index e93551dbc9ea..981e9190f393 100644
--- a/arch/mips/loongson/common/mem.c
+++ b/arch/mips/loongson/common/mem.c
@@ -20,8 +20,7 @@ void __init prom_init_memory(void)
add_memory_region(memsize << 20, LOONGSON_PCI_MEM_START - (memsize <<
20), BOOT_MEM_RESERVED);
-#ifdef CONFIG_64BIT
-#ifdef CONFIG_CPU_LOONGSON2F
+#ifdef CONFIG_CPU_SUPPORTS_ADDRWINCFG
{
int bit;
@@ -36,8 +35,9 @@ void __init prom_init_memory(void)
0x80000000ul, (1 << bit));
mmiowb();
}
-#endif /* CONFIG_CPU_LOONGSON2F */
+#endif /* !CONFIG_CPU_SUPPORTS_ADDRWINCFG */
+#ifdef CONFIG_64BIT
if (highmemsize > 0)
add_memory_region(LOONGSON_HIGHMEM_START,
highmemsize << 20, BOOT_MEM_RAM);
@@ -45,7 +45,7 @@ void __init prom_init_memory(void)
add_memory_region(LOONGSON_PCI_MEM_END + 1, LOONGSON_HIGHMEM_START -
LOONGSON_PCI_MEM_END - 1, BOOT_MEM_RESERVED);
-#endif /* CONFIG_64BIT */
+#endif /* !CONFIG_64BIT */
}
/* override of arch/mips/mm/cache.c: __uncached_access */
diff --git a/arch/mips/loongson/common/pci.c b/arch/mips/loongson/common/pci.c
index eac43b8f695e..31d8c5ecd16c 100644
--- a/arch/mips/loongson/common/pci.c
+++ b/arch/mips/loongson/common/pci.c
@@ -68,7 +68,7 @@ static void __init setup_pcimap(void)
deassert for some broken device */
LOONGSON_PXARB_CFG = 0x00fe0105ul;
-#if defined(CONFIG_CPU_LOONGSON2F) && defined(CONFIG_64BIT)
+#ifdef CONFIG_CPU_SUPPORTS_ADDRWINCFG
/*
* set cpu addr window2 to map CPU address space to PCI address space
*/