[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] x86/svm: Don't unconditionally use a new ASID in svm_invlpg_intercept()
commit eee511dec9d1f7e2bdfb4aebfe5ffbd70cdf6f51 Author: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> AuthorDate: Mon May 9 18:09:38 2016 +0100 Commit: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> CommitDate: Tue May 10 18:08:58 2016 +0100 x86/svm: Don't unconditionally use a new ASID in svm_invlpg_intercept() paging_invlpg() already returns a boolean indicating whether an invalidation is necessary or not. A return value of 0 indicates that the specified virtual address wasn't shadowed (or has already been flushed), cannot currently be cached in the TLB. This is a performance optimisation. Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> Reviewed-by: Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx> Reviewed-by: Tim Deegan <tim@xxxxxxx> Release-acked-by: Wei Liu <wei.liu2@xxxxxxxxxx> --- xen/arch/x86/hvm/svm/svm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xen/arch/x86/hvm/svm/svm.c b/xen/arch/x86/hvm/svm/svm.c index 7634c3f..081a5d8 100644 --- a/xen/arch/x86/hvm/svm/svm.c +++ b/xen/arch/x86/hvm/svm/svm.c @@ -2224,8 +2224,8 @@ static void svm_invlpg_intercept(unsigned long vaddr) { struct vcpu *curr = current; HVMTRACE_LONG_2D(INVLPG, 0, TRC_PAR_LONG(vaddr)); - paging_invlpg(curr, vaddr); - svm_asid_g_invlpg(curr, vaddr); + if ( paging_invlpg(curr, vaddr) ) + svm_asid_g_invlpg(curr, vaddr); } static struct hvm_function_table __initdata svm_function_table = { -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |