[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] [IA64] Cleanup warnings for UC accesses to UC|WB pages



# HG changeset patch
# User Alex Williamson <alex.williamson@xxxxxx>
# Date 1180107489 21600
# Node ID 2372c3fbf7d2db071a5960b6ea3d63f03fe88266
# Parent  0e5c0cde23b10a268022bbebe3b22fdf9e9fdcc7
[IA64] Cleanup warnings for UC accesses to UC|WB pages

This patch cleanup the following warning.

(XEN) mm.c:497:d0 Warning: UC to WB for mpaddr=xxxxxxxx

Signed-off-by: Akio Takebe <takebe_akio@xxxxxxxxxxxxxx>
Signed-off-by: Alex Williamson <alex.williamson@xxxxxx>
---
 xen/arch/ia64/xen/mm.c |   19 ++++++++++++++++---
 1 files changed, 16 insertions(+), 3 deletions(-)

diff -r 0e5c0cde23b1 -r 2372c3fbf7d2 xen/arch/ia64/xen/mm.c
--- a/xen/arch/ia64/xen/mm.c    Fri May 25 09:33:01 2007 -0600
+++ b/xen/arch/ia64/xen/mm.c    Fri May 25 09:38:09 2007 -0600
@@ -498,9 +498,22 @@ u64 translate_domain_pte(u64 pteval, u64
                           This can happen when domU tries to touch i/o
                           port space.  Also prevents possible address
                           aliasing issues.  */
-                       if (!(mpaddr - IO_PORTS_PADDR < IO_PORTS_SIZE))
-                               gdprintk(XENLOG_WARNING, "Warning: UC to WB "
-                                        "for mpaddr=%lx\n", mpaddr);
+                       if (!(mpaddr - IO_PORTS_PADDR < IO_PORTS_SIZE)) {
+                               u64 ucwb;
+                               
+                               /*
+                                * If dom0 page has both UC & WB attributes
+                                * don't warn about attempted UC access.
+                                */
+                               ucwb = efi_mem_attribute(mpaddr, PAGE_SIZE);
+                               ucwb &= EFI_MEMORY_UC | EFI_MEMORY_WB;
+                               ucwb ^= EFI_MEMORY_UC | EFI_MEMORY_WB;
+
+                               if (d != dom0 || ucwb != 0)
+                                       gdprintk(XENLOG_WARNING, "Warning: UC"
+                                                " to WB for mpaddr=%lx\n",
+                                                mpaddr);
+                       }
                        pteval = (pteval & ~_PAGE_MA_MASK) | _PAGE_MA_WB;
                }
                break;

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.