WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-ia64-devel

[Xen-ia64-devel] [PATCH 3/7] allocate mpt table from domheap

To: xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-ia64-devel] [PATCH 3/7] allocate mpt table from domheap
From: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
Date: Thu, 29 Jan 2009 11:21:30 +0900
Cc: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
Delivery-date: Wed, 28 Jan 2009 18:17:08 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.18 (2008-05-17)
[IA64] use domheap for mpt_table.

Now there is no need to allocate pages for mpt_table from xenheap.
So allocate it from domheap.

Signed-off-by: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>

diff --git a/xen/arch/ia64/xen/xenmem.c b/xen/arch/ia64/xen/xenmem.c
--- a/xen/arch/ia64/xen/xenmem.c
+++ b/xen/arch/ia64/xen/xenmem.c
@@ -49,6 +49,7 @@ paging_init (void)
 {
        unsigned int mpt_order;
        unsigned long mpt_table_size;
+       struct page_info *page;
        unsigned long i;
 
        if (!opt_contig_mem) {
@@ -64,9 +65,11 @@ paging_init (void)
        mpt_table_size = max_page * sizeof(unsigned long);
        mpt_order = get_order(mpt_table_size);
        ASSERT(mpt_order <= MAX_ORDER);
-       if ((mpt_table = alloc_xenheap_pages(mpt_order)) == NULL)
+       page = alloc_domheap_pages(NULL, mpt_order, 0);
+       if (page == NULL)
                panic("Not enough memory to bootstrap Xen.\n");
 
+       mpt_table = page_to_virt(page);
        printk("machine to physical table: 0x%lx mpt_table_size 0x%lx\n"
               "mpt_order %u max_page 0x%lx\n",
               (u64)mpt_table, mpt_table_size, mpt_order, max_page);

Attachment: allocate-mpt-from-dom-heap.patch
Description: Text Data

_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-ia64-devel] [PATCH 3/7] allocate mpt table from domheap, Isaku Yamahata <=