Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp3777366pxv; Mon, 28 Jun 2021 12:36:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxUh+A/BvmmIExD1liLIDzLl6SOXtlO/TuJl7hL6YtmZXW4xnAIM+T53j/QY9nIrac4PPR7 X-Received: by 2002:a92:3f01:: with SMTP id m1mr20280791ila.122.1624908983506; Mon, 28 Jun 2021 12:36:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624908983; cv=none; d=google.com; s=arc-20160816; b=sRSj/A4PL3m0XLKBhM9kaHyacQCRDKWEWinB7kmwPmylhPSSsAtQuS7hdg4EeIjkoN af4OEKw/UgE+f2EUIB4Dpz2nun7gJpn+8qxD7z5/q+qEMxc8Zk+AG42+umLMnZHXzanZ DkO/6S/6X+RVx6+tO40q1uIxcte9QJPBAEd/e9GiJFlrxpRrrbHBeSN2QgKKPpyMf2Hv hOhp3GusrTM59vQgxJkb5ExrDPS/bPZ0oKvVvaNbJ5r1/cFmP7Xb5WrAVksBDeQt7WzH tXGLSnW7H+BTGKUXSzA/A6tmQaZ9EpofAMH78IuuRwrxlTSLAmbtUKkLVB/VVl0TdCsh 2lFQ== 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=H/OouXXcY7RdBb768jmxHzcQJs6bKeXYLsfyxGWmrF8=; b=O81/GgbinImTF7fmGjBF3djKwgJezEbjSsQp9w4IaqAbqUOHSSiijB/PozqyPOcocu i5M24Eqk3l+SXdXFJTYR4NHdFVYJK0DGVRJus09bZ9GfBywdWLGO8kE5fLawG1QSQv+4 tDR64yDYoEkdnGt+CfZokkdCkqx0cAtSpiin3dpp8E6uhZh4AV93izRAmSMN2DyNBF/7 12GGCga14r9VhKWF7ibB5qS8vCIzeg0WEauj1jYTbsIqjbSgrutHVWRX3/fHLIs/o95q d2Eoszgz1vWS/Ab9+lL/yQ4c9TCyLa9qPvtIhiSzy9nxXttFjia9ct0yI6r8LO5Q8Jhw RyuQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=J1FxACTR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h17si1827267jav.42.2021.06.28.12.36.11; Mon, 28 Jun 2021 12:36:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-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=@kernel.org header.s=k20201202 header.b=J1FxACTR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232937AbhF1Oxm (ORCPT + 99 others); Mon, 28 Jun 2021 10:53:42 -0400 Received: from mail.kernel.org ([198.145.29.99]:43895 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235515AbhF1OkD (ORCPT ); Mon, 28 Jun 2021 10:40:03 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 8228C61D0E; Mon, 28 Jun 2021 14:33:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1624890793; bh=jHRM/4R/pQFCnYN0/rrh37kCWN38OC6C0X+sP8BxSxk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=J1FxACTRERzp/OdIbWkyWFdnQSfMo1jmkuQRgz4YEbm+lAFYhxQEi4pVRZ9fM+ZtU nRPOJ3VvrXZJAs87/1r43uaRmRjWP1XdaV430H/H2oMqugzdPakT/mvjFl2czFbg/n 7zcQhfOFg5IPID1YYyQE4UTXsQ5r/fTX0vIhLujRP+sFtus2bcdDMdPdYEDIYQP+m4 9xJ432wTQ/RmXbGQuksewHfmCeRGIx5r5TTD6EPZAfmM9rY24/zc6zotJUgwTlKfwP XozV2O1vrLd9ciczNsgJMV264uRl3aSgj9jFy/B169YwYaCoHUuBPRPClVS7pP/3tU eKvTSckioX5sQ== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Yongqiang Liu , Tony Lindgren , Sasha Levin Subject: [PATCH 4.19 006/109] ARM: OMAP2+: Fix build warning when mmc_omap is not built Date: Mon, 28 Jun 2021 10:31:22 -0400 Message-Id: <20210628143305.32978-7-sashal@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210628143305.32978-1-sashal@kernel.org> References: <20210628143305.32978-1-sashal@kernel.org> MIME-Version: 1.0 X-KernelTest-Patch: http://kernel.org/pub/linux/kernel/v4.x/stable-review/patch-4.19.196-rc1.gz X-KernelTest-Tree: git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git X-KernelTest-Branch: linux-4.19.y X-KernelTest-Patches: git://git.kernel.org/pub/scm/linux/kernel/git/stable/stable-queue.git X-KernelTest-Version: 4.19.196-rc1 X-KernelTest-Deadline: 2021-06-30T14:32+00:00 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Yongqiang Liu [ Upstream commit 040ab72ee10ea88e1883ad143b3e2b77596abc31 ] GCC reports the following warning with W=1: arch/arm/mach-omap2/board-n8x0.c:325:19: warning: variable 'index' set but not used [-Wunused-but-set-variable] 325 | int bit, *openp, index; | ^~~~~ Fix this by moving CONFIG_MMC_OMAP to cover the rest codes in the n8x0_mmc_callback(). Signed-off-by: Yongqiang Liu Signed-off-by: Tony Lindgren Signed-off-by: Sasha Levin --- arch/arm/mach-omap2/board-n8x0.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mach-omap2/board-n8x0.c b/arch/arm/mach-omap2/board-n8x0.c index 75bc18646df6..902e9df9b8bb 100644 --- a/arch/arm/mach-omap2/board-n8x0.c +++ b/arch/arm/mach-omap2/board-n8x0.c @@ -325,6 +325,7 @@ static int n8x0_mmc_get_cover_state(struct device *dev, int slot) static void n8x0_mmc_callback(void *data, u8 card_mask) { +#ifdef CONFIG_MMC_OMAP int bit, *openp, index; if (board_is_n800()) { @@ -342,7 +343,6 @@ static void n8x0_mmc_callback(void *data, u8 card_mask) else *openp = 0; -#ifdef CONFIG_MMC_OMAP omap_mmc_notify_cover_event(mmc_device, index, *openp); #else pr_warn("MMC: notify cover event not available\n"); -- 2.30.2