From patchwork Mon Nov 9 18:21:58 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 320965 Delivered-To: patch@linaro.org Received: by 2002:a92:7b12:0:0:0:0:0 with SMTP id w18csp1957649ilc; Mon, 9 Nov 2020 10:25:19 -0800 (PST) X-Google-Smtp-Source: ABdhPJyOa6/9W8l0mFDTqOCMWKa7lHfjFuEDa2aGCOg3MG2Jv3KfdC6lVDpC7fWD+CijyripH/oK X-Received: by 2002:adf:814f:: with SMTP id 73mr19321134wrm.174.1604946319252; Mon, 09 Nov 2020 10:25:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604946319; cv=none; d=google.com; s=arc-20160816; b=DFkfZrQogAHL3n0vMft+QMZ8yi2I8EG9p3T1pIZsQEX+4GtdaT1dQKw0E55s9GRgww iTw277rpmiBkCJl/NS3GF3R91NsCf+4xuBUeOrahHScW7LrhwhmA8xVUSVgtJdDWrpUm f6Ung4jbS4Q2kGaLv+IwdViov7ePvfZ+jqPNtCtmOelGGal7OjSKgZbCh8CIFuaudrWh PfhfmSHxQvxEWqReH7qim4QYzQ2DOJX4zJxG6xJyTOIU6sTzfxEaOxxWCr7ORWv3Vfg8 TnuJXIR2veM7y4jem6cfnqPd6vlEIVgLxvzkJXS0hej8Lt3OPxystKF4b1bheA9fStpM R/bQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:cc:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:mime-version:references:in-reply-to:message-id:date :subject:to:from:dkim-signature:dkim-signature; bh=n/DTXePThcgrH6HMtQaU/usSvTmxDbR/cIp+unxHlng=; b=rlSySK8bQui/OsXJO/69QvQcLZPakkrs7W9hO2/pHyUg2AkTODXckpJBwbbsoUHIDl ZqjkKO5ixbEbFGnfGi40lQi52J8HiIesYQm/XQCl9heaOjpVkBIam2hpVnh0yKqN3cHB INJHi7u1a4uzIF5G5FGMBgZt5EN4LHt/fwjnqEqr7MW8OdUGj763XhEm1591/DXULYY0 El+qozFpdHETjIf/0HWZb4nyXwKSpiTnuRYDSK5fdeqpllewKh22DazuOkaeRPwYQtvq GJTMTUnUHVHbmi6/VwPtFH6XjeBUb/n1GoArCSZ1BYEDYoAELK0Xs/NUJi4tHFJuILOh 4CBQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lists.infradead.org header.s=merlin.20170209 header.b=izLl13s0; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=eespszn+; spf=pass (google.com: best guess record for domain of linux-mtd-bounces+patch=linaro.org@lists.infradead.org designates 2001:8b0:10b:1231::1 as permitted sender) smtp.mailfrom="linux-mtd-bounces+patch=linaro.org@lists.infradead.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from merlin.infradead.org (merlin.infradead.org. [2001:8b0:10b:1231::1]) by mx.google.com with ESMTPS id v17si10618484wrn.178.2020.11.09.10.25.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Nov 2020 10:25:19 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-mtd-bounces+patch=linaro.org@lists.infradead.org designates 2001:8b0:10b:1231::1 as permitted sender) client-ip=2001:8b0:10b:1231::1; Authentication-Results: mx.google.com; dkim=pass header.i=@lists.infradead.org header.s=merlin.20170209 header.b=izLl13s0; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=eespszn+; spf=pass (google.com: best guess record for domain of linux-mtd-bounces+patch=linaro.org@lists.infradead.org designates 2001:8b0:10b:1231::1 as permitted sender) smtp.mailfrom="linux-mtd-bounces+patch=linaro.org@lists.infradead.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=n/DTXePThcgrH6HMtQaU/usSvTmxDbR/cIp+unxHlng=; b=izLl13s0AhUr0BgnM1Pb26WYN xSf1cLu1tcRJl9MbZ4tJBf589eCxICWRYxQ8VFOn9zRb1AoJBenh6EBXfK9imu82u58qg8w2swirl X4r9C4iO5wYMqsN6uvQisovkygFkQ7d08W8cMgN/VZUfXcGixJv3ODGKNEe/mb2VEQqP6iRdc8umA 1iMVtQUU16FKGeQbYDMXrVs07vwRop65AlIlltcaHRRmzZNBL1F8ELa+i7k79a0MsP/Rg6tsMfQKk J2YkaJBIpVnKVLCftgklB7LS0NNy2wpmZCnVBInq684Ap21v0RtwyexS3SYj/g9z2KESFfXEpuGNa biN1CXBoA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kcBqj-00022g-7w; Mon, 09 Nov 2020 18:25:05 +0000 Received: from mail-wr1-x444.google.com ([2a00:1450:4864:20::444]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kcBoR-0000wd-0v for linux-mtd@lists.infradead.org; Mon, 09 Nov 2020 18:22:53 +0000 Received: by mail-wr1-x444.google.com with SMTP id o15so1970968wru.6 for ; Mon, 09 Nov 2020 10:22:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=zU6AEe7QJ86BUUdNT9vgeNl78+UInfUWOmxhJubmBR0=; b=eespszn+YzerPW89j0B6QI6zk+RxJ1PHs9P1SEM5hZerhh3ZzcZTRQ7GHYMYUf+Dga ++A4cusms1L/Pe1u5fJ/lrRe8YuhE0YY4giowbFwEgp7orkXRh/ShfipGTynSUZfJG6n 39I7QLU/e3j/1irF9M3iDMWnl/RkEj1RCEy3SK0goOba5IQrXJWY6/lDuy2s6qVpbGcD 4JTixvz6bWmsoKNFGRlTSQOfZPXUMjf7969pxHbsAuzxn1/emvmh3hcYmCMpR9/GwKmE /1L09ZZE7s99hP1qDvCXoyVha6cwY597da0n090H+kuJ4XNbD/lqED4riT3Nev2R1ZIB zvkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=zU6AEe7QJ86BUUdNT9vgeNl78+UInfUWOmxhJubmBR0=; b=ZU0GFFKCtC8a/yWlOhqah6ZCPOH5SSu6xqM//Dr+K0mHvLY2zSWSPJOExcFPWjrkgx 716HsdRQpRZoRr1lE/7aWNlP37iITyUXYBX0a73ZL2rSoSV0RdDNDJWV+lHARLZqIfeC GIwx7FINBYvn5yLhYuB4sf7r/f5/4l4jzOff/heltkMheigt4mgPTY/rcH43vuosolkU SSz9F5GX4nBlJyUDF/WjBzEZaHdmARkSwzQO2YPRegHFhnDLFrlI3ntCHMa/bUBGsbOM tqyG6gTsLrSRKhjneF4DcCWM9x1CqO4rPV3b25grDWgWztnivSLA8BgPPNLEAC9m1iQX F+dA== X-Gm-Message-State: AOAM531KXaUNFK/MSjtQOFTJtpBMMYPaExPPaJt8DWSN/7JAjebcN/dn lraB01PFBgqJAVfxDiK9cN/70A== X-Received: by 2002:adf:f9c4:: with SMTP id w4mr20167333wrr.64.1604946161879; Mon, 09 Nov 2020 10:22:41 -0800 (PST) Received: from dell.default ([91.110.221.180]) by smtp.gmail.com with ESMTPSA id g186sm735365wma.1.2020.11.09.10.22.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Nov 2020 10:22:41 -0800 (PST) From: Lee Jones To: lee.jones@linaro.org Subject: [PATCH v3 15/23] mtd: rawnand: diskonchip: Marking unused variables as __always_unused Date: Mon, 9 Nov 2020 18:21:58 +0000 Message-Id: <20201109182206.3037326-16-lee.jones@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201109182206.3037326-1-lee.jones@linaro.org> References: <20201109182206.3037326-1-lee.jones@linaro.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201109_132243_117520_49ED3569 X-CRM114-Status: GOOD ( 20.05 ) X-Spam-Score: -0.2 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (-0.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:444 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Dan Brown , Vignesh Raghavendra , Richard Weinberger , linux-kernel@vger.kernel.org, Boris Brezillon , linux-mtd@lists.infradead.org, Miquel Raynal , Thomas Gleixner , David Woodhouse Sender: "linux-mtd" Errors-To: linux-mtd-bounces+patch=linaro.org@lists.infradead.org 'dummy' is never checked (as per the nomenclature) and the use of 'emtpymatch' is currently #if 0'ed out. We could also #if 0 the declaration, but #ifery is pretty ugly, so I like to keep it to a minimum. Fixes the following W=1 kernel build warning(s): drivers/mtd/nand/raw/diskonchip.c: In function ‘DoC_Delay’: drivers/mtd/nand/raw/diskonchip.c:219:16: warning: variable ‘dummy’ set but not used [-Wunused-but-set-variable] drivers/mtd/nand/raw/diskonchip.c: In function ‘doc200x_calculate_ecc’: drivers/mtd/nand/raw/diskonchip.c:706:6: warning: variable ‘emptymatch’ set but not used [-Wunused-but-set-variable] Cc: Miquel Raynal Cc: Richard Weinberger Cc: Vignesh Raghavendra Cc: Boris Brezillon Cc: Dan Brown Cc: David Woodhouse Cc: Thomas Gleixner Cc: linux-mtd@lists.infradead.org Signed-off-by: Lee Jones --- drivers/mtd/nand/raw/diskonchip.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/mtd/nand/raw/diskonchip.c b/drivers/mtd/nand/raw/diskonchip.c index 94432a453e5ee..d5050e32cc421 100644 --- a/drivers/mtd/nand/raw/diskonchip.c +++ b/drivers/mtd/nand/raw/diskonchip.c @@ -216,7 +216,7 @@ static int doc_ecc_decode(struct rs_control *rs, uint8_t *data, uint8_t *ecc) static void DoC_Delay(struct doc_priv *doc, unsigned short cycles) { - volatile char dummy; + volatile char __always_unused dummy; int i; for (i = 0; i < cycles; i++) { @@ -703,7 +703,7 @@ static int doc200x_calculate_ecc(struct nand_chip *this, const u_char *dat, struct doc_priv *doc = nand_get_controller_data(this); void __iomem *docptr = doc->virtadr; int i; - int emptymatch = 1; + int __always_unused emptymatch = 1; /* flush the pipeline */ if (DoC_is_2000(doc)) {