x86/mm: Remove unnecessary mfn_valid() call from get_page_from_l1e()
authorAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 27 Apr 2022 13:43:28 +0000 (14:43 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 18 May 2022 14:05:18 +0000 (15:05 +0100)
commitc154abe99d45fad110384e1ea75fad50b65962b3
tree477519409409a26a0506abd913dcdb5371b99025
parent25c160a74f4489f031ac79a24078cc12efd5c96b
x86/mm: Remove unnecessary mfn_valid() call from get_page_from_l1e()

mfn_valid() is not a trivially simple, and contains an evaluate_nospec() for
speculative defence.  Avoid calling it redundantly, and just store the result
of the first call.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/mm.c