[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2 01/10] target/i386: fix INVD vmexit
From: |
Paolo Bonzini |
Subject: |
[PATCH v2 01/10] target/i386: fix INVD vmexit |
Date: |
Tue, 20 Jun 2023 17:16:25 +0200 |
Due to a typo or perhaps a brain fart, the INVD vmexit was never generated.
Fix it (but not that fixing just the typo would break both INVD and WBINVD,
due to a case of two wrongs making a right).
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
target/i386/tcg/translate.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/i386/tcg/translate.c b/target/i386/tcg/translate.c
index 5cf14311a60..0ef4d98ce79 100644
--- a/target/i386/tcg/translate.c
+++ b/target/i386/tcg/translate.c
@@ -6119,7 +6119,7 @@ static bool disas_insn(DisasContext *s, CPUState *cpu)
case 0x108: /* invd */
case 0x109: /* wbinvd */
if (check_cpl0(s)) {
- gen_svm_check_intercept(s, (b & 2) ? SVM_EXIT_INVD :
SVM_EXIT_WBINVD);
+ gen_svm_check_intercept(s, (b & 1) ? SVM_EXIT_WBINVD :
SVM_EXIT_INVD);
/* nothing to do */
}
break;
--
2.40.1
- [PATCH v2 00/10] target/i386: add a few simple features, Paolo Bonzini, 2023/06/20
- [PATCH v2 03/10] target/i386: TCG supports RDSEED, Paolo Bonzini, 2023/06/20
- [PATCH v2 04/10] target/i386: TCG supports XSAVEERPTR, Paolo Bonzini, 2023/06/20
- [PATCH v2 05/10] target/i386: TCG supports WBNOINVD, Paolo Bonzini, 2023/06/20
- [PATCH v2 02/10] target/i386: TCG supports 3DNow! prefetch(w), Paolo Bonzini, 2023/06/20
- [PATCH v2 01/10] target/i386: fix INVD vmexit,
Paolo Bonzini <=
- [PATCH v2 07/10] target/i386: sysret and sysexit are privileged, Paolo Bonzini, 2023/06/20
- [PATCH v2 08/10] target/i386: implement 32-bit SYSCALL for linux-user, Paolo Bonzini, 2023/06/20
- [PATCH v2 09/10] target/i386: implement 32-bit SYSENTER for linux-user, Paolo Bonzini, 2023/06/20
- [PATCH v2 06/10] target/i386: Intel only supports SYSCALL in long mode, Paolo Bonzini, 2023/06/20
- [PATCH v2 10/10] target/i386: implement RDPID in TCG, Paolo Bonzini, 2023/06/20