On 04.12.2019 10:43, Andrew Cooper wrote:
> The local variable eventinj is set to the value of vmcb->exitintinfo which is
> confusing considering that it isn't vmcb->eventinj.  The variable isn't
> necessary to begin with, so drop it to avoid confusion.
> 
> A local rc variable is shadowed in the CPUID, #DB and #BP handlers.
> 
> There is a mix of spelling of inst_len and insn_len, all of which are
> logically the same value.  Consolidate on insn_len which also matches the name
> of the emulation functions for obtaining instruction lengths, and avoid
> shadowing it in the CPUID and TASK_SWITCH handlers.
> 
> Signed-off-by: Andrew Cooper <andrew.coop...@citrix.com>

Reviewed-by: Jan Beulich <jbeul...@suse.com>

> --- a/xen/arch/x86/hvm/svm/svm.c
> +++ b/xen/arch/x86/hvm/svm/svm.c
> @@ -2480,8 +2480,7 @@ void svm_vmexit_handler(struct cpu_user_regs *regs)
>      uint64_t exit_reason;
>      struct vcpu *v = current;
>      struct vmcb_struct *vmcb = v->arch.hvm.svm.vmcb;
> -    eventinj_t eventinj;
> -    int inst_len, rc;
> +    int insn_len, rc;

I'm not really happy to see insn_len be plain int, but the task switch
case requires it to be so (at least for the time being).

Jan

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to