On 16/06/21 14:39, Lara Lazier wrote:
> Following the APM2 I added some checks to
> resolve the following tests in kvm-unit-tests for svm:
>
> * vmrun_intercept_check
> * asid_zero
> * sel_cr0_bug
> * CR0 CD=0,NW=1: a0010011
> * CR0 63:32: 180010011
> * CR0 63:32: 1080010011
> * CR0 63:32: 10080010011
> * CR0 63:32: 100080010011
> * CR0 63:32: 1000080010011
> * CR0 63:32: 10000080010011
> * CR0 63:32: 100000080010011
> * CR0 63:32: 1000000080010011
>
> v1->v2: introduced cpu_svm_has_intercept to avoid defining bitmasks for
> intercepts
>
> Lara Lazier (4):
> target/i386: Refactored intercept checks into cpu_svm_has_intercept
> target/i386: Added consistency checks for VMRUN intercept and ASID
> target/i386: Added consistency checks for CR0
> target/i386: Added Intercept CR0 writes check
>
> target/i386/cpu.h | 5 ++
> target/i386/svm.h | 2 +
> target/i386/tcg/sysemu/misc_helper.c | 9 ++
> target/i386/tcg/sysemu/svm_helper.c | 127 ++++++++++++++++-----------
> 4 files changed, 93 insertions(+), 50 deletions(-)
>
Looks good. I fixed the small issue in patch 1 and queued it, thanks.
It will appear in a pull request later this week.
Paolo