lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Fri, 2 Feb 2018 06:54:57 +0300 From: Serge Semin <fancer.lancer@...il.com> To: ralf@...ux-mips.org, miodrag.dinic@...s.com, jhogan@...nel.org, goran.ferenc@...s.com, david.daney@...ium.com, paul.gortmaker@...driver.com, paul.burton@...s.com, alex.belits@...ium.com, Steven.Hill@...ium.com Cc: alexander.sverdlin@...ia.com, matt.redfearn@...s.com, kumba@...too.org, marcin.nowakowski@...s.com, James.hogan@...s.com, Peter.Wotton@...s.com, Sergey.Semin@...latforms.ru, linux-mips@...ux-mips.org, linux-kernel@...r.kernel.org, Serge Semin <fancer.lancer@...il.com> Subject: [PATCH v2 14/15] MIPS: memblock: Discard bootmem from SGI IP27 code SGI IP27 got its own code to set the early memory allocator up since it's NUMA-based system. So in order to be compatible with NO_BOOTMEM config we need to discard the bootmem allocator initialization and insert the memblock reservation method. Although in my opinion the code isn't working anyway since I couldn't find a place where prom_meminit() called and kernel memory isn't reserved. It must have been untested since the time the arch/mips/mips-boards/generic code was in the kernel. Signed-off-by: Serge Semin <fancer.lancer@...il.com> --- arch/mips/sgi-ip27/ip27-memory.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/arch/mips/sgi-ip27/ip27-memory.c b/arch/mips/sgi-ip27/ip27-memory.c index 59133d0abc83..c480ee3eca96 100644 --- a/arch/mips/sgi-ip27/ip27-memory.c +++ b/arch/mips/sgi-ip27/ip27-memory.c @@ -389,7 +389,6 @@ static void __init node_mem_init(cnodeid_t node) { unsigned long slot_firstpfn = slot_getbasepfn(node, 0); unsigned long slot_freepfn = node_getfirstfree(node); - unsigned long bootmap_size; unsigned long start_pfn, end_pfn; get_pfn_range_for_nid(node, &start_pfn, &end_pfn); @@ -400,7 +399,6 @@ static void __init node_mem_init(cnodeid_t node) __node_data[node] = __va(slot_freepfn << PAGE_SHIFT); memset(__node_data[node], 0, PAGE_SIZE); - NODE_DATA(node)->bdata = &bootmem_node_data[node]; NODE_DATA(node)->node_start_pfn = start_pfn; NODE_DATA(node)->node_spanned_pages = end_pfn - start_pfn; @@ -409,12 +407,9 @@ static void __init node_mem_init(cnodeid_t node) slot_freepfn += PFN_UP(sizeof(struct pglist_data) + sizeof(struct hub_data)); - bootmap_size = init_bootmem_node(NODE_DATA(node), slot_freepfn, - start_pfn, end_pfn); free_bootmem_with_active_regions(node, end_pfn); - reserve_bootmem_node(NODE_DATA(node), slot_firstpfn << PAGE_SHIFT, - ((slot_freepfn - slot_firstpfn) << PAGE_SHIFT) + bootmap_size, - BOOTMEM_DEFAULT); + memblock_reserve(slot_firstpfn << PAGE_SHIFT, + ((slot_freepfn - slot_firstpfn) << PAGE_SHIFT)); sparse_memory_present_with_active_regions(node); } -- 2.12.0
Powered by blists - more mailing lists