From patchwork Fri Nov 13 09:29:42 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pankaj Dubey X-Patchwork-Id: 7609441 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 3CC09BF90C for ; Fri, 13 Nov 2015 09:38:51 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6EACC207F1 for ; Fri, 13 Nov 2015 09:38:50 +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 4D645207E7 for ; Fri, 13 Nov 2015 09:38:49 +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 1ZxAmY-0003LW-0W; Fri, 13 Nov 2015 09:36:34 +0000 Received: from mailout1.samsung.com ([203.254.224.24]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZxAk5-0008C6-6Q for linux-arm-kernel@lists.infradead.org; Fri, 13 Nov 2015 09:34:04 +0000 Received: from epcpsbgr2.samsung.com (u142.gpu120.samsung.co.kr [203.254.230.142]) by mailout1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0NXQ01SOEYJL6X70@mailout1.samsung.com> for linux-arm-kernel@lists.infradead.org; Fri, 13 Nov 2015 18:33:21 +0900 (KST) Received: from epcpsbgm1new.samsung.com ( [172.20.52.123]) by epcpsbgr2.samsung.com (EPCPMTA) with SMTP id C2.39.05272.06EA5465; Fri, 13 Nov 2015 18:33:20 +0900 (KST) X-AuditID: cbfee68e-f791c6d000001498-a0-5645ae609213 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm1new.samsung.com (EPCPMTA) with SMTP id CA.DF.23663.06EA5465; Fri, 13 Nov 2015 18:33:20 +0900 (KST) Received: from chromebld-server.sisodomain.com ([107.108.73.106]) by mmp1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0NXQ002KAYHMWY40@mmp1.samsung.com>; Fri, 13 Nov 2015 18:33:20 +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 v5 8/9] ARM: EXYNOS: rearrange static and non-static functions of PMU driver Date: Fri, 13 Nov 2015 14:59:42 +0530 Message-id: <1447406983-27835-9-git-send-email-pankaj.dubey@samsung.com> X-Mailer: git-send-email 2.4.5 In-reply-to: <1447406983-27835-1-git-send-email-pankaj.dubey@samsung.com> References: <1447406983-27835-1-git-send-email-pankaj.dubey@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrNLMWRmVeSWpSXmKPExsWyRsSkWjdxnWuYQYOgxcfVL9ks/k46xm7x +oWhRe+Cq2wWXw+vYLTY9Pgaq8XlXXPYLD73HmG0mHF+H5PFqeuf2SwWbf3CbtGxjNGBx+P3 r0mMHjtn3WX3uHNtD5vH5iX1HldONLF69G1ZxejxeZNcAHsUl01Kak5mWWqRvl0CV8aXCd2s Bf95K1Y83sPawHiCu4uRk0NCwETiTftsdghbTOLCvfVsXYxcHEICKxglli94wQpTdH1mEztE YimjxKtLtxlBEkICrUwSS+4lgthsAroST97PZQYpEhFoZZRYtv8/E4jDLHCAUWLHuldgHcIC cRJ3vrWBjWURUJVY1buLBcTmFfCQmLZnKpDNAbROTmJpcy1ImFPAU+L51IXMEMs8JI4vPMsI MlNC4BK7RGPLEqg5AhLfJh+C6pWV2HSAGeJqSYmDK26wTG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T2NwoQE0hNLUrNTUwtSi2D6mDg4pRoYJc1slRKc j5TbNxb4fuH0DrrOpPzeXPQCI28Zy3rR2fUP5ol0PpU1+dTO55F5tbEtWK/eeMUZhqC8dzyq 9kvOn7Z8Icl84dxOW+36b+/38h+5udC1XkPa+9NWrbAtvR/+sWZvK7z3pbyj4Khsn4jX5GPr 3K+/K4zyMMzTVll7r0/oE9tPoY1KLMUZiYZazEXFiQD/2VuL3AIAAA== 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-20151113_013401_693770_B6E23F9A X-CRM114-Status: GOOD ( 11.35 ) X-Spam-Score: -7.3 (-------) 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.5 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) {