From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AF31AC433F5 for ; Tue, 15 Feb 2022 10:26:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=zWhxqrUGSWJ+Zux8yYNkWC2w2bolS5KHDt0+7qbEyZ8=; b=RzSmhnxXPTBafR w6DXSR7L4fwqjq5V50jWp4HCXvI/P3LDUlfGYZVQk3WL2Er97t9drwDQF+vJ3a6jzezyPN87VaZc7 k+hYJU+oPY90Ba1Vba95WKKqKIK2/mjMJ4zf1JY2DE3aKP/wmOdAsIw6PFPO5iNhwtj92a/BNOZdj p6NpvtUwGqdjJjfoUZFFgJVhVxo/RkkeR3gbOTn2UWesk+1wNsmRDD9ClwtmCqC1Q6OkN3sUe0WMl XSnZE97ge8gr33je08s6d3Y6BHHrrt4Sjwz1e8dbVrCWbL7ccht8jdDWxgfFCsID8UAzjCXS7ymvb drhU0ZFk/Ru6Eknrs1NQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nJv1z-002IyJ-3M; Tue, 15 Feb 2022 10:25:59 +0000 Received: from ams.source.kernel.org ([2604:1380:4601:e00::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nJv1r-002ItJ-LB; Tue, 15 Feb 2022 10:25:54 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id B2AB4B8180A; Tue, 15 Feb 2022 10:25:49 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E87FEC340EB; Tue, 15 Feb 2022 10:25:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1644920748; bh=ff3JsyoyvYlhG8jzgNCTPV8IRM6/qaYw6mQrNFy9F74=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Idtvq2yMUPVIjRWGD6CbxsSP8vfjonXBjhqjw0KPeSxq9WG+eJI9q3VMhGdj4sPiw td4MlzEZussptBdaheJ5yjhE4vnfocIKiMf6Eye4k3uvvU7zndbY9d/28Z7fJPAVjQ V+ay13tyZYzyUl7pHGRP2ddUQDwCe4rTDO0IODfo= Date: Tue, 15 Feb 2022 11:25:44 +0100 From: Greg KH To: Arnd Bergmann Cc: Christoph Hellwig , Linus Torvalds , Christoph Hellwig , linux-arch , Linux-MM , Linux API , Arnd Bergmann , Linux Kernel Mailing List , Mark Rutland , Rich Felker , linux-ia64@vger.kernel.org, Linux-sh list , Peter Zijlstra , Max Filippov , Guo Ren , sparclinux , "open list:QUALCOMM HEXAGON..." , linux-riscv , Will Deacon , Ard Biesheuvel , linux-s390 , Brian Cain , Helge Deller , the arch/x86 maintainers , Russell King - ARM Linux , linux-csky@vger.kernel.org, Ingo Molnar , Geert Uytterhoeven , "open list:SYNOPSYS ARC ARCHITECTURE" , "open list:TENSILICA XTENSA PORT (xtensa)" , Heiko Carstens , alpha , linux-um , linux-m68k , Openrisc , Greentime Hu , Stafford Horne , Linux ARM , Michal Simek , Thomas Bogendoerfer , Parisc List , Nick Hu , "open list:BROADCOM NVRAM DRIVER" , "# 3.4.x" , Dinh Nguyen , "Eric W . Biederman" , Richard Weinberger , Andrew Morton , linuxppc-dev , David Miller Subject: Re: [PATCH 03/14] nds32: fix access_ok() checks in get/put_user Message-ID: References: <20220214163452.1568807-1-arnd@kernel.org> <20220214163452.1568807-4-arnd@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220215_022552_005847_A2D957FC X-CRM114-Status: GOOD ( 24.86 ) X-BeenThere: linux-snps-arc@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Linux on Synopsys ARC Processors List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-snps-arc" Errors-To: linux-snps-arc-bounces+linux-snps-arc=archiver.kernel.org@lists.infradead.org On Tue, Feb 15, 2022 at 10:18:15AM +0100, Arnd Bergmann wrote: > On Mon, Feb 14, 2022 at 6:01 PM Christoph Hellwig wrote: > > > > On Mon, Feb 14, 2022 at 05:34:41PM +0100, Arnd Bergmann wrote: > > > From: Arnd Bergmann > > > > > > The get_user()/put_user() functions are meant to check for > > > access_ok(), while the __get_user()/__put_user() functions > > > don't. > > > > > > This broke in 4.19 for nds32, when it gained an extraneous > > > check in __get_user(), but lost the check it needs in > > > __put_user(). > > > > Can we follow the lead of MIPS (which this was originally copied > > from I think) and kill the pointless __get/put_user_check wrapper > > that just obsfucate the code? > > I had another look, but I think that would be a bigger change than > I want to have in a fix for stable backports, as nds32 also uses > the _check versions in __{get,put}_user_error. Don't worry about stable backports first, get it correct and merged and then worry about them if you really have to. If someone cares about nds32 for stable kernels, they can do the backport work :) thanks, greg k-h _______________________________________________ linux-snps-arc mailing list linux-snps-arc@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-snps-arc