Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp4800137pxb; Thu, 14 Oct 2021 12:12:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyR5n4o6kAhkec5oE1AdPZOh6lLeEFAH7k2SnPPRbiu7OQHNsqYGHdJHigFdrCjXLile7We X-Received: by 2002:a17:902:7c94:b0:13b:8d10:cc4f with SMTP id y20-20020a1709027c9400b0013b8d10cc4fmr6758441pll.54.1634238769019; Thu, 14 Oct 2021 12:12:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634238769; cv=none; d=google.com; s=arc-20160816; b=tb8ar9GJ5cl/ti5veBXRn57NBiSJd9Tknrz58gIJ1m28uA7a15Z0ML15pVQiD9CYam 1I1DKacIAS6wEs/7iocSU3XOQ0VpdneBG24dl1Wx7ULBFS29tzImWHXrDHJRvLkhZPKZ JW4g6tqkxF79t7DZiz54SpWxzHPqgni6HHwVxed42DhMSrJoPJLnSvPwi4+XDbbG4q8r e1O9Vog5tsJDAtfSdWSleUkN3epLJKpW3aV6MO3zKWDUumDX0tmpQbWUfMmhKclw6Zgn 6bRkj0t2HdQxO79QlDh2HYPjlsbNF4Ht/HNPJ1Pzq3XmVNckD1wEvXGSColEbktPofys QG8w== 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:subject:cc:to:from:date; bh=vGwFj8aWLEVDh4TPnNwOdyE1vbmUYD5+yd9XZT/wX1Y=; b=KQKszAJA1oO1nr9SxaSbi0u33h6eTTxF7A8Zm3QntUhNQPqchZekDXyS+YDdwBtSUD eUd4ESPrEoqwraYrtAc5k5i0zqw+IbJLNAOQbJkOWbO2BVlnt5iTB7mq6DUlktqqn57g Vx83ed2QPwtOiOb+JPyxmby3TVxQykvBujwj64TuSr1cAKINSZoM8tMwWf9wV8swceWV 06eF+iadWHY1Vajl1mfaHyxZkcHJ916pQeiXpseJHbyttAYb5LQaHzgeXpVgdDuanCDm O35aoQLbDwf586jd6g1DYBQfv1g3PXBg4iZFcPgREpNcMRYD0kCt32KkreFmm9KhB/Jo 6gYA== ARC-Authentication-Results: i=1; mx.google.com; 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 z11si4269397pfc.266.2021.10.14.12.12.35; Thu, 14 Oct 2021 12:12:49 -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; 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 S233539AbhJNRmx convert rfc822-to-8bit (ORCPT + 99 others); Thu, 14 Oct 2021 13:42:53 -0400 Received: from mail.kernel.org ([198.145.29.99]:55952 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232779AbhJNRmw (ORCPT ); Thu, 14 Oct 2021 13:42:52 -0400 Received: from jic23-huawei (cpc108967-cmbg20-2-0-cust86.5-4.cable.virginm.net [81.101.6.87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id EF3A361037; Thu, 14 Oct 2021 17:40:43 +0000 (UTC) Date: Thu, 14 Oct 2021 18:44:55 +0100 From: Jonathan Cameron To: Randy Dunlap Cc: Cai Huoqing , Arnd Bergmann , Shawn Guo , Sascha Hauer , Fabio Estevam , Arnd Bergmann , Lars-Peter Clausen , Pengutronix Kernel Team , NXP Linux Team , linux-iio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] iio: imx8qxp-adc: mark PM functions as __maybe_unused Message-ID: <20211014184448.474849a9@jic23-huawei> In-Reply-To: <50f71530-bab0-58f4-cf90-a7c1b60b9716@infradead.org> References: <20211013144338.2261316-1-arnd@kernel.org> <20211014012936.GA2999@LAPTOP-UKSR4ENP.internal.baidu.com> <50f71530-bab0-58f4-cf90-a7c1b60b9716@infradead.org> X-Mailer: Claws Mail 4.0.0 (GTK+ 3.24.30; x86_64-pc-linux-gnu) 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 On Wed, 13 Oct 2021 18:40:41 -0700 Randy Dunlap wrote: > On 10/13/21 6:29 PM, Cai Huoqing wrote: > > On 13 10月 21 16:43:26, Arnd Bergmann wrote: > >> From: Arnd Bergmann > >> > >> Without CONFIG_PM_SLEEP, the runtime suspend/resume functions > >> are unused, producing a warning: > >> > >> drivers/iio/adc/imx8qxp-adc.c:433:12: error: 'imx8qxp_adc_runtime_resume' defined but not used [-Werror=unused-function] > >> 433 | static int imx8qxp_adc_runtime_resume(struct device *dev) > >> | ^~~~~~~~~~~~~~~~~~~~~~~~~~ > >> drivers/iio/adc/imx8qxp-adc.c:419:12: error: 'imx8qxp_adc_runtime_suspend' defined but not used [-Werror=unused-function] > >> 419 | static int imx8qxp_adc_runtime_suspend(struct device *dev) > >> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ > >> > >> Mark them as __maybe_unused to shut up the compiler. > >> > >> Fixes: 7bce634d02e6 ("iio: imx8qxp-adc: Add driver support for NXP IMX8QXP ADC") > >> Signed-off-by: Arnd Bergmann > > > > Reviewed-by: Cai Huoqing > > Looks the same as > https://lore.kernel.org/all/20211013014658.2798-1-caihuoqing@baidu.com/ > > but that one is mixing the Fixes: tag. Given Cai replied to this one and the presence of the fixes tag + my inherent laziness, applied this one to the togreg branch of iio.git. I'll push that out as testing to let 0-day poke it before pushing it out for next to pick up in a day or 2. Thanks, Jonathan > > >> --- > >> drivers/iio/adc/imx8qxp-adc.c | 4 ++-- > >> 1 file changed, 2 insertions(+), 2 deletions(-) > >> > >> diff --git a/drivers/iio/adc/imx8qxp-adc.c b/drivers/iio/adc/imx8qxp-adc.c > >> index 5030e0d8318d..901dd8e1b32f 100644 > >> --- a/drivers/iio/adc/imx8qxp-adc.c > >> +++ b/drivers/iio/adc/imx8qxp-adc.c > >> @@ -416,7 +416,7 @@ static int imx8qxp_adc_remove(struct platform_device *pdev) > >> return 0; > >> } > >> > >> -static int imx8qxp_adc_runtime_suspend(struct device *dev) > >> +static __maybe_unused int imx8qxp_adc_runtime_suspend(struct device *dev) > >> { > >> struct iio_dev *indio_dev = dev_get_drvdata(dev); > >> struct imx8qxp_adc *adc = iio_priv(indio_dev); > >> @@ -430,7 +430,7 @@ static int imx8qxp_adc_runtime_suspend(struct device *dev) > >> return 0; > >> } > >> > >> -static int imx8qxp_adc_runtime_resume(struct device *dev) > >> +static __maybe_unused int imx8qxp_adc_runtime_resume(struct device *dev) > >> { > >> struct iio_dev *indio_dev = dev_get_drvdata(dev); > >> struct imx8qxp_adc *adc = iio_priv(indio_dev); > >> -- > > > >