xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2/3] xen/p2m: Using INVALID_MFN instead of mfn_valid
@ 2012-08-15  6:57 Xudong Hao
  2012-08-15  9:21 ` Jan Beulich
  0 siblings, 1 reply; 11+ messages in thread
From: Xudong Hao @ 2012-08-15  6:57 UTC (permalink / raw)
  To: xen-devel; +Cc: Xudong Hao, tim, Xiantao Zhang

64 bits big bar's MMIO address may out of the highest gfn, then mfn_valid 
may return failure, so using INVALID_MFN to measure.

Signed-off-by: Xiantao Zhang <xiantao.zhang@intel.com>
Signed-off-by: Xudong Hao <xudong.hao@intel.com>

diff -r 663eb766cdde xen/arch/x86/mm/p2m-ept.c
--- a/xen/arch/x86/mm/p2m-ept.c	Tue Jul 24 17:02:04 2012 +0200
+++ b/xen/arch/x86/mm/p2m-ept.c	Thu Jul 26 15:40:01 2012 +0800
@@ -428,7 +428,7 @@ ept_set_entry(struct p2m_domain *p2m, un
     }
 
     /* Track the highest gfn for which we have ever had a valid mapping */
-    if ( mfn_valid(mfn_x(mfn)) &&
+    if ( (mfn_x(mfn) != INVALID_MFN) &&
          (gfn + (1UL << order) - 1 > p2m->max_mapped_pfn) )
         p2m->max_mapped_pfn = gfn + (1UL << order) - 1;

^ permalink raw reply	[flat|nested] 11+ messages in thread
* [PATCH 2/3] xen/p2m: Using INVALID_MFN instead of mfn_valid
@ 2012-08-15  6:55 Xudong Hao
  0 siblings, 0 replies; 11+ messages in thread
From: Xudong Hao @ 2012-08-15  6:55 UTC (permalink / raw)
  To: xen-devel; +Cc: @xen.org, Xudong Hao, tim, Xiantao Zhang

64 bits big bar's MMIO address may out of the highest gfn, then mfn_valid 
may return failure, so using INVALID_MFN to measure.

Signed-off-by: Xiantao Zhang <xiantao.zhang@intel.com>
Signed-off-by: Xudong Hao <xudong.hao@intel.com>

diff -r 663eb766cdde xen/arch/x86/mm/p2m-ept.c
--- a/xen/arch/x86/mm/p2m-ept.c	Tue Jul 24 17:02:04 2012 +0200
+++ b/xen/arch/x86/mm/p2m-ept.c	Thu Jul 26 15:40:01 2012 +0800
@@ -428,7 +428,7 @@ ept_set_entry(struct p2m_domain *p2m, un
     }
 
     /* Track the highest gfn for which we have ever had a valid mapping */
-    if ( mfn_valid(mfn_x(mfn)) &&
+    if ( (mfn_x(mfn) != INVALID_MFN) &&
          (gfn + (1UL << order) - 1 > p2m->max_mapped_pfn) )
         p2m->max_mapped_pfn = gfn + (1UL << order) - 1;

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2012-08-16 19:14 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.10813.1345115327.1399.xen-devel@lists.xen.org>
2012-08-16 17:17 ` [PATCH 2/3] xen/p2m: Using INVALID_MFN instead of mfn_valid Andres Lagar-Cavilla
2012-08-16 17:47   ` Tim Deegan
2012-08-15  6:57 Xudong Hao
2012-08-15  9:21 ` Jan Beulich
2012-08-16 10:05   ` Hao, Xudong
2012-08-16 10:12     ` Jan Beulich
2012-08-16 10:31       ` Hao, Xudong
2012-08-16 10:41         ` Jan Beulich
2012-08-16 11:01           ` Tim Deegan
2012-08-16 19:14         ` Mukesh Rathor
  -- strict thread matches above, loose matches on Subject: below --
2012-08-15  6:55 Xudong Hao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).