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] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 14 Jul 2016 15:52:47 +0200
From:	Radim Krčmář <rkrcmar@...hat.com>
To:	Suravee Suthikulpanit <Suravee.Suthikulpanit@....com>
Cc:	joro@...tes.org, pbonzini@...hat.com, alex.williamson@...hat.com,
	kvm@...r.kernel.org, linux-kernel@...r.kernel.org,
	sherry.hurwitz@....com
Subject: Re: [PART2 PATCH v4 10/11] svm: Introduce AMD IOMMU
 avic_ga_log_notifier

2016-07-14 16:43+0700, Suravee Suthikulpanit:
> On 7/13/16 21:29, Radim Krčmář wrote:
>> 2016-07-13 08:20-0500, Suravee Suthikulpanit:
>> > >diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c
>> > >+	hash_for_each_possible(svm_vm_data_hash, ka, hnode, vm_id) {
>> > >+		struct kvm *kvm = container_of(ka, struct kvm, arch);
>> > >+
>> > >+		vcpu = kvm_get_vcpu_by_id(kvm, vcpu_id);
>> The first result is not neccessarily the correct one.
>> 
>> With more than active 256 VMs, there is a guaranteed collision that
>> cannot be disambiguated, so VCPUs in both VMs need to be woken up.
>> 
>> Having a 24 bit vm_id and checking that
>>    kvm->*.avic_id & 0xfffff == vm_id
>> would help a bit to avoid useless wakeups, but the collision cannot be
>> avoided.
> 
> True. What if SVM guarantee that the VM_ID won't conflict b/w any two active
> VMs?

It is a nice way to avoid the bug you found in amd_iommu_update_ga() and
we would send only one wakeup here as well, so it sound like the best
solution.

Powered by blists - more mailing lists