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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <5366D1F8.5040006@intel.com>
Date:	Sun, 04 May 2014 16:49:12 -0700
From:	"H. Peter Anvin" <h.peter.anvin@...el.com>
To:	Paolo Bonzini <pbonzini@...hat.com>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Andy Lutomirski <luto@...capital.net>
CC:	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	the arch/x86 maintainers <x86@...nel.org>,
	Steven Rostedt <rostedt@...dmis.org>,
	Gleb Natapov <gleb@...nel.org>
Subject: Re: [RFC/HACK] x86: Fast return to kernel

On 05/04/2014 04:46 PM, Paolo Bonzini wrote:
> 
> Your suggested trick of splitting the return paths for IF=0/IF=1 can be
> also done like this:
> 
>     movq EFLAGS-ARGOFFSET(%rsp), %rdi
>     btrq $9, %rdi        # Clear IF, save old value in CF
>     movq %rdi, (%rsi)
>     ...
>     popfq
>     jnc    1f        # If IF was 0, just return
>     sti            # Using STI gets us an interrupt shadow
> 1f:
>     retq
> 

That doesn't work, because CF gets restored by the popfq as well.
Unfortunately.

	-hpa


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ