From patchwork Tue Jun 27 15:02:46 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 106442 Delivered-To: patch@linaro.org Received: by 10.182.135.102 with SMTP id pr6csp2504331obb; Tue, 27 Jun 2017 08:06:13 -0700 (PDT) X-Received: by 10.84.176.131 with SMTP id v3mr6448928plb.138.1498575973158; Tue, 27 Jun 2017 08:06:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1498575973; cv=none; d=google.com; s=arc-20160816; b=UJ69KOJLggNWTUsvm5NvhqEFK2wfZ4U2GcaO5NL7ilwwMfBzYbdBIyl8yPnLnsz7yi n5d/rCO5OLybP29axKFyHsVFGN4YSnM1nWJn0ohzXtYGQiHjaNx3Ca92f/EAomHGwlPQ VtyrSEeGuPURNQ8hRo5liANLpQAdH8e5cPZ+pVLMSk+aWHtauYaaYTnKKOxdjFbChxN1 sXdbxQI9hhIhMF3iydsRKWO0XjwNyX7cNgcWM6BbK3OatrM4bL3GxRV24WQecfAO/Jti QyYWHD219Z5UlMuNIYLG2uwTxyjRN4+potSQbeVetSzZTDE79exKam+nuCDzXqT0O7PC oluQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=uNQOGCuzClNKIh05fUrZ3WvfITuDCOpgP2PhdOhNnvY=; b=Keb6u0Uxje/jWNZz9Ame3kMqoS1TnxXmcpze7Gznjxe67OHY2kYvJCh+O+yQ3D3gBh AasduCw3zWMfuMkx1ePK4ocYV0a9pYF6IzEN5EWCUT12Zz+ErpouKxeMcaPnsjlTqxsn Mdah79X5hlyzRCkWfrFlkfvpCHfrIP8y20/ExC6+ahbzzoheN3YZZupf1xBl21E9cCgL 1FxstO3ukSpQBdMxblelJ0mT3EFvdgnIs9rM8uDkYkOAdbq7cqDaiv0P7ZD6i1Toric9 /0U+pjHKt9+hQs6QtxznfLorgEcvsdDJAqP7So7PIhe4zDohMXexK8Rs3vPTP+uv098J wzxA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-media-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d193si2052803pgc.115.2017.06.27.08.06.13; Tue, 27 Jun 2017 08:06:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-media-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-media-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751739AbdF0PGB (ORCPT + 4 others); Tue, 27 Jun 2017 11:06:01 -0400 Received: from mout.kundenserver.de ([212.227.126.130]:54342 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753276AbdF0PDZ (ORCPT ); Tue, 27 Jun 2017 11:03:25 -0400 Received: from wuerfel.lan ([5.56.224.194]) by mrelayeu.kundenserver.de (mreue003 [212.227.15.129]) with ESMTPA (Nemesis) id 0LhRPo-1e3YLv2yqu-00mZRe; Tue, 27 Jun 2017 17:03:11 +0200 From: Arnd Bergmann To: Stanimir Varbanov , Mauro Carvalho Chehab Cc: Arnd Bergmann , Hans Verkuil , Colin Ian King , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/3] [media] venus: mark PM functions as __maybe_unused Date: Tue, 27 Jun 2017 17:02:46 +0200 Message-Id: <20170627150310.719212-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:uMCzuWIdWFETDZJPj4nXlKxSOFJtoAOvznUt0aTJ98uGMmf6h0D wqng5/t3pfjGbbmMEDA9x85i8qoky0MgHby++ojWl1KaNiIe6xaOJMpIOl5BlCv8uXw1cS8 uAtqOfVxv/ZzgnfKGuKzwd8PbSFv/223X7YWizrpnyaM7CNY1p7IO6tKQ6hDcGtvx3kLJa3 foX8k0yZ5f9f6fjCLPmrQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:WqjRk+o1jWY=:JC8WlAIQXgyx21F3eHj/yt 1Uy5aKHfCe6dQx531H3f38aGA0MavLb54UvaArJhQnfVwpbTm4nJbSyJrjOH8CG9qej3spFCL Gn5yzwqtnrezfRxWEZECRhNidSl0/rzBqfh4fTv2qcYy83vadDV4VqVDQzShF4dRo5czI+9HM wiVMbWxy2OlsmYGdGFlX5fUG8QBXnVyC9XbCYbq7TKZq5NN8Fx1a4+TkhQQuWqdgsIcXdhwds 3aJmWLp++oUKSSJMOMD+U1hPT6G3B58G9bdRPY0//wfviWEWzvhhPO9KfXQMUVf2VAKLMkU92 V7HOy3GrWzWNAc7Y0jo3VAU+fCRyuhG/Dc2yOes55Z7nACe51XzLPKUUQ/tT2PttWatEw3Nxf PuSDIz5QfEc/RPJX7WkJnt6l21MdJbu2glU//RBhBf0DgEPrfk4yWY/eN/UwvJgXsVkXstIGU zNQdBbaSwkGe2MUwhwU9t/5UsMi1ip6EWFBhZbeRTqGDjl3HMZM27SibRNRtVt7hvgDmJwnJN RDltSAlO9erJTV2NskpIkmT//9581vObQ5oIg6xH0K8osWwoaZs1zAp/o6oCL6Ih+j3GrRp09 d99dmrL2+KwuO3F9BRzkuNr4HJSt5JvVdF/+BeFBvVu1x5lHpCo3KoLZXMs7dB6gp/tq04NcP B3ZRs/buIEOWiAJv+EY/qElEelvKWMsfTE/fJB96IXiKx7kE/vDVa4NelFBvcK3EOPLo= Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Without PM support, gcc warns about two unused functions: platform/qcom/venus/core.c:146:13: error: 'venus_clks_disable' defined but not used [-Werror=unused-function] platform/qcom/venus/core.c:126:12: error: 'venus_clks_enable' defined but not used [-Werror=unused-function] The problem as usual are incorrect #ifdefs, so the easiest fix is to do away with the #ifdef completely and mark the suspend/resume handlers as __maybe_unused, which they are. Fixes: af2c3834c8ca ("[media] media: venus: adding core part and helper functions") Signed-off-by: Arnd Bergmann --- drivers/media/platform/qcom/venus/core.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) -- 2.9.0 Reviewed-by: Stanimir Varbanov Signed-off-by: Arnd Bergmann diff --git a/drivers/media/platform/qcom/venus/core.c b/drivers/media/platform/qcom/venus/core.c index d8cbe8549d97..47f79637938c 100644 --- a/drivers/media/platform/qcom/venus/core.c +++ b/drivers/media/platform/qcom/venus/core.c @@ -270,8 +270,7 @@ static int venus_remove(struct platform_device *pdev) return ret; } -#ifdef CONFIG_PM -static int venus_runtime_suspend(struct device *dev) +static __maybe_unused int venus_runtime_suspend(struct device *dev) { struct venus_core *core = dev_get_drvdata(dev); int ret; @@ -283,7 +282,7 @@ static int venus_runtime_suspend(struct device *dev) return ret; } -static int venus_runtime_resume(struct device *dev) +static __maybe_unused int venus_runtime_resume(struct device *dev) { struct venus_core *core = dev_get_drvdata(dev); int ret; @@ -302,7 +301,6 @@ static int venus_runtime_resume(struct device *dev) venus_clks_disable(core); return ret; } -#endif static const struct dev_pm_ops venus_pm_ops = { SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend,