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=-9.6 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 0EFE2C00A89 for ; Fri, 30 Oct 2020 14:54:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 9A5872076E for ; Fri, 30 Oct 2020 14:54:01 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="G9li2Tvz" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726875AbgJ3OyA (ORCPT ); Fri, 30 Oct 2020 10:54:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38408 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726491AbgJ3OyA (ORCPT ); Fri, 30 Oct 2020 10:54:00 -0400 Received: from mail-pl1-x644.google.com (mail-pl1-x644.google.com [IPv6:2607:f8b0:4864:20::644]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D588FC0613D2 for ; Fri, 30 Oct 2020 07:53:58 -0700 (PDT) Received: by mail-pl1-x644.google.com with SMTP id x23so3073320plr.6 for ; Fri, 30 Oct 2020 07:53:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:date:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=CkQFDq2V3fTRnTqwrpougjs6hrzT2Mg5FLap+tCFeI0=; b=G9li2Tvz7YB3v7bQVSR3T+G91Gn4Q1O/LxAV2YyfxdIcTWerCiyFiIVBFA/l2Kts6+ iO363f1lgr5WtxxvPlDzy9sNMRswErv+Ay3jyuSByl2mPqHG1ByPQ8WdZB0Z5qeMMdDC O0tFO9VVUyKNyK8fAC9/VLINWtqhE76QJFqnZwm+ZuVPN3beg+3jf5mQ9OD0CPkuLtdn b2YVS7FMoX7EYNOtz/W18Z7UNGP+lFFCMHO+bOu78Si3q660H/mjD+wLbY7VO2bFHVYL 39ylpHs/5qWJ5MuAtCuAioXn7p6AXDgYqNWGtv5dAR1PH4OnB5yXz/eSKXJxSIdoOEJ5 2hFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:date:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=CkQFDq2V3fTRnTqwrpougjs6hrzT2Mg5FLap+tCFeI0=; b=ZhdAnGshqDpRzkrEeS/w4ttbahs+y5SbtCogZF3S3dmqovkGeXh+4BwtvBPiq8OOCs YwJQ/tMjIwsT/T2pn0sjKuq0ohEWGiO4ZlPHatPygg8E8MsMXOGoZYa7QoEVLlwstfK9 gIcBbO8BUOzh84SSYfGoNz25JxAex0BERLj+YhrB/uHATuk2m70M07KQWDXWK/6Q/CgY wytL1bUsH+SA6SCLHFYm4RQ9MYBqHcN7011jKcIBZT8wXKBhe+oniWNZeIsY8Z0PvWTR 93viqdlIqtTkKNTuEPntRUZd43ON7artAAyYfqEFpuscyJ4v2ai+BrerSnzLtgUQ0+mZ RvJA== X-Gm-Message-State: AOAM533Pjw9DONahQQTaQ+QqIuTM8jaaqp1b/dUo87yCZsIMsfa39KgA vfhnnBtPU8yXSI7BEVTL7cY= X-Google-Smtp-Source: ABdhPJyvA4VrWnyjoOxNgcBLcrNyRQ8yIc1KHqAj6mmJQxnD7c8Pj7HTBZSnzbcoRfNfc1d2agC2gg== X-Received: by 2002:a17:902:b688:b029:d6:ad52:ffab with SMTP id c8-20020a170902b688b02900d6ad52ffabmr950049pls.61.1604069638420; Fri, 30 Oct 2020 07:53:58 -0700 (PDT) Received: from localhost ([240e:472:3d00:779:b01a:f9a7:6a68:30ac]) by smtp.gmail.com with ESMTPSA id u14sm4039534pjf.53.2020.10.30.07.53.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Oct 2020 07:53:58 -0700 (PDT) From: Coiby Xu X-Google-Original-From: Coiby Xu Date: Fri, 30 Oct 2020 22:53:22 +0800 To: Chunyan Zhang Cc: Lee Jones , Orson Zhai , Baolin Wang , open list Subject: Re: [PATCH 9/9] mfd: sprd-sc27xx-spi: remove unnecessary CONFIG_PM_SLEEP Message-ID: <20201030145322.agt774ib5jgin7du@Rk> References: <20201029100647.233361-1-coiby.xu@gmail.com> <20201029100647.233361-9-coiby.xu@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Chunyan, On Fri, Oct 30, 2020 at 12:02:03PM +0800, Chunyan Zhang wrote: >Hi Coiby, > >After removing CONFIG_PM_SLEEP, sprd_pmic_suspend/resume() would not >be built into symbol table with clang compiler though, that would >cause clang compiler report warnings of "unused function" if >CONFIG_PM_SLEEP is not set. So I also prefer to add a __maybe_unused >instead as other people suggested in the mail list. > Thank you for the suggestion! At least Lee prefers to CONFIG_PM_SLEEP thus to keep the status quo. I'll see he'll change his mind with the ongoing discussion [1]:) [1] https://www.mail-archive.com/linux-kernel@vger.kernel.org/msg2361371.html >Thanks, >Chunyan > > >On Thu, 29 Oct 2020 at 18:07, Coiby Xu wrote: >> >> SIMPLE_DEV_PM_OPS has already took good care of CONFIG_PM_CONFIG. Signed-off-by: Coiby Xu drivers/mfd/sprd-sc27xx-spi.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/mfd/sprd-sc27xx-spi.c b/drivers/mfd/sprd-sc27xx-spi.c index 6b7956604a0f..4db2ec9ef2ff 100644 --- a/drivers/mfd/sprd-sc27xx-spi.c +++ b/drivers/mfd/sprd-sc27xx-spi.c @@ -206,7 +206,6 @@ static int sprd_pmic_probe(struct spi_device *spi) return 0; -#ifdef CONFIG_PM_SLEEP static int sprd_pmic_suspend(struct device *dev) struct sprd_pmic *ddata = dev_get_drvdata(dev); @@ -226,7 +225,6 @@ static int sprd_pmic_resume(struct device *dev) return 0; -#endif static SIMPLE_DEV_PM_OPS(sprd_pmic_pm_ops, sprd_pmic_suspend, sprd_pmic_resume); 2.28.0 -- Best regards, Coiby