Messages in this thread | | | Date | Fri, 30 Jun 2023 01:26:31 +0800 | Subject | Re: [PATCH v9 4/6] KVM: x86: Introduce untag_addr() in kvm_x86_ops | From | Binbin Wu <> |
| |
On 6/29/2023 11:16 PM, Sean Christopherson wrote: >> And for LAM, X86EMUL_F_IMPLICIT will not be used because in the implicit >> access to memory management registers or descriptors, >> the linear base addresses still need to be canonical and no hooks will be >> added to untag the addresses in these pathes. >> So I probably will remove the check for X86EMUL_F_IMPLICIT here. > No, please keep it, e.g. so that changes in the emulator don't lead to breakage, > and to document that they are exempt. > > If you want, you could do WARN_ON_ONCE() for the IMPLICIT case, but I don't know > that that's worthwhile, e.g. nothing will go wrong if KVM tries to untag an > implicit access, and deliberately avoiding the call make make it annoying to > consolidate code in the future. Right. Have a second thought, X86EMUL_F_IMPLICIT should be kept in case SVM has a different implementation and needs to do untag for IMPLICIT cases.
| |