Hi Keir,
I posted a similar patch a couple of weeks ago but
I got no response. So I split it and resend.
This patch is needed for live-migration for ia64 (and perhaps PPC).
On ia64, xencomm_copy_chunk_to() dirties a page bypassing a write
protection of TLB. i.e. the page isn't logged as dirty.
Thanks,
Kouya
Signed-off-by: Kouya Shimura <kouya@xxxxxxxxxxxxxx>
diff -r e8f058b99171 xen/common/xencomm.c
--- a/xen/common/xencomm.c Sat Apr 05 22:25:30 2008 +0100
+++ b/xen/common/xencomm.c Mon Apr 07 15:40:47 2008 +0900
@@ -323,6 +323,7 @@ xencomm_copy_chunk_to(
(unsigned long)xencomm_vaddr(paddr, page));
memcpy(xencomm_vaddr(paddr, page), (void *)from, len);
+ xencomm_mark_dirty(xencomm_vaddr(paddr, page), len);
put_page(page);
return 0;
diff -r e8f058b99171 xen/include/xen/xencomm.h
--- a/xen/include/xen/xencomm.h Sat Apr 05 22:25:30 2008 +0100
+++ b/xen/include/xen/xencomm.h Mon Apr 07 15:40:47 2008 +0900
@@ -114,4 +114,12 @@ static inline unsigned long xencomm_inli
xencomm_copy_from_guest(_d, _s, sizeof(*_d), _off); \
})
+#ifdef CONFIG_XENCOMM_MARK_DIRTY
+extern void xencomm_mark_dirty(unsigned long addr, unsigned int len);
+#else
+static inline void xencomm_mark_dirty(unsigned long addr, unsigned int len)
+{
+}
+#endif
+
#endif /* __XENCOMM_H__ */
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|