summaryrefslogtreecommitdiffstats
path: root/arch/mips/loongson64/numa.c
diff options
context:
space:
mode:
authorTiezhu Yang <yangtiezhu@loongson.cn>2020-11-03 15:12:01 +0800
committerThomas Bogendoerfer <tsbogend@alpha.franken.de>2020-11-11 23:52:07 +0100
commitfe9863a19a5a73af8227548603fb521050769611 (patch)
treee475b8afd292ef567ef640bbf5ae0397abe4b82e /arch/mips/loongson64/numa.c
parent4d1b3ac886b5c03e966199edcc7e0efddd5c4cb2 (diff)
downloadlinux-fe9863a19a5a73af8227548603fb521050769611.tar.bz2
MIPS: Loongson64: Set the field ELPA of CP0_PAGEGRAIN only once
The field ELPA of CP0_PAGEGRAIN register is set at the beginning of the kernel entry point in kernel-entry-init.h, no need to set it again in numa.c, we can remove enable_lpa() and only print the related information. Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn> Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Diffstat (limited to 'arch/mips/loongson64/numa.c')
-rw-r--r--arch/mips/loongson64/numa.c17
1 files changed, 2 insertions, 15 deletions
diff --git a/arch/mips/loongson64/numa.c b/arch/mips/loongson64/numa.c
index c7e3ccedc74f..509b360e4d28 100644
--- a/arch/mips/loongson64/numa.c
+++ b/arch/mips/loongson64/numa.c
@@ -35,20 +35,6 @@ EXPORT_SYMBOL(__node_data);
cpumask_t __node_cpumask[MAX_NUMNODES];
EXPORT_SYMBOL(__node_cpumask);
-static void enable_lpa(void)
-{
- unsigned long value;
-
- value = __read_32bit_c0_register($16, 3);
- pr_info("CP0_Config3: CP0 16.3 (0x%lx)\n", value);
-
- value = __read_32bit_c0_register($5, 1);
- value |= 0x20000000;
- __write_32bit_c0_register($5, 1, value);
- value = __read_32bit_c0_register($5, 1);
- pr_info("CP0_PageGrain: CP0 5.1 (0x%lx)\n", value);
-}
-
static void cpu_node_probe(void)
{
int i;
@@ -240,7 +226,8 @@ EXPORT_SYMBOL(pcibus_to_node);
void __init prom_init_numa_memory(void)
{
- enable_lpa();
+ pr_info("CP0_Config3: CP0 16.3 (0x%x)\n", read_c0_config3());
+ pr_info("CP0_PageGrain: CP0 5.1 (0x%x)\n", read_c0_pagegrain());
prom_meminit();
}
EXPORT_SYMBOL(prom_init_numa_memory);