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=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_MUTT autolearn=ham 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 C592AC04AAC for ; Thu, 23 May 2019 07:47:19 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 773332133D for ; Thu, 23 May 2019 07:47:19 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="rZj7TWxR" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729583AbfEWHrS (ORCPT ); Thu, 23 May 2019 03:47:18 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:35296 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725814AbfEWHrS (ORCPT ); Thu, 23 May 2019 03:47:18 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.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: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=lsgHCa2vpCehpFETQiyNH/o7TEppcQLLkSY0AC+okiA=; b=rZj7TWxRADhac9Kvvt+/WDl6C bW6EfWL6kkFNW5mJuOaTXt7KeEjdw8yatC1AIV8E8Fk/iGOzC9/YduaBBOeV075273SM4j855TshK ochtlLTCj0BLyFLfQdxrONj6B7772aAOAulInHhxwyayetCdNyiYTD3WgKiLvocCoZ93fHsAfF2w+ jLKzq5/74UJMRNsrMSMeROaCAzWZSw9YBGV/4xDfA/GNO0HGbnMey+PSEUIrFv1P4yvinPeZcxfNa PaB8Ka0MhGFKGoQuM6qj+oSpKH8caqD36jMtEpKVQerx7x1el4lLaHN5HJGWqstYpsdirnZ7r4e4G 6wptVuhgQ==; Received: from hch by bombadil.infradead.org with local (Exim 4.90_1 #2 (Red Hat Linux)) id 1hTiRC-0003v4-Sr; Thu, 23 May 2019 07:46:54 +0000 Date: Thu, 23 May 2019 00:46:54 -0700 From: Christoph Hellwig To: Christophe Leroy Cc: Qian Cai , benh@kernel.crashing.org, paulus@samba.org, mpe@ellerman.id.au, aik@ozlabs.ru, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] powerpc/powernv: fix variable "c" set but not used Message-ID: <20190523074654.GA9873@infradead.org> References: <20190523023141.2973-1-cai@lca.pw> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.2 (2017-12-15) X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 23, 2019 at 09:26:53AM +0200, Christophe Leroy wrote: > You are not fixing the problem, you are just hiding it. > > If the result of __get_user() is unneeded, it means __get_user() is not the > good function to use. > > Should use fault_in_pages_readable() instead. Also it is not just the variable that is unused, but that whole function. I'll resend my series to remote it in a bit.