On 10/05/2019 12:35, Jan Beulich wrote:
On 07.05.19 at 17:14, <julien.gr...@arm.com> wrote:
--- a/xen/arch/x86/mm/shadow/common.c
+++ b/xen/arch/x86/mm/shadow/common.c
@@ -474,7 +474,8 @@ static inline void trace_resync(int event, mfn_t gmfn)
if ( tb_init_done )
{
/* Convert gmfn to gfn */
- unsigned long gfn = mfn_to_gfn(current->domain, gmfn);
+ unsigned long gfn = gfn_x(mfn_to_gfn(current->domain, gmfn));
+
__trace_var(event, 0/*!tsc*/, sizeof(gfn), &gfn);
}
Can't you use gfn_t here, and hence avoid the gfn_x()? Same again further
down.
Because __trace_var will export the value to the guest. I wasn't sure whether we
can safely consider that gfn_t is exactly the same as unsigned long in debug-build.
Cheers,
--
Julien Grall
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel