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 X-Spam-Level: X-Spam-Status: No, score=-2.3 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 37550C433E0 for ; Thu, 21 May 2020 11:46:42 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id EC36F2070A for ; Thu, 21 May 2020 11:46:41 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="OAxMJ0Cd"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b="jyzicPHN" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EC36F2070A Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=armlinux.org.uk Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject: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=KRq8kXWfaKXkS7yjIv78cZglA5PW2mYfrieagxBJMnY=; b=OAxMJ0CdMew/qq bwUoz7Kw57vU90jfk5aBpaf3DWtKuPIpgyiHiqUoDZnrV0VzlTUCAH/Lhee/MGlokkxRttrLKQPih d4T4riak7SRWlP0+33zYClKBCe65GsOR3iLmuyCJlAYBUh/vZwnDE/pxvBKALpTDtGOcTiWqI5qR0 POplOHkDG3Rr/dTqcRZwRR/2c3dyENS1iuGU/YVJ7nFCDvBSenFuk8UFWIScueV3/IyddP4UQrsgz PvVhCD2on31a5//b2NV/+TOAzhhqtQBspXe3kzOr1wX+psLftd4LlcOp7JK+36rD3C6JqmXvHEdXb IvPTN9vP6CuJiS33ke0g==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jbjer-0002Sg-Gb; Thu, 21 May 2020 11:46:41 +0000 Received: from pandora.armlinux.org.uk ([2001:4d48:ad52:3201:214:fdff:fe10:1be6]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jbjen-0002QR-JU for linux-arm-kernel@lists.infradead.org; Thu, 21 May 2020 11:46:39 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=rsieF57gufe7ou9V7L0Dwppgjn2RE0LWW3aj4epHibE=; b=jyzicPHNA03f4JzG2fuRl4fCA YDU9nB+jas7c6+LLf0xryPU806VK8AaddWAoYgPjLoXhQNq4ZWX2vB5XDz4oabalOKFNLqCTEAhAT kp8U3++R/5dxFUqi1ocSGPR6KeeMTHY3pDJf5nPdVuKPC+RU3aFQOYJ/KUiI0wgZ/6ctl8KwNBE75 M2Kp4JHyjF8PN5I53ibZSpB0gi5/Q6pPnzzqYi7W15PqyuzICvVlteXaHyib27cFhTnRbiQLmuiRb bbUN4HsWB69tKtUgBqd73iNdK/qr4SAdE1T0sSy7ulWGOKD/ZAuemESLH2HAeuHUUvPXGM8RMedY9 cWnWtxUgQ==; Received: from shell.armlinux.org.uk ([2002:4e20:1eda:1:5054:ff:fe00:4ec]:60832) by pandora.armlinux.org.uk with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jbjeM-0002Ki-Dr; Thu, 21 May 2020 12:46:10 +0100 Received: from linux by shell.armlinux.org.uk with local (Exim 4.92) (envelope-from ) id 1jbjeJ-0000Ab-BN; Thu, 21 May 2020 12:46:07 +0100 Date: Thu, 21 May 2020 12:46:07 +0100 From: Russell King - ARM Linux admin To: Arnd Bergmann Subject: Re: [PATCH v4 0/7] firmware: smccc: Add basic SMCCC v1.2 + ARCH_SOC_ID support Message-ID: <20200521114607.GP1551@shell.armlinux.org.uk> References: <20200518091222.27467-1-sudeep.holla@arm.com> <158999823818.135150.13263761266508812198.b4-ty@kernel.org> <20200521070629.GB1131@bogus> <20200521075755.GA4668@willie-the-truck> <20200521081055.GD1131@bogus> <20200521101422.GO1551@shell.armlinux.org.uk> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200521_044637_642078_AF411AC0 X-CRM114-Status: GOOD ( 22.91 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , Lorenzo Pieralisi , Catalin Marinas , "linux-kernel@vger.kernel.org" , Steven Price , harb@amperecomputing.com, Sudeep Holla , Will Deacon , Linux ARM Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, May 21, 2020 at 12:31:32PM +0200, Arnd Bergmann wrote: > On Thu, May 21, 2020 at 12:14 PM Russell King - ARM Linux admin > wrote: > > > > On Thu, May 21, 2020 at 11:06:23AM +0200, Arnd Bergmann wrote: > > > Note that the warning should come up for either W=1 or C=1, and I also > > > think that > > > new code should generally be written sparse-clean and have no warnings with > > > 'make C=1' as a rule. > > > > No, absolutely not, that's a stupid idea, there are corner cases > > where hiding a sparse warning is the wrong thing to do. Look at > > many of the cases in fs/ for example. > > > > See https://lkml.org/lkml/2004/9/12/249 which should make anyone > > who sees a use of __force in some random code stop and question > > why it is there, and whether it is actually correct, or just there > > to hide a sparse warning. > > > > Remember, sparse is there to warn that something isn't quite right, > > and the view taken is, if it isn't right, then we don't "cast the > > warning away" with __force, even if we intend not to fix the code > > immediately. > > > > So, going for "sparse-clean" is actually not correct. Going for > > "no unnecessary warnings" is. > > > > And don't think what I've said above doesn't happen; I've rejected > > patches from people who've gone around trying to fix every sparse > > warning that they see by throwing __force incorrectly at it. > > > > The thing is, if you hide all the warnings, even for incorrect code, > > then sparse becomes completely useless to identify where things in > > the code are not quite correct. > > Adding __force is almost always the wrong solution, and I explictly > was not talking about existing code here where changing it would > risk introducing bugs or require bad hacks. I'm using existing code to illustrate the problem with your idea of "sparse-clean" new code, trying to show you that it is not about being sparse clean, but about being correct. > However, when writing a new driver, sparse warnings usually > indicate that you are doing something wrong that is better addressed > by doing something different that does not involve adding __force. Right, but if you lay down a rule that says "new submissions must be sparse clean" you will get people using __force to shut sparse up. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTC for 0.8m (est. 1762m) line in suburbia: sync at 13.1Mbps down 424kbps up _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel