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=-17.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT 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 228F2C47095 for ; Mon, 7 Jun 2021 16:26:11 +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 041EA6144E for ; Mon, 7 Jun 2021 16:26:10 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 041EA6144E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+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.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=T+CA2+45XzMXS9zWRkrBqf6eYbSZck6hxOD+HYq9ndc=; b=XrDUuqVE8DmTBD iPcB1SjjLdewuUa6xdFBVeoz/2m7di7cvgjESAHESkVzlooWCteDr62i3JaEIkjBhW1oFbmgnDZai 0gwjDkYPDsQ9gOMr+l2lrJBXj43V4v9Y5kx7QqR+gRUglLAGbuLIIKuksR8bDBhg6tyBF0vUa/oXv MRXyWHK1jf35DkecXm7jhjkTONbmASbRuQQvpftEx5cWuYgflXUa4Bpjk10IzDqKTst4h5Y6rehRE So3nyHzivWCdoORq2L3vNalaBBJh/x1+GG7tabEFmv2DdKbTgdKZ8GfeAt1ye9/cWCImIgwIYr6UG pX1TjujzoPpH76ncSoig==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1lqI2v-004U13-Vb; Mon, 07 Jun 2021 16:24:14 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1lqHtx-004Pjv-6L for linux-arm-kernel@lists.infradead.org; Mon, 07 Jun 2021 16:14:58 +0000 Received: by mail.kernel.org (Postfix) with ESMTPSA id 1BD3261432; Mon, 7 Jun 2021 16:14:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1623082496; bh=jHRM/4R/pQFCnYN0/rrh37kCWN38OC6C0X+sP8BxSxk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=GNdJHwjKumxuVoTJvLwn2FKaGLczrRVpRTWQ8FfGOil4vvVASv5MQJPfYWwTDS9Yk xotarzQRE70z7jm0sDdX+Rzx5PRQl3YRb+FgJu95kktBoKayl5F2meD6S1btuC6ZXs FTq8Qgfz0Uh4dfROMm5clkd0EJ/JJ2xG5J48un3iXszqc0HS1Nksszd/cpWyDdSXQb YcFfvI9irt463/3jEV/54EfW0mfxWg31YtPpSAMF0uAi6H+aJs7Eolfmb8/oyY63qs 1GCACjNxmzE50qfQ2iwYqoH/uiYfQuEjkcC9YITnP7MAwpLka0gArkPbnIX6kDH35p gV8AZLVSBOnpQ== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Yongqiang Liu , Tony Lindgren , Sasha Levin , linux-arm-kernel@lists.infradead.org, linux-omap@vger.kernel.org Subject: [PATCH AUTOSEL 4.19 06/21] ARM: OMAP2+: Fix build warning when mmc_omap is not built Date: Mon, 7 Jun 2021 12:14:33 -0400 Message-Id: <20210607161448.3584332-6-sashal@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210607161448.3584332-1-sashal@kernel.org> References: <20210607161448.3584332-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210607_091457_297019_320FB39C X-CRM114-Status: GOOD ( 11.77 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.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 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel