]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
MIPS: Loongson fix name confict - MEM_RESERVED
authorHuacai Chen <chenhc@lemote.com>
Thu, 16 Nov 2017 08:35:04 +0000 (16:35 +0800)
committerJames Hogan <jhogan@kernel.org>
Wed, 24 Jan 2018 13:34:39 +0000 (13:34 +0000)
MEM_RESERVED is used as a value of enum mem_type in include/linux/
edac.h. This will make failure to build for Loongson in some case:
for example with CONFIG_RAS enabled.

So here rename MEM_RESERVED to SYSTEM_RAM_RESERVED in Loongson code.

Signed-off-by: YunQiang Su <yunqiang.su@imgtec.com>
Signed-off-by: Huacai Chen <chenhc@lemote.com>
Reviewed-by: James Hogan <jhogan@kernel.org>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/17724/
Signed-off-by: James Hogan <jhogan@kernel.org>
arch/mips/include/asm/mach-loongson64/boot_param.h
arch/mips/loongson64/common/mem.c
arch/mips/loongson64/loongson-3/numa.c

index 4f69f08717f6efc08bd3db360e8d2e32834ef04e..8c286bedff3e15339ba292f6fed55c7c44df5a81 100644 (file)
@@ -4,7 +4,7 @@
 
 #define SYSTEM_RAM_LOW         1
 #define SYSTEM_RAM_HIGH                2
-#define MEM_RESERVED           3
+#define SYSTEM_RAM_RESERVED    3
 #define PCI_IO                 4
 #define PCI_MEM                        5
 #define LOONGSON_CFG_REG       6
index b01d52473da81450d9486cf8da36f8b48cee082e..c549e525fc11f80124753a296a46fac025fc1894 100644 (file)
@@ -79,7 +79,7 @@ void __init prom_init_memory(void)
                                        (u64)loongson_memmap->map[i].mem_size << 20,
                                        BOOT_MEM_RAM);
                                break;
-                       case MEM_RESERVED:
+                       case SYSTEM_RAM_RESERVED:
                                add_memory_region(loongson_memmap->map[i].mem_start,
                                        (u64)loongson_memmap->map[i].mem_size << 20,
                                        BOOT_MEM_RESERVED);
index f17ef520799aef0d827b15b0e0530f65013b9212..9717106de4a5a33c32f2261c0e21a2eb1f7fd87a 100644 (file)
@@ -166,7 +166,7 @@ static void __init szmem(unsigned int node)
                        memblock_add_node(PFN_PHYS(start_pfn),
                                PFN_PHYS(end_pfn - start_pfn), node);
                        break;
-               case MEM_RESERVED:
+               case SYSTEM_RAM_RESERVED:
                        pr_info("Node%d: mem_type:%d, mem_start:0x%llx, mem_size:0x%llx MB\n",
                                (u32)node_id, mem_type, mem_start, mem_size);
                        add_memory_region((node_id << 44) + mem_start,