From patchwork Wed Nov 4 09:06:00 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 320526 Delivered-To: patch@linaro.org Received: by 2002:a92:7b12:0:0:0:0:0 with SMTP id w18csp5280228ilc; Wed, 4 Nov 2020 01:10:12 -0800 (PST) X-Google-Smtp-Source: ABdhPJwbTJDJwehttEg8QMwnnxx/q+GCMWSkHzQWYgPrjE15kQieVQBz35NsNN6jN2hj6oRwUQ10 X-Received: by 2002:a17:906:c293:: with SMTP id r19mr23196702ejz.63.1604481012257; Wed, 04 Nov 2020 01:10:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604481012; cv=none; d=google.com; s=arc-20160816; b=a+c7XHvxHTqkoh9WnPgBXFdq0sUwX8hd7fpa9v0pzvSITOL1wAxg0Y3DFNb/qd7shi +/JLSkNj2dn4LLz9qU889hNcEFhDdaV85BkdqTHRICcgdxsSBPZEEaxFZjPJZg6XsY+y 5ogfXEWcDASnuC6qyD8giaw3L79c6qThZq2VFCg1/t/7J2Ey1cc81MezlGXxFVkkXd0G QgmXd8pkNTVVROFNqZUxNMCUebe1gXIPANGjyzW4IqIicoeRYXObv3oUaLloRIOvYUNn l06pifPRnP4v3wGakirF4e8x+gMkA4BphdoA3lzxMtElOvVYrQ51q7UPFdsaMChxLlWr Nl3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=c5eEvJlIJ9dRxH14TAwIWUTdkS+IjrVsnIh7Q0ggT08=; b=ohDispPY2k6Z8gSP/PLoH2G/ARkeG2/5hDKXGp6yprgVthI5xAhGCK9lrYDZHKIrw/ 9o9WZLiTIr/Y+u0+rcR16o7dFp0jx9EuWSFvPfI9nq7PZ6eMMPR2Ao6EJ0YAdR778UK0 kICf0CfKq/Ip+7DOCsb7JJHbBvIJ3cHntMsyNQNAcH70eN2K8GWA0Q2p6jQxP9vkmRJf oAJgiM0+z+i/SlNDGmRNLgsQK8qJWL++lP0apr4xCxCeK4JpF9PB3UtU4kgVGLXt8bpF 5gpIcR8DV1BLTivufmlkbNMt3MbaW78BI+t8n4YbtSPRwEVOnlmkJW0UVXyJhQV3C+j8 ZcHw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=brnfN0ua; spf=pass (google.com: domain of netdev-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id qo13si970967ejb.650.2020.11.04.01.10.12; Wed, 04 Nov 2020 01:10:12 -0800 (PST) Received-SPF: pass (google.com: domain of netdev-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=brnfN0ua; spf=pass (google.com: domain of netdev-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729353AbgKDJKJ (ORCPT + 8 others); Wed, 4 Nov 2020 04:10:09 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51124 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728612AbgKDJG1 (ORCPT ); Wed, 4 Nov 2020 04:06:27 -0500 Received: from mail-wr1-x441.google.com (mail-wr1-x441.google.com [IPv6:2a00:1450:4864:20::441]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 22615C0401C1 for ; Wed, 4 Nov 2020 01:06:27 -0800 (PST) Received: by mail-wr1-x441.google.com with SMTP id w1so21225287wrm.4 for ; Wed, 04 Nov 2020 01:06:27 -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=c5eEvJlIJ9dRxH14TAwIWUTdkS+IjrVsnIh7Q0ggT08=; b=brnfN0ua+I8Gz0uH1YV2F5yGMa1nzKtE/fciwy9jk3b9rq5I0aNfgD4mZJzX8y7I1E v3JDs7pEobe4Yi8iYBQ40zxZ8nXthK8OcVOLr67uk0SAcc/ubdXmUKHvE0/AK1rMDu01 yrRiiolMV4YiWRm8HrWgQJ0JQAFJoqCM0yyfQZqUrnR9NiJ8SwrEv5+7kDefd5+Gi3cq gaPUm3pKb2M6ijdOnMD5xlQYyoNvOCtnC5vEOz1OroBw8vK3P6Lcw338vkw3+ONJXbDj vbiyjSwa39RI1uguEompiCmYj46eiYl+u75lYB12uxNu8llPEM5POY4oMBpriKxwoZcs 6iwg== 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=c5eEvJlIJ9dRxH14TAwIWUTdkS+IjrVsnIh7Q0ggT08=; b=osJD7HgaeZOSrAo8u/G/yO4yBHYQTijI5oZotcxjVEiG5s9heV/KKpbk10+okMUUDN TLBd2rw+0xt25kiHB+RyYKVqlQfYkKYNBPlPdzfLVlPdVsPqXFlOjshZJmkGYRgTWDLm 1dTNdotLBLkhoE8bYdPMSq3ukZS4m6GzBxcTBbqTYRSNv6/5Vznb96NvXs3C+KKAleVL 5iDtZPwfd7VvLWKOg4q/aMw1U0L55I6ItWm/qPBPsjnFYrVLygWUX2aOFwAzCtHueS5g r9SSMzT/4Qvs6PaCc5aCjniYbjp0sv/jXWAYWRn5lkzpqV1sk/0aja3f9RYhV0iVT+B3 lG2w== X-Gm-Message-State: AOAM530q4fWYdyjYXAobydKI+0OIGUkj3lXzo/ujdC1EdyubV/lAz1bS X4hzfom7SLvb8rDA9+ktYev8Xw== X-Received: by 2002:a05:6000:1252:: with SMTP id j18mr29760015wrx.18.1604480785876; Wed, 04 Nov 2020 01:06:25 -0800 (PST) Received: from dell.default ([91.110.221.242]) by smtp.gmail.com with ESMTPSA id e25sm1607823wrc.76.2020.11.04.01.06.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Nov 2020 01:06:24 -0800 (PST) From: Lee Jones To: davem@davemloft.net, kuba@kernel.org Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Lee Jones , Dustin McIntire , netdev@vger.kernel.org Subject: [PATCH 02/12] net: ethernet: smsc: smc911x: Mark 'status' as __maybe_unused Date: Wed, 4 Nov 2020 09:06:00 +0000 Message-Id: <20201104090610.1446616-3-lee.jones@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201104090610.1446616-1-lee.jones@linaro.org> References: <20201104090610.1446616-1-lee.jones@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org 'status' is used to interact with a hardware register. It might not be safe to remove it entirely. Mark it as __maybe_unused instead. Fixes the following W=1 kernel build warning(s): drivers/net/ethernet/smsc/smc911x.c: In function ‘smc911x_phy_configure’: drivers/net/ethernet/smsc/smc911x.c:882:6: warning: variable ‘status’ set but not used [-Wunused-but-set-variable] drivers/net/ethernet/smsc/smc911x.c: In function ‘smc911x_phy_interrupt’: drivers/net/ethernet/smsc/smc911x.c:976:6: warning: variable ‘status’ set but not used [-Wunused-but-set-variable] drivers/net/ethernet/smsc/smc911x.c: In function ‘smc911x_timeout’: drivers/net/ethernet/smsc/smc911x.c:1251:6: warning: variable ‘status’ set but not used [-Wunused-but-set-variable] Cc: "David S. Miller" Cc: Jakub Kicinski Cc: Dustin McIntire Cc: netdev@vger.kernel.org Signed-off-by: Lee Jones --- drivers/net/ethernet/smsc/smc911x.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- 2.25.1 diff --git a/drivers/net/ethernet/smsc/smc911x.c b/drivers/net/ethernet/smsc/smc911x.c index 01069dfaf75c9..552953c376fe3 100644 --- a/drivers/net/ethernet/smsc/smc911x.c +++ b/drivers/net/ethernet/smsc/smc911x.c @@ -879,7 +879,7 @@ static void smc911x_phy_configure(struct work_struct *work) int phyaddr = lp->mii.phy_id; int my_phy_caps; /* My PHY capabilities */ int my_ad_caps; /* My Advertised capabilities */ - int status; + int __maybe_unused status; unsigned long flags; DBG(SMC_DEBUG_FUNC, dev, "--> %s()\n", __func__); @@ -973,7 +973,7 @@ static void smc911x_phy_interrupt(struct net_device *dev) { struct smc911x_local *lp = netdev_priv(dev); int phyaddr = lp->mii.phy_id; - int status; + int __maybe_unused status; DBG(SMC_DEBUG_FUNC, dev, "--> %s\n", __func__); @@ -1248,7 +1248,7 @@ static void smc911x_poll_controller(struct net_device *dev) static void smc911x_timeout(struct net_device *dev, unsigned int txqueue) { struct smc911x_local *lp = netdev_priv(dev); - int status, mask; + int __maybe_unused status, mask; unsigned long flags; DBG(SMC_DEBUG_FUNC, dev, "--> %s\n", __func__);