From: Wei Yongjun <yjwei@cn.fujitsu.com>
To: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Subject: [PATCH] mm: fix some compile errors on x86 arch
Date: Thu, 17 Dec 2009 18:01:50 +0800 [thread overview]
Message-ID: <4B2A018E.2010407@cn.fujitsu.com> (raw)
This patch fixed the following compile errors on x86 arch:
p2m.c: In function ‘p2m_change_type_global’:
p2m.c:2211: error: ‘i4’ undeclared (first use in this function)
mem_sharing.c: In function ‘mem_sharing_hash_delete’:
mem_sharing.c:217: error: format ‘%lx’ expects type ‘long unsigned int’,
but argument 2 has type ‘shr_handle_t’
Signed-off-by: Wei Yongjun <yjwei@cn.fujitsu.com>
diff -r 1b81d0607af9 xen/arch/x86/mm/mem_sharing.c
--- a/xen/arch/x86/mm/mem_sharing.c Thu Dec 17 06:27:57 2009 +0000
+++ b/xen/arch/x86/mm/mem_sharing.c Thu Dec 17 17:55:24 2009 +0800
@@ -214,7 +214,7 @@
pprev = &e->next;
e = e->next;
}
- printk("Could not find shr entry for handle %lx\n", handle);
+ printk("Could not find shr entry for handle %llx\n", handle);
BUG();
}
diff -r 1b81d0607af9 xen/arch/x86/mm/p2m.c
--- a/xen/arch/x86/mm/p2m.c Thu Dec 17 06:27:57 2009 +0000
+++ b/xen/arch/x86/mm/p2m.c Thu Dec 17 17:55:24 2009 +0800
@@ -2208,7 +2208,11 @@
mfn = l2e_get_pfn(l2e[i2]);
/* Do not use get_gpfn_from_mfn because it may return
SHARED_M2P_ENTRY */
- gfn = (i2 + (i3 + (i4 * L3_PAGETABLE_ENTRIES))
+ gfn = (i2 + (i3
+#if CONFIG_PAGING_LEVELS >= 4
+ + (i4 * L3_PAGETABLE_ENTRIES)
+#endif
+ )
* L2_PAGETABLE_ENTRIES) * L1_PAGETABLE_ENTRIES;
flags = p2m_type_to_flags(nt);
l1e_content = l1e_from_pfn(mfn, flags | _PAGE_PSE);
@@ -2226,7 +2230,11 @@
if ( p2m_flags_to_type(flags) != ot )
continue;
mfn = l1e_get_pfn(l1e[i1]);
- gfn = i1 + (i2 + (i3 + (i4 * L3_PAGETABLE_ENTRIES))
+ gfn = i1 + (i2 + (i3
+#if CONFIG_PAGING_LEVELS >= 4
+ + (i4 * L3_PAGETABLE_ENTRIES)
+#endif
+ )
* L2_PAGETABLE_ENTRIES) * L1_PAGETABLE_ENTRIES;
/* create a new 1le entry with the new type */
flags = p2m_type_to_flags(nt);
reply other threads:[~2009-12-17 10:01 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4B2A018E.2010407@cn.fujitsu.com \
--to=yjwei@cn.fujitsu.com \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.