lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <d2c3471d-3234-5e0a-0c76-872040a65bb6@redhat.com>
Date:   Tue, 25 Feb 2020 15:01:52 +0100
From:   Paolo Bonzini <pbonzini@...hat.com>
To:     Vitaly Kuznetsov <vkuznets@...hat.com>
Cc:     rmuncrief@...anavance.com, linux-kernel@...r.kernel.org,
        kvm@...r.kernel.org
Subject: Re: [PATCH] KVM: SVM: allocate AVIC data structures based on kvm_amd
 moduleparameter

On 25/02/20 14:45, Vitaly Kuznetsov wrote:
>>  	int ret;
>> +	struct kvm_vcpu *vcpu = &svm->vcpu;
>>  
>> -	if (!kvm_vcpu_apicv_active(&svm->vcpu))
>> +	if (!avic || !irqchip_in_kernel(vcpu->kvm))
>>  		return 0;
>>  
>>  	ret = avic_init_backing_page(&svm->vcpu);
> Out of pure curiosity,
> 
> when irqchip_in_kernel() is false, can we still get to .update_pi_irte()
> (svm_update_pi_irte()) -> get_pi_vcpu_info() -> "vcpu_info->pi_desc_addr
> = __sme_set(page_to_phys((*svm)->avic_backing_page));" -> crash! or is
> there anything which make this impossible?

No, because kvm_arch_irqfd_allowed returns false so you cannot create
any irqfd (svm_update_pi_irte is called when virt/lib/irqbypass.c finds
a match between two eventfds in KVM and VFIO).

Paolo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ