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: <20140306140243.GN9987@twins.programming.kicks-ass.net>
Date:	Thu, 6 Mar 2014 15:02:43 +0100
From:	Peter Zijlstra <peterz@...radead.org>
To:	Rasmus Villemoes <linux@...musvillemoes.dk>
Cc:	"H. Peter Anvin" <hpa@...or.com>,
	Khalid Aziz <khalid.aziz@...cle.com>, tglx@...utronix.de,
	Ingo Molnar <mingo@...nel.org>, akpm@...ux-foundation.org,
	andi.kleen@...el.com, rob@...dley.net, viro@...iv.linux.org.uk,
	oleg@...hat.com, venki@...gle.com, linux-kernel@...r.kernel.org
Subject: Re: [RFC] [PATCH] Pre-emption control for userspace

On Thu, Mar 06, 2014 at 02:45:00PM +0100, Rasmus Villemoes wrote:
> Peter Zijlstra <peterz@...radead.org> writes:
> 
> > On Thu, Mar 06, 2014 at 02:24:43PM +0100, Rasmus Villemoes wrote:
> >> Is it possible to implement non-sleeping versions of {get,put}_user()?
> >
> > __{get,put}_user()
> 
> Huh?
> 
> arch/x86/include/asm/uaccess.h:
> 
> /**
>  * __get_user: - Get a simple variable from user space, with less checking.
>  * @x:   Variable to store result.
>  * @ptr: Source address, in user space.
>  *
>  * Context: User context only.  This function may sleep.
> 
> What am I missing?

__get_user() -> __get_user_nocheck() -> __get_user_size() -> __get_user_asm()

And __get_user_asm() seems to generate the required .fixup section for
this to work in pagefault_disable() context.
--
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