From mboxrd@z Thu Jan 1 00:00:00 1970 From: Al Viro Subject: Re: Use of copy_from_user in msm_gem_submit.c while holding a spin_lock Date: Wed, 17 Aug 2016 20:31:20 +0100 Message-ID: <20160817193120.GG2356@ZenIV.linux.org.uk> References: <57B44D2E.2030301@oracle.com> <20160817170827.GC2356@ZenIV.linux.org.uk> <20160817191534.GF2356@ZenIV.linux.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org To: Rob Clark Cc: Vaishali Thakkar , David Airlie , linux-arm-msm , "dri-devel@lists.freedesktop.org" , freedreno@lists.freedesktop.org, Linux Kernel Mailing List , Julia Lawall List-Id: linux-arm-msm@vger.kernel.org On Wed, Aug 17, 2016 at 03:24:38PM -0400, Rob Clark wrote: > hmm, looks like, at least on arm (not sure about arm64), > > #define __copy_from_user_inatomic __copy_from_user > > ie. copy_from_user() minus the access_ok() and memset in the > !access_ok() path.. but maybe what I want is just the > pagefault_disable() if that disables copy_from_user() being able to > block.. On a bunch of platforms copy_from_user() starts with might_sleep(); again, that'll spread to all of the pretty soon. Right now those primitives are very badly out of sync; this will change, but let's not add more PITA sources.