+ mm-free-memblockmemory-in-free_all_bootmem-fix.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Subject: + mm-free-memblockmemory-in-free_all_bootmem-fix.patch added to -mm tree
To: phacht@xxxxxxxxxxxxxxxxxx,hannes@xxxxxxxxxxx,iamjoonsoo.kim@xxxxxxx,tangchen@xxxxxxxxxxxxxx,tj@xxxxxxxxxx,toshi.kani@xxxxxx,wujianguo@xxxxxxxxxx
From: akpm@xxxxxxxxxxxxxxxxxxxx
Date: Wed, 08 Jan 2014 14:07:00 -0800


The patch titled
     Subject: mm-free-memblockmemory-in-free_all_bootmem-fix
has been added to the -mm tree.  Its filename is
     mm-free-memblockmemory-in-free_all_bootmem-fix.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/mm-free-memblockmemory-in-free_all_bootmem-fix.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/mm-free-memblockmemory-in-free_all_bootmem-fix.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Philipp Hachtmann <phacht@xxxxxxxxxxxxxxxxxx>
Subject: mm-free-memblockmemory-in-free_all_bootmem-fix

Am Wed, 8 Jan 2014 12:08:04 +0800
schrieb Jianguo Wu <wujianguo@xxxxxxxxxx>:

> For some archs, like arm64, would use memblock.memory after system
> booting, so we can not simply released to the buddy allocator, maybe
> need !defined(CONFIG_ARCH_DISCARD_MEMBLOCK).

Signed-off-by: Philipp Hachtmann <phacht@xxxxxxxxxxxxxxxxxx>
Cc: Tejun Heo <tj@xxxxxxxxxx>
Cc: Joonsoo Kim <iamjoonsoo.kim@xxxxxxx>
Cc: Johannes Weiner <hannes@xxxxxxxxxxx>
Cc: Tang Chen <tangchen@xxxxxxxxxxxxxx>
Cc: Toshi Kani <toshi.kani@xxxxxx>
Cc: Jianguo Wu <wujianguo@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 mm/memblock.c  |    4 ++++
 mm/nobootmem.c |    3 +++
 2 files changed, 7 insertions(+)

diff -puN mm/memblock.c~mm-free-memblockmemory-in-free_all_bootmem-fix mm/memblock.c
--- a/mm/memblock.c~mm-free-memblockmemory-in-free_all_bootmem-fix
+++ a/mm/memblock.c
@@ -291,6 +291,8 @@ phys_addr_t __init_memblock get_allocate
 			  memblock.reserved.max);
 }
 
+#ifdef CONFIG_ARCH_DISCARD_MEMBLOCK
+
 phys_addr_t __init_memblock get_allocated_memblock_memory_regions_info(
 					phys_addr_t *addr)
 {
@@ -303,6 +305,8 @@ phys_addr_t __init_memblock get_allocate
 			  memblock.memory.max);
 }
 
+#endif
+
 /**
  * memblock_double_array - double the size of the memblock regions array
  * @type: memblock type of the regions array being doubled
diff -puN mm/nobootmem.c~mm-free-memblockmemory-in-free_all_bootmem-fix mm/nobootmem.c
--- a/mm/nobootmem.c~mm-free-memblockmemory-in-free_all_bootmem-fix
+++ a/mm/nobootmem.c
@@ -127,10 +127,13 @@ static unsigned long __init free_low_mem
 	if (size)
 		count += __free_memory_core(start, start + size);
 
+#ifdef CONFIG_ARCH_DISCARD_MEMBLOCK
+
 	/* Free memblock.memory array if it was allocated */
 	size = get_allocated_memblock_memory_regions_info(&start);
 	if (size)
 		count += __free_memory_core(start, start + size);
+#endif
 
 	return count;
 }
_

Patches currently in -mm which might be from phacht@xxxxxxxxxxxxxxxxxx are

mm-nobootmemc-add-return-value-check-in-__alloc_memory_core_early.patch
mm-free-memblockmemory-in-free_all_bootmem.patch
mm-free-memblockmemory-in-free_all_bootmem-fix.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux