Re: [PATCH v9 09/17] x86/split_lock: Handle #AC exception for split lock
From: Paolo Bonzini
Date: Wed Oct 16 2019 - 12:38:50 EST
On 16/10/19 18:25, Xiaoyao Li wrote:
>>
>> ÂÂ 3 | YÂÂÂÂÂÂÂÂ |ÂÂÂÂ YÂÂÂÂÂÂ |Â NÂ |ÂÂ YÂÂÂÂ |ÂÂ xÂÂ | Switch
>> MSR_TEST_CTRL on
>> ÂÂÂÂ |ÂÂÂÂÂÂÂÂÂÂ |ÂÂÂÂÂÂÂÂÂÂÂÂ |ÂÂÂÂ |ÂÂÂÂÂÂÂÂ |ÂÂÂÂÂÂ | enter/exit,
>> plus:
>> ÂÂÂÂ |ÂÂÂÂÂÂÂÂÂÂ |ÂÂÂÂÂÂÂÂÂÂÂÂ |ÂÂÂÂ |ÂÂÂÂÂÂÂÂ |ÂÂÂÂÂÂ | A) #AC
>> forwarded to guest.
>> ÂÂÂÂ |ÂÂÂÂÂÂÂÂÂÂ |ÂÂÂÂÂÂÂÂÂÂÂÂ |ÂÂÂÂ |ÂÂÂÂÂÂÂÂ |ÂÂÂÂÂÂ | B) SIGBUS or
>> KVM exit code
>>
>
> I just want to get confirmed that in (3), we should split into 2 case:
>
> a) if host has it enabled, still apply the constraint that guest is
> forcibly enabled? so we don't switch MSR_TEST_CTL.
>
> b) if host has it disabled, we can switch MSR_TEST_CTL on enter/exit.
That's doable, yes.
Paolo