lkml.org 
[lkml]   [2008]   [May]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH] x86: extend e820 early_res support 32bit -fix #4
    Date

    reserve_early pgdata for 32bit numa

    Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>

    Index: linux-2.6/arch/x86/mm/discontig_32.c
    ===================================================================
    --- linux-2.6.orig/arch/x86/mm/discontig_32.c
    +++ linux-2.6/arch/x86/mm/discontig_32.c
    @@ -159,8 +159,13 @@ static void __init allocate_pgdat(int ni
    if (nid && node_has_online_mem(nid) && node_remap_start_vaddr[nid])
    NODE_DATA(nid) = (pg_data_t *)node_remap_start_vaddr[nid];
    else {
    - NODE_DATA(nid) = (pg_data_t *)(pfn_to_kaddr(min_low_pfn));
    - min_low_pfn += PFN_UP(sizeof(pg_data_t));
    + unsigned long pgdat_phys;
    + pgdat_phys = find_e820_area(min_low_pfn<<PAGE_SHIFT,
    + max_low_pfn<<PAGE_SHIFT, sizeof(pg_data_t),
    + PAGE_SIZE);
    + NODE_DATA(nid) = (pg_data_t *)(pfn_to_kaddr(pgdat_phys>>PAGE_SHIFT));
    + reserve_early(pgdat_phys, pgdat_phys + sizeof(pg_data_t),
    + "NODE_DATA");
    }
    }


    \
     
     \ /
      Last update: 2008-05-29 22:03    [W:0.024 / U:0.148 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site