From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from casper.infradead.org (casper.infradead.org [90.155.50.34]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 70AAE288D0; Fri, 17 Oct 2025 10:38:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=90.155.50.34 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760697499; cv=none; b=PGGxNKMstjSAi+YIhge9d4i4OOe9NOIuhsNKbw+NQZ3wselc7IZwzIfjd5+U6za1GAtij+DBp6QVl8MFglxVrRasQaqzYUwW9z5Wcz2wr4i9wefyKy0e6dKkAQbz3ae5ZuoYpzLEEkFjjdJVIFqn6xww26sAM9w/ma3ce7XRDVI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760697499; c=relaxed/simple; bh=8B4uYIt4n/VpUaqrH6E24NRdkkxqDj4yA/FMe0ayRhE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=rf/v+cdr/LEarrl+e7jO+T6gJJug5zbPMZoIldnL2zxzdmTE+HLSg4jnAvCIVUOevkN/yXMX2qyp8MdR6PN0y0G3Bif0uhI0RZuys77xcR8VFNeI0R1NGd2I6NGdNhqchPpV57jETAu3dBBtYVNGxkJqybK/hNRMypi7YTzx+I0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org; spf=none smtp.mailfrom=infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=rx05nYJA; arc=none smtp.client-ip=90.155.50.34 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=infradead.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="rx05nYJA" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=nWS8mbbAyKknksTkgFaSq1Uk5/fAQaz/isktn9K57hg=; b=rx05nYJAYN+RTwLB2lGfP1bKqX cPz5fqwLakGazsonqYKuradYhuAqs/nZNMp1UmMdmEfCx/0wwDD1Jo8DUW2lVPnJwIO6NufWGAA9r ZiUDqFrLMAam5RoKlt9adHo8b8Nkesw6GoiJ3pPrPHmQwBLTDcZDeMMDpoeIh/vzMVcK8i9VuHnvA GdtPmogaKpTQntPRIva/xPzJCazhbx9a7ZE/fV3ObzJngfuEGmNt4pPpmcf/oqbUye2TOgbB5JjbS DIiU97r47NbJ1u6sTo7huCPbrCOm4ElFLO5G2diIbCi3+DVFhpmeU5zExTsMiYzZevf9n4rETyW3X VfZs2JcA==; Received: from 77-249-17-252.cable.dynamic.v4.ziggo.nl ([77.249.17.252] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.98.2 #2 (Red Hat Linux)) id 1v9hqO-00000008mcj-0Bmj; Fri, 17 Oct 2025 10:37:57 +0000 Received: by noisy.programming.kicks-ass.net (Postfix, from userid 1000) id 8AB1130023C; Fri, 17 Oct 2025 12:37:55 +0200 (CEST) Date: Fri, 17 Oct 2025 12:37:55 +0200 From: Peter Zijlstra To: Thomas Gleixner Cc: LKML , kernel test robot , Russell King , linux-arm-kernel@lists.infradead.org, Linus Torvalds , x86@kernel.org, Madhavan Srinivasan , Michael Ellerman , Nicholas Piggin , Christophe Leroy , linuxppc-dev@lists.ozlabs.org, Paul Walmsley , Palmer Dabbelt , linux-riscv@lists.infradead.org, Heiko Carstens , Christian Borntraeger , Sven Schnelle , linux-s390@vger.kernel.org, Mathieu Desnoyers , Andrew Cooper , Julia Lawall , Nicolas Palix , Darren Hart , Davidlohr Bueso , =?iso-8859-1?Q?Andr=E9?= Almeida , Alexander Viro , Christian Brauner , Jan Kara , linux-fsdevel@vger.kernel.org Subject: Re: [patch V3 00/12] uaccess: Provide and use scopes for user masked access Message-ID: <20251017103755.GZ4067720@noisy.programming.kicks-ass.net> References: <20251017085938.150569636@linutronix.de> Precedence: bulk X-Mailing-List: linux-s390@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20251017085938.150569636@linutronix.de> On Fri, Oct 17, 2025 at 12:08:54PM +0200, Thomas Gleixner wrote: > After some back and forth discussion Linus suggested to put the local label > workaround into the user access functions themself. > Andrew thankfully pointed me to nested for() loops and after some head > scratching I managed to get all of it hidden in that construct. These two hacks are awesome and made my day; thanks! > Thomas Gleixner (12): > ARM: uaccess: Implement missing __get_user_asm_dword() > uaccess: Provide ASM GOTO safe wrappers for unsafe_*_user() > x86/uaccess: Use unsafe wrappers for ASM GOTO > powerpc/uaccess: Use unsafe wrappers for ASM GOTO > riscv/uaccess: Use unsafe wrappers for ASM GOTO > s390/uaccess: Use unsafe wrappers for ASM GOTO > uaccess: Provide scoped masked user access regions > uaccess: Provide put/get_user_masked() > futex: Convert to scoped masked user access > x86/futex: Convert to scoped masked user access Acked-by: Peter Zijlstra (Intel) > select: Convert to scoped masked user access Basically okay on this one too, except see the comment. > coccinelle: misc: Add scoped_masked_$MODE_access() checker script And that's just pure magic, I can't seem to get me head around coccinelle syntax.