x86: check paging mode earlier in xenmem_add_to_physmap_one()
authorJan Beulich <jbeulich@suse.com>
Tue, 28 Nov 2017 12:14:43 +0000 (13:14 +0100)
committerJan Beulich <jbeulich@suse.com>
Tue, 28 Nov 2017 12:14:43 +0000 (13:14 +0100)
commitf38f3dccf1e1a8aabcf57364326fc8f44cddc41a
treeca57980964baaf8518f7077a9c869f0c044c135c
parentf33d653f46f5889db7be4fef31d71bc871834c10
x86: check paging mode earlier in xenmem_add_to_physmap_one()

There's no point in deferring this until after some initial processing,
and it's actively wrong for the XENMAPSPACE_gmfn_foreign handling to not
have such a check at all.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: George Dunlap <george.dunlap@citrix.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
Release-acked-by: Julien Grall <julien.grall@linaro.org>
xen/arch/x86/mm.c