Hi Andrew,
On 06/11/2018 20:11, Andrew Cooper wrote:
This looks like it would be cleaner by not splitting mfn out into a
separate variable.
page = mfn_to_page(_mfn(gfn_x(gfn)));
return mfn_valid(mfn) && get_page(page, d) ? page : NULL;
The only reason this looks odd is because of the mfn => gfn equality,
but we are just beside a comment explaining that we are non-translated.
I introduced the mfn variable to avoid duplicating _mfn(gfn_x(gfn)) in the two
places where gfn was used.
I am happy to duplicated if you prefer.
Cheers,
--
Julien Grall
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel