lkml.org 
[lkml]   [2022]   [Mar]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [RFC PATCH v5 005/104] KVM: x86: Refactor KVM VMX module init/exit functions
    Thanks for review.

    On Sun, Mar 13, 2022 at 02:54:15PM +0100,
    Paolo Bonzini <pbonzini@redhat.com> wrote:

    > On 3/4/22 20:48, isaku.yamahata@intel.com wrote:
    > > -static int __init vmx_init(void)
    > > -{
    > > - int r, cpu;
    > > + if (sizeof(struct vcpu_vmx) > *vcpu_size)
    > > + *vcpu_size = sizeof(struct vcpu_vmx);
    > > + if (__alignof__(struct vcpu_vmx) > *vcpu_align)
    > > + *vcpu_align = __alignof__(struct vcpu_vmx);
    >
    > Please keep these four lines in vt_init, and rename the rest of
    > vmx_pre_kvm_init to hv_vp_assist_page_init. Likewise, rename
    > vmx_post_kvm_exit to hv_vp_assist_page_exit.
    >
    > Adjusting the vcpu_size and vcpu_align for TDX (I guess) can be added later
    > when TDX ops are introduced.

    sure. I'll make it like
    vcpu_size = max(sizeof(struct vcpu_vmx), sizeof(vcpu_tdx));
    ...


    Thanks,
    --
    Isaku Yamahata <isaku.yamahata@gmail.com>

    \
     
     \ /
      Last update: 2022-03-14 20:24    [W:3.357 / U:1.212 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site