• Sean Christopherson's avatar
    KVM: Drop kvm_reload_remote_mmus(), open code request in x86 users · 2f6f66cc
    Sean Christopherson authored
    Remove the generic kvm_reload_remote_mmus() and open code its
    functionality into the two x86 callers.  x86 is (obviously) the only
    architecture that uses the hook, and is also the only architecture that
    uses KVM_REQ_MMU_RELOAD in a way that's consistent with the name.  That
    will change in a future patch, as x86's usage when zapping a single
    shadow page x86 doesn't actually _need_ to reload all vCPUs' MMUs, only
    MMUs whose root is being zapped actually need to be reloaded.
    
    s390 also uses KVM_REQ_MMU_RELOAD, but for a slightly different purpose.
    
    Drop the generic code in anticipation of implementing s390 and x86 arch
    specific requests, which will allow dropping KVM_REQ_MMU_RELOAD entirely.
    
    Opportunistically reword the x86 TDP MMU comment to avoid making
    references to functions (and requests!) when possible, and to remove the
    rather ambiguous "this".
    
    No functional change intended.
    
    Cc: Ben Gardon <bgardon@google.com>
    Signed-off-by: default avatarSean Christopherson <seanjc@google.com>
    Reviewed-by: default avatarBen Gardon <bgardon@google.com>
    Message-Id: <20220225182248.3812651-4-seanjc@google.com>
    Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
    2f6f66cc
kvm_main.c 145 KB