From patchwork Tue Nov 17 06:05:50 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pankaj Dubey X-Patchwork-Id: 7633421 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id CB246BF90C for ; Tue, 17 Nov 2015 06:19:03 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id ECEAD20525 for ; Tue, 17 Nov 2015 06:19:02 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0D61D2042A for ; Tue, 17 Nov 2015 06:19:02 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZyZZh-0004u4-Qu; Tue, 17 Nov 2015 06:17:05 +0000 Received: from merlin.infradead.org ([2001:4978:20e::2]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZyZXT-0001vg-Aa for linux-arm-kernel@bombadil.infradead.org; Tue, 17 Nov 2015 06:14:47 +0000 Received: from mailout2.samsung.com ([203.254.224.25]) by merlin.infradead.org with esmtps (Exim 4.85 #2 (Red Hat Linux)) id 1ZyZXQ-00060U-Oc for linux-arm-kernel@lists.infradead.org; Tue, 17 Nov 2015 06:14:46 +0000 Received: from epcpsbgr2.samsung.com (u142.gpu120.samsung.co.kr [203.254.230.142]) by mailout2.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0NXY00AMW3ZQRG30@mailout2.samsung.com> for linux-arm-kernel@lists.infradead.org; Tue, 17 Nov 2015 15:14:14 +0900 (KST) Received: from epcpsbgm1new.samsung.com ( [172.20.52.123]) by epcpsbgr2.samsung.com (EPCPMTA) with SMTP id F0.B0.05272.6B5CA465; Tue, 17 Nov 2015 15:14:14 +0900 (KST) X-AuditID: cbfee68e-f791c6d000001498-e3-564ac5b63d2f Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm1new.samsung.com (EPCPMTA) with SMTP id 58.12.23663.5B5CA465; Tue, 17 Nov 2015 15:14:14 +0900 (KST) Received: from chromebld-server.sisodomain.com ([107.108.73.106]) by mmp2.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0NXY00GBB3PUDS00@mmp2.samsung.com>; Tue, 17 Nov 2015 15:14:13 +0900 (KST) From: Pankaj Dubey To: linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-pm@vger.kernel.org Subject: [PATCH v6 8/9] ARM: EXYNOS: rearrange static and non-static functions of PMU driver Date: Tue, 17 Nov 2015 11:35:50 +0530 Message-id: <1447740351-14246-9-git-send-email-pankaj.dubey@samsung.com> X-Mailer: git-send-email 2.4.5 In-reply-to: <1447740351-14246-1-git-send-email-pankaj.dubey@samsung.com> References: <1447740351-14246-1-git-send-email-pankaj.dubey@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrDLMWRmVeSWpSXmKPExsWyRsSkWnfbUa8wg2PbBCw+rn7JZvF30jF2 i9cvDC16F1xls/h6eAWjxabH11gtLu+aw2bxufcIo8WM8/uYLE5d/8xmsWjrF3aLjmWMDjwe v39NYvTYOesuu8eda3vYPDYvqfe4cqKJ1aNvyypGj8+b5ALYo7hsUlJzMstSi/TtErgyvrQf Zi3YzVcx9eYLtgbG/9xdjJwcEgImErsmvmaBsMUkLtxbz9bFyMUhJLCCUWLz1ofMMEW7d7xl h0jMYpS4tWU6M4TTyiTx+kkvK0gVm4CuxJP3c8ESIgKtjBLL9v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dxMjOBqfSe1gPLjL/RCj AAejEg/vjiNeYUKsiWXFlbmHGCU4mJVEeJ8cAgrxpiRWVqUW5ccXleakFh9iNAU6ayKzlGhy PjBR5JXEGxqbmJsam1qaWJiYWSqJ8+p7GoUJCaQnlqRmp6YWpBbB9DFxcEo1MF4UZThd9uxj zO6lM5K+Xgpae8c+4Z3meau1cw10XdbxXD4SUFr37R77nfVn1+rPb/h2dnnxxgzJyG9/RLXV /rIpHDp8lq873/GC8Xm2yQ5nHPyPrcyJb3g4Ky4rwG+ByRxOK8spQi4/2woW67dtsT98Qod5 xcFT3z4H/D61180qiyVC0FIpYq4SS3FGoqEWc1FxIgBLWKHt3AIAAA== DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20151117_011445_082175_DA4BDB50 X-CRM114-Status: GOOD ( 13.00 ) X-Spam-Score: -7.7 (-------) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: amitdanielk@gmail.com, k.kozlowski@samsung.com, kgene.kim@samsung.com, arnd@arndb.de, khilman@linaro.org, Pankaj Dubey , thomas.ab@samsung.com, olof@lixom.net MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.8 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch moves exynos_sys_powerdown_conf function above all static functions, to avoid confusion causing due to mixing of static-nonstatic-static functions and to improve readability of this driver. Signed-off-by: Pankaj Dubey Suggested-by: Krzysztof Kozlowski Reviewed-by: Krzysztof Kozlowski --- arch/arm/mach-exynos/pmu.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/arch/arm/mach-exynos/pmu.c b/arch/arm/mach-exynos/pmu.c index 01cb649..a7741d4 100644 --- a/arch/arm/mach-exynos/pmu.c +++ b/arch/arm/mach-exynos/pmu.c @@ -39,23 +39,6 @@ u32 pmu_raw_readl(u32 offset) return readl_relaxed(pmu_base_addr + offset); } -static void exynos_power_off(void) -{ - unsigned int tmp; - - pr_info("Power down.\n"); - tmp = pmu_raw_readl(EXYNOS_PS_HOLD_CONTROL); - tmp ^= (1 << 8); - pmu_raw_writel(tmp, EXYNOS_PS_HOLD_CONTROL); - - /* Wait a little so we don't give a false warning below */ - mdelay(100); - - pr_err("Power down failed, please power off system manually.\n"); - while (1) - ; -} - void exynos_sys_powerdown_conf(enum sys_powerdown mode) { unsigned int i; @@ -85,6 +68,23 @@ void exynos_sys_powerdown_conf(enum sys_powerdown mode) } } +static void exynos_power_off(void) +{ + unsigned int tmp; + + pr_info("Power down.\n"); + tmp = pmu_raw_readl(EXYNOS_PS_HOLD_CONTROL); + tmp ^= (1 << 8); + pmu_raw_writel(tmp, EXYNOS_PS_HOLD_CONTROL); + + /* Wait a little so we don't give a false warning below */ + mdelay(100); + + pr_err("Power down failed, please power off system manually.\n"); + while (1) + ; +} + static int pmu_restart_notify(struct notifier_block *this, unsigned long code, void *unused) {