Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp9132615pxu; Mon, 28 Dec 2020 07:25:38 -0800 (PST) X-Google-Smtp-Source: ABdhPJyPiIRMrRmcr9DXgyaU7LuFm0KBU3NpNjQj454qTx07g/5EPTKbXjs5XbWqbdvaPPLev60B X-Received: by 2002:a17:906:31cb:: with SMTP id f11mr2834143ejf.468.1609169137864; Mon, 28 Dec 2020 07:25:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1609169137; cv=none; d=google.com; s=arc-20160816; b=DrNisCkDwkM+JITGYu88b2du7NwOtT//4z/vn+wC+Syd3YT+R+WCLi5o+xbFy6CTMp 1ijlpTdqMtF790TcI9kSvXeDfHMPA6t5W1NzCCeqUY8bi/MnMzxSH/lV+jTPzlD/xv0j OB3xjsQINQpW9+QYqHbkTFsAtJsINEF18Am7Tf62B13VYwp4mfslb6lDejKFbYB4OhqN eGbnVbsQBT1lQdrO4TgiX/tNqmrJyggOpDyDupirAax/7GtEhIqBHa4jombe48OwQHfC UHBPTRFyg9cVTL6yrupCbk0p09suG7eGDcCxZ74XExn90hhwb44lqtx7USW3AqCi4KNF rQgQ== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=rMr86DwmPWTeKD46lRJUvqh2+2sCCerBnn/Osbz0U/A=; b=N0gJ5OW5ffIrExOpyD8OoPjIskUlzXewmfx9+IzAjXcOY/9dfjPVPJ5x3VgAK0JeCB wXRT3YYo/G5hBs4GlQcdRR/Dgp0EXz15/TNLHguuH7XXdVM1cSGUl+OrRyw3KU/ubtzn VdPKupxEJcsOwKu+bW8JsoUQhfcT6m5tbaWDR6kmXExiSvVNB2p/77CEmUDdjet3zfjW b1urbejhh32xhkXzCS6iaDp4A05pzY13L+DR/0SbWj3s1jM6LDaGT7i56njhi00FpUTn y/aw72RRPCtPMa0WlqDFNQqWzEgij44RiIsFp1svJz3NsdPUzu6y6VxG4wzABMb9eLhf 6rEw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=CEaMgNjb; 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=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t17si17436146eji.269.2020.12.28.07.25.13; Mon, 28 Dec 2020 07:25:37 -0800 (PST) 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=@linuxfoundation.org header.s=korg header.b=CEaMgNjb; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2440904AbgL1PXL (ORCPT + 99 others); Mon, 28 Dec 2020 10:23:11 -0500 Received: from mail.kernel.org ([198.145.29.99]:34768 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2436619AbgL1OBb (ORCPT ); Mon, 28 Dec 2020 09:01:31 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id BFB192064B; Mon, 28 Dec 2020 14:01:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1609164076; bh=78DGMlegYay+NAmrbGiq7DLAKwscd8kCXZYlTG2YNqA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=CEaMgNjbOL/ZMVOw+367qun4nw2BlCIrFRAACBPR0HwCbzQvdz4sQPgsYqKKRdALQ mBM119B6r4smi8wSGut5cnu63SrI5v4MohlOZ9DTNjQ4MbfXmJBYqxrsKatcEZjBrJ mJz9KeNFxBkeWh3fAiTApi/6OTDV2uO17s3UteuA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, He Zhe , Andy Shevchenko , Linus Walleij , Sasha Levin Subject: [PATCH 5.10 052/717] pinctrl: core: Add missing #ifdef CONFIG_GPIOLIB Date: Mon, 28 Dec 2020 13:40:50 +0100 Message-Id: <20201228125023.485376911@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201228125020.963311703@linuxfoundation.org> References: <20201228125020.963311703@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: He Zhe [ Upstream commit b507cb92477ad85902783a183c5ce01d16296687 ] To fix the following build warnings when CONFIG_GPIOLIB=n. drivers/pinctrl/core.c:1607:20: warning: unused variable 'chip' [-Wunused-variable] 1608 | struct gpio_chip *chip; | ^~~~ drivers/pinctrl/core.c:1606:15: warning: unused variable 'gpio_num' [-Wunused-variable] 1607 | unsigned int gpio_num; | ^~~~~~~~ drivers/pinctrl/core.c:1605:29: warning: unused variable 'range' [-Wunused-variable] 1606 | struct pinctrl_gpio_range *range; | ^~~~~ Fixes: f1b206cf7c57 ("pinctrl: core: print gpio in pins debugfs file") Signed-off-by: He Zhe Reviewed-by: Andy Shevchenko Link: https://lore.kernel.org/r/20201028103921.22486-1-zhe.he@windriver.com Signed-off-by: Linus Walleij Signed-off-by: Sasha Levin --- drivers/pinctrl/core.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index 3663d87f51a01..9fc4433fece4f 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -1602,9 +1602,11 @@ static int pinctrl_pins_show(struct seq_file *s, void *what) struct pinctrl_dev *pctldev = s->private; const struct pinctrl_ops *ops = pctldev->desc->pctlops; unsigned i, pin; +#ifdef CONFIG_GPIOLIB struct pinctrl_gpio_range *range; unsigned int gpio_num; struct gpio_chip *chip; +#endif seq_printf(s, "registered pins: %d\n", pctldev->desc->npins); -- 2.27.0