[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] arm: handle xenheap which isn't at the start of RAM.
# HG changeset patch # User Ian Campbell <ian.campbell@xxxxxxxxxx> # Date 1354278022 0 # Node ID ee9c6e49f20aa6cfbd2f8e33a441496a4843f725 # Parent 88a6381a4f2a6378767942cfc6e9a5abf46bf08b arm: handle xenheap which isn't at the start of RAM. Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx> Acked-by: Tim Deegan <tim@xxxxxxx> Committed-by: Ian Campbell <ian.campbell@xxxxxxxxxx> --- diff -r 88a6381a4f2a -r ee9c6e49f20a xen/include/asm-arm/mm.h --- a/xen/include/asm-arm/mm.h Fri Nov 30 12:20:22 2012 +0000 +++ b/xen/include/asm-arm/mm.h Fri Nov 30 12:20:22 2012 +0000 @@ -214,17 +214,15 @@ static inline struct page_info *virt_to_ ASSERT(va >= XENHEAP_VIRT_START); ASSERT(va < xenheap_virt_end); - return frame_table + ((va - XENHEAP_VIRT_START) >> PAGE_SHIFT); + return frame_table + + ((va - XENHEAP_VIRT_START) >> PAGE_SHIFT) + + xenheap_mfn_start + - frametable_base_mfn; } static inline void *page_to_virt(const struct page_info *pg) { - ASSERT((unsigned long)pg - FRAMETABLE_VIRT_START < frametable_virt_end); - return (void *)(XENHEAP_VIRT_START + - ((unsigned long)pg - FRAMETABLE_VIRT_START) / - (sizeof(*pg) / (sizeof(*pg) & -sizeof(*pg))) * - (PAGE_SIZE / (sizeof(*pg) & -sizeof(*pg)))); - + return mfn_to_virt(page_to_mfn(pg)); } struct domain *page_get_owner_and_reference(struct page_info *page); _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |