From patchwork Thu Nov 20 05:39:26 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kachhap X-Patchwork-Id: 5345811 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id BFDA7C11AC for ; Thu, 20 Nov 2014 05:48:07 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E1AA92020E for ; Thu, 20 Nov 2014 05:48:06 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id EBC4720115 for ; Thu, 20 Nov 2014 05:48:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754910AbaKTFsE (ORCPT ); Thu, 20 Nov 2014 00:48:04 -0500 Received: from mailout4.samsung.com ([203.254.224.34]:53587 "EHLO mailout4.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754735AbaKTFsD (ORCPT ); Thu, 20 Nov 2014 00:48:03 -0500 Received: from epcpsbgr4.samsung.com (u144.gpu120.samsung.co.kr [203.254.230.144]) by mailout4.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0NFB00EISPFOKY40@mailout4.samsung.com>; Thu, 20 Nov 2014 14:47:48 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [172.20.52.125]) by epcpsbgr4.samsung.com (EPCPMTA) with SMTP id 1C.78.18167.3808D645; Thu, 20 Nov 2014 14:47:48 +0900 (KST) X-AuditID: cbfee690-f79ab6d0000046f7-b6-546d8083bd98 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id E7.26.09430.3808D645; Thu, 20 Nov 2014 14:47:47 +0900 (KST) Received: from chromebld-server.sisodomain.com ([107.108.73.106]) by mmp1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0NFB001WHPBWO9C0@mmp1.samsung.com>; Thu, 20 Nov 2014 14:47:47 +0900 (KST) From: Amit Daniel Kachhap To: linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org Cc: kgene.kim@samsung.com, linux-kernel@vger.kernel.org, pankaj.dubey@samsung.com, Amit Daniel Kachhap Subject: [PATCH v3 3/5] driver: soc: exynos-pmu: Add an API to be called after wakeup Date: Thu, 20 Nov 2014 11:09:26 +0530 Message-id: <1416461968-2057-4-git-send-email-amit.daniel@samsung.com> X-Mailer: git-send-email 1.7.9.5 In-reply-to: <1416461968-2057-1-git-send-email-amit.daniel@samsung.com> References: <1416461968-2057-1-git-send-email-amit.daniel@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrJLMWRmVeSWpSXmKPExsWyRsSkVrelITfEYPd0NouGqyEWvQuuslls enyN1eLyrjlsFjPO72OyWLT1C7sDm8fmJfUefVtWMXp83iQXwBzFZZOSmpNZllqkb5fAlTH9 yB7WgpW8FTe7H7A1MK7g7mLk5JAQMJF4tWkDO4QtJnHh3nq2LkYuDiGBpYwS09puMsEUTX9w jQXEFhJYxCgxeysLRNEEJonORUfAutkEjCV+7twPZHNwiAh4Syy/pghSwyzQxChxbt5lVpAa YYFwiV9du8HqWQRUJb7//Aa2gFfATeL777ssIL0SAgoScybZgIQ5Bdwlnn/awwix103i1IrF TCAzJQSa2SU+3LzIBjFHQOLb5ENQvbISmw4wQ9wsKXFwxQ2WCYzCCxgZVjGKphYkFxQnpReZ 6BUn5haX5qXrJefnbmIEhvDpf88m7GC8d8D6EKMAB6MSD2+CRW6IEGtiWXFl7iFGU6ANE5ml RJPzgZGSVxJvaGxmZGFqYmpsZG5ppiTO+1rqZ7CQQHp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9RpgIAAA== DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_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 adds an API exynos_sys_powerup_conf to be called after system sleep wakeup. This will useful for exynos7 SoC to perform resume related initialisations. This is similar to currently existing API exynos_sys_powerdown_conf. Reviewed-by: Pankaj Dubey Signed-off-by: Amit Daniel Kachhap --- drivers/soc/samsung/exynos-pmu.c | 9 +++++++++ include/linux/soc/samsung/exynos-pmu.h | 1 + 2 files changed, 10 insertions(+) diff --git a/drivers/soc/samsung/exynos-pmu.c b/drivers/soc/samsung/exynos-pmu.c index aa43e04..f8896bc 100644 --- a/drivers/soc/samsung/exynos-pmu.c +++ b/drivers/soc/samsung/exynos-pmu.c @@ -29,6 +29,7 @@ struct exynos_pmu_data { void (*pmu_init)(void); void (*powerdown_conf)(enum sys_powerdown); + void (*powerup_conf)(enum sys_powerdown); }; struct exynos_pmu_context { @@ -637,6 +638,14 @@ void exynos_sys_powerdown_conf(enum sys_powerdown mode) } } +void exynos_sys_powerup_conf(enum sys_powerdown mode) +{ + const struct exynos_pmu_data *pmu_data = pmu_context->pmu_data; + + if (pmu_data->powerup_conf) + pmu_data->powerup_conf(mode); +} + static void exynos5250_pmu_init(void) { unsigned int value; diff --git a/include/linux/soc/samsung/exynos-pmu.h b/include/linux/soc/samsung/exynos-pmu.h index a2ab0d5..b497712 100644 --- a/include/linux/soc/samsung/exynos-pmu.h +++ b/include/linux/soc/samsung/exynos-pmu.h @@ -20,5 +20,6 @@ enum sys_powerdown { }; extern void exynos_sys_powerdown_conf(enum sys_powerdown mode); +extern void exynos_sys_powerup_conf(enum sys_powerdown mode); #endif /* __EXYNOS_PMU_H */