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, 5 Jul 2018 12:22:41 +0000
From:   "Raslan, KarimAllah" <karahmed@...zon.de>
To:     "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "kvm@...r.kernel.org" <kvm@...r.kernel.org>,
        "pbonzini@...hat.com" <pbonzini@...hat.com>
CC:     "rkrcmar@...hat.com" <rkrcmar@...hat.com>
Subject: Re: [PATCH] KVM: Switch 'requests' to be 64-bit (explicitly)

On Tue, 2018-05-22 at 17:47 +0200, Paolo Bonzini wrote:
> On 22/05/2018 17:42, Raslan, KarimAllah wrote:
> > 
> > On Mon, 2018-04-16 at 18:28 +0200, Paolo Bonzini wrote:
> > > 
> > > On 15/04/2018 00:26, KarimAllah Ahmed wrote:
> > > > 
> > > > 
> > > > Switch 'requests' to be explicitly 64-bit and update BUILD_BUG_ON check to
> > > > use the size of "requests" instead of the hard-coded '32'.
> > > > 
> > > > That gives us a bit more room again for arch-specific requests as we
> > > > already ran out of space for x86 due to the hard-coded check.
> > > > 
> > > > Cc: Paolo Bonzini <pbonzini@...hat.com>
> > > > Cc: Radim Krčmář <rkrcmar@...hat.com>
> > > > Cc: kvm@...r.kernel.org
> > > > Cc: linux-kernel@...r.kernel.org
> > > > Signed-off-by: KarimAllah Ahmed <karahmed@...zon.de>
> > > 
> > > I'm afraid architectures like ARM 32 need this to be conditional (using
> > > Kconfig).
> > 
> > Why would using a 64-bit 'requests' be a problem for ARM32? Are you 
> > concerned about performance here or is there some symantic problem?
> 
> They don't support atomics on double-word data.

But they support atomics on single words. Of which there are two.
We don't need atomic updates of the whole 64-bit quantity (a là 
cmpxchg). Do we strictly need this to be atomic accross the 64-bit?

Looking at the use cases for "requests":

kvm_clear_request
kvm_test_request
kvm_request_pending
kvm_check_request

... and all of them would still work if the atomicity is only at the 
word level, right?

> 
> Paolo
> 
Amazon Development Center Germany GmbH
Berlin - Dresden - Aachen
main office: Krausenstr. 38, 10117 Berlin
Geschaeftsfuehrer: Dr. Ralf Herbrich, Christian Schlaeger
Ust-ID: DE289237879
Eingetragen am Amtsgericht Charlottenburg HRB 149173 B

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ