Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp361918pxx; Thu, 29 Oct 2020 04:36:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJynNtlp+w0Nt8EuaU7ZRK8vPOGwfj/Qd2/McjuGaZWVqFCgRLaPFlM82GGztvhiuAB9QZjq X-Received: by 2002:aa7:d28a:: with SMTP id w10mr3515412edq.192.1603971408655; Thu, 29 Oct 2020 04:36:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603971408; cv=none; d=google.com; s=arc-20160816; b=l8y888qrSfFAbHKY7Dnar6DGqMhK+yuBrtQUrGqEu+ESlRZQQJaGEI9eWqlOTw+vCb YkOX6MrvoMXaeIE7yetu8N3aSR1q1fY3vmzNF7mrJPBnS8e72bbMi2XRspk5y/xaJqDs QY48HioUkwB5He3wxhUSHRKkJwZmk3XJz3RhxmLxaPne0PnUcNhoGJ6fHzLXByt9358Q KyXLgqV9fWO/gvQ7Cs6RyaYmBdWGCnUVMwmFo6UHyI5YZVrNDht2za+AJikDvecrnFKY ECGRlbOpyOO8Gf5cmmy1ljnySAVsPntxtfZlHaBSTCTll827UBkty+fJzvNUWE2TIePD Hesw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=4+1Op2RV/23UrA0vNOm4u+eLDwQyANlhkaHLvGe8m90=; b=VfRPLc/E8hITwX98c1G3BrSowe4PEBQTqheATqTUpOEdE5JKbOnBvF8S64jJnwxLnW Lr+DxD1tqwYFOIPasM/rUyAHsr7T4n2zG2R4bruFX3rwwDsjeKgcYNXfTTX0ymcVwTv5 3vj2CQW2yWH4JGAJ6uoo7F7jD+afiYPNLAdMFWLJAkbHqlur3I0jvnn6K15x5Pvgl4H9 qe1bzQqiArUKDjqSrBDpk0hQwtNjexdKQs1GjnLhPzXBye7eEkbX8NJS/aN2ggREFX4n hnErLfdRw7WiaOXYBK4qjKdD2bZbxOnLGlG7kvDWJk2YdiecYvjbiAh9RX7azRfnoKQm 9urA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@st.com header.s=STMicroelectronics header.b=H3H1DRys; 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=st.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r26si1834135edi.587.2020.10.29.04.36.25; Thu, 29 Oct 2020 04:36:48 -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=@st.com header.s=STMicroelectronics header.b=H3H1DRys; 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=st.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727698AbgJ2Lcl (ORCPT + 99 others); Thu, 29 Oct 2020 07:32:41 -0400 Received: from mx08-00178001.pphosted.com ([91.207.212.93]:44794 "EHLO mx07-00178001.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727677AbgJ2Lcb (ORCPT ); Thu, 29 Oct 2020 07:32:31 -0400 Received: from pps.filterd (m0046661.ppops.net [127.0.0.1]) by mx07-00178001.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 09TBR0AU012814; Thu, 29 Oct 2020 12:32:11 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=st.com; h=subject : to : cc : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=STMicroelectronics; bh=4+1Op2RV/23UrA0vNOm4u+eLDwQyANlhkaHLvGe8m90=; b=H3H1DRysG8v90GAtNTaGhNmqWClcg/HhSZpCi2ghtH2m+RX2aQXCkTmx1lBc0C67oF+f YkGc4Z0cT7Pw4+nvd4TxXsyrWJmNrm3IXGjcpUKsf/gQ4fBG1NoqMscPzK2Vh6hAdylz iBsE04GNKWIJhvJiIClt1opt143h2Frci7Du2DYw9L0ABFvhNG/jINYmiKcldSaTmpDU iGzeVSCW+qh+DjjcZRRrWiahDOd2hpCKdCA2e+/7XsgeZODTH90p+AKyzKWmILYAtCsR swMQThecQBhhU5y2LXbhlUKmDOPfQR92xKFhB/paBvkEDayrxyzZA0Bb5ibfJr6LLYan Zw== Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com with ESMTP id 34ccffrq0y-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 29 Oct 2020 12:32:11 +0100 Received: from euls16034.sgp.st.com (euls16034.sgp.st.com [10.75.44.20]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 39C7C100038; Thu, 29 Oct 2020 12:32:10 +0100 (CET) Received: from Webmail-eu.st.com (sfhdag1node3.st.com [10.75.127.3]) by euls16034.sgp.st.com (STMicroelectronics) with ESMTP id 052082823BD; Thu, 29 Oct 2020 12:32:10 +0100 (CET) Received: from [10.48.1.149] (10.75.127.44) by SFHDAG1NODE3.st.com (10.75.127.3) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Thu, 29 Oct 2020 12:31:19 +0100 Subject: Re: [PATCH 10/15] iio: adc: stm32: remove unnecessary CONFIG_PM_SLEEP To: Coiby Xu CC: Lars-Peter Clausen , Peter Meerwald-Stadler , "open list:IIO SUBSYSTEM AND DRIVERS" , open list , "moderated list:ARM/STM32 ARCHITECTURE" , Maxime Coquelin , "moderated list:ARM/STM32 ARCHITECTURE" , Jonathan Cameron , Alexandre Torgue References: <20201029074910.227859-1-coiby.xu@gmail.com> <20201029074910.227859-10-coiby.xu@gmail.com> From: Fabrice Gasnier Message-ID: <0d58cf8c-997c-959f-f952-999b0d3acdb1@st.com> Date: Thu, 29 Oct 2020 12:31:19 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <20201029074910.227859-10-coiby.xu@gmail.com> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.75.127.44] X-ClientProxiedBy: SFHDAG7NODE3.st.com (10.75.127.21) To SFHDAG1NODE3.st.com (10.75.127.3) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.312,18.0.737 definitions=2020-10-29_06:2020-10-29,2020-10-29 signatures=0 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/29/20 8:49 AM, Coiby Xu wrote: > SET_SYSTEM_SLEEP_PM_OPS has already took good care of CONFIG_PM_CONFIG. > > Signed-off-by: Coiby Xu > --- > drivers/iio/adc/stm32-adc.c | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/drivers/iio/adc/stm32-adc.c b/drivers/iio/adc/stm32-adc.c > index b3f31f147347..42f9013730f8 100644 > --- a/drivers/iio/adc/stm32-adc.c > +++ b/drivers/iio/adc/stm32-adc.c > @@ -1988,7 +1988,6 @@ static int stm32_adc_remove(struct platform_device *pdev) > return 0; > } > > -#if defined(CONFIG_PM_SLEEP) Hi Coiby, This generates warnings when building with W=1 and CONFIG_PM_SLEEP=n. Could you please add also "__maybe_unused" attribute in suspend / resume routines below. > static int stm32_adc_suspend(struct device *dev) ^ e.g. like: static int __maybe_unused stm32_adc_... > { > struct iio_dev *indio_dev = dev_get_drvdata(dev); > @@ -2018,7 +2017,6 @@ static int stm32_adc_resume(struct device *dev) > > return stm32_adc_buffer_postenable(indio_dev); > } > -#endif > > #if defined(CONFIG_PM) Same could be done also for runtime PM routines. For my own curiosity, do you plan to do this as well ? Best regards, Fabrice > static int stm32_adc_runtime_suspend(struct device *dev) >