lkml.org 
[lkml]   [2008]   [Apr]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[Patch 002/005](memory hotplug) align memmap to page size

    To free memmap easier, this patch aligns it to page size.
    Bootmem allocater may mix some objects in one pages.
    It's not good for freeing memmap of memory hot-remove.


    Signed-off-by: Yasunori Goto <y-goto@jp.fujitsu.com>

    ---
    mm/sparse.c | 4 ++--
    1 file changed, 2 insertions(+), 2 deletions(-)

    Index: current/mm/sparse.c
    ===================================================================
    --- current.orig/mm/sparse.c 2008-04-07 19:18:50.000000000 +0900
    +++ current/mm/sparse.c 2008-04-07 20:08:13.000000000 +0900
    @@ -265,8 +265,8 @@
    if (map)
    return map;

    - map = alloc_bootmem_node(NODE_DATA(nid),
    - sizeof(struct page) * PAGES_PER_SECTION);
    + map = alloc_bootmem_pages_node(NODE_DATA(nid),
    + PAGE_ALIGN(sizeof(struct page) * PAGES_PER_SECTION));
    return map;
    }
    #endif /* !CONFIG_SPARSEMEM_VMEMMAP */
    --
    Yasunori Goto




    \
     
     \ /
      Last update: 2008-04-07 14:53    [W:2.455 / U:0.004 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site