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]
Message-ID: <CAFEAcA-xuUPukf9EPeetr_+RSU7FPDMXmyk3zbjY=FcV65CF=g@mail.gmail.com>
Date:   Fri, 9 Nov 2018 12:56:54 +0000
From:   Peter Maydell <peter.maydell@...aro.org>
To:     Mark Rutland <mark.rutland@....com>
Cc:     Alex Bennée <alex.bennee@...aro.org>,
        kvm-devel <kvm@...r.kernel.org>,
        Marc Zyngier <marc.zyngier@....com>,
        Catalin Marinas <catalin.marinas@....com>,
        Will Deacon <will.deacon@....com>,
        open list <linux-kernel@...r.kernel.org>,
        Christoffer Dall <christoffer.dall@...aro.org>,
        kvmarm@...ts.cs.columbia.edu,
        arm-mail-list <linux-arm-kernel@...ts.infradead.org>
Subject: Re: [RFC PATCH] KVM: arm64: don't single-step for non-emulated faults

On 9 November 2018 at 12:49, Mark Rutland <mark.rutland@....com> wrote:
> I'm not saying anything about *decisions*. I'm saying that we can make
> the state consistent by advancing the singlestep state in the same way
> that HW does, at the instant it advances the PC.
>
> i.e. do that in kvm_skip_instr(), as I've done in my local tree.
>
> That mirrors the HW, and we don't need to special-case any handling for
> emulated vs non-emulated instructions.

You also need to do it in the "set PC because we're making the guest
take an exception" code path, which doesn't go through kvm_skip_instr().
This corresponds to the two kinds of "step completed" in hardware as
noted in DDI0487D.a D2.12.3 fig D2-3 footnote b:
 * executing the instruction to be stepped without taking an exception
 * taking an exception to an exception level that debug exceptions
   are enabled from [ie guest EL1 in our case]

thanks
-- PMM

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ