[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [RFC XEN PATCH 01/16] x86_64/mm: explicitly specify the location to place the frame table
A reserved area on each pmem region is used to place the frame table. However, it's not at the beginning of the pmem region, so we need to specify the location explicitly when extending the frame table. Signed-off-by: Haozhong Zhang <haozhong.zhang@xxxxxxxxx> --- Cc: Jan Beulich <jbeulich@xxxxxxxx> Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> --- xen/arch/x86/x86_64/mm.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/xen/arch/x86/x86_64/mm.c b/xen/arch/x86/x86_64/mm.c index b8b6b70..33f226a 100644 --- a/xen/arch/x86/x86_64/mm.c +++ b/xen/arch/x86/x86_64/mm.c @@ -792,7 +792,8 @@ static int setup_frametable_chunk(void *start, void *end, return 0; } -static int extend_frame_table(struct mem_hotadd_info *info) +static int extend_frame_table(struct mem_hotadd_info *info, + struct mem_hotadd_info *alloc_info) { unsigned long cidx, nidx, eidx, spfn, epfn; @@ -818,9 +819,9 @@ static int extend_frame_table(struct mem_hotadd_info *info) nidx = find_next_bit(pdx_group_valid, eidx, cidx); if ( nidx >= eidx ) nidx = eidx; - err = setup_frametable_chunk(pdx_to_page(cidx * PDX_GROUP_COUNT ), + err = setup_frametable_chunk(pdx_to_page(cidx * PDX_GROUP_COUNT), pdx_to_page(nidx * PDX_GROUP_COUNT), - info); + alloc_info); if ( err ) return err; @@ -1413,7 +1414,7 @@ int memory_add(unsigned long spfn, unsigned long epfn, unsigned int pxm) info.epfn = epfn; info.cur = spfn; - ret = extend_frame_table(&info); + ret = extend_frame_table(&info, &info); if (ret) goto destroy_frametable; -- 2.10.1 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |