From patchwork Mon Nov 3 03:53:00 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amit Kachhap X-Patchwork-Id: 5213741 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id B27A19F380 for ; Mon, 3 Nov 2014 04:03:17 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B78AD201E4 for ; Mon, 3 Nov 2014 04:03:16 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id AF65A201BB for ; Mon, 3 Nov 2014 04:03:15 +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 1Xl8pG-000756-Fl; Mon, 03 Nov 2014 04:01:06 +0000 Received: from mailout4.samsung.com ([203.254.224.34]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Xl8pD-0006xc-OU for linux-arm-kernel@lists.infradead.org; Mon, 03 Nov 2014 04:01:04 +0000 Received: from epcpsbgr5.samsung.com (u145.gpu120.samsung.co.kr [203.254.230.145]) by mailout4.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0NEG00LRJ3569720@mailout4.samsung.com> for linux-arm-kernel@lists.infradead.org; Mon, 03 Nov 2014 13:00:42 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [172.20.52.126]) by epcpsbgr5.samsung.com (EPCPMTA) with SMTP id E0.5B.19034.AEDF6545; Mon, 03 Nov 2014 13:00:42 +0900 (KST) X-AuditID: cbfee691-f79b86d000004a5a-0f-5456fdea005a Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id B0.49.09430.AEDF6545; Mon, 03 Nov 2014 13:00:42 +0900 (KST) Received: from chromebld-server.sisodomain.com ([107.108.73.106]) by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0NEG00BUJ320LR40@mmp2.samsung.com>; Mon, 03 Nov 2014 13:00:42 +0900 (KST) From: Amit Daniel Kachhap To: linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-pm@vger.kernel.org Subject: [PATCH 02/12] drivers: mfd: Add support for Exynos PMU driver Date: Mon, 03 Nov 2014 09:23:00 +0530 Message-id: <1414986790-11940-3-git-send-email-amit.daniel@samsung.com> X-Mailer: git-send-email 1.7.9.5 In-reply-to: <1414986790-11940-1-git-send-email-amit.daniel@samsung.com> References: <1414986790-11940-1-git-send-email-amit.daniel@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrELMWRmVeSWpSXmKPExsWyRsSkTvfV37AQg/X7ZCwaroZY9C64ymZx /+tRRotNj6+xWnzuPcJoMeP8PiaLRVu/sFuc7ma1uLjiC5MDp8eda3vYPOadDPTYvKTeo2/L KkaPz5vkAlijuGxSUnMyy1KL9O0SuDKam06xFxyUrvj4oY+9gfGSWBcjJ4eEgInEvx93WSFs MYkL99azdTFycQgJLGWUWDvpEStM0YqNM1kgEtMZJb6c/AblTGCSmHq5nx2kik3AWOLnzv1g tohAusSaRbvBRjELXGKUeLnoBAtIQljATaLz4H8wm0VAVaLh+jomEJtXwF3iz5rvQDYH0DoF iTmTbEDCnAIeEif7roNdIQRUMundcyaQmRICy9gl3p35yAoxR0Di2+RDLBC9shKbDjBDXC0p cXDFDZYJjMILGBlWMYqmFiQXFCelF5nqFSfmFpfmpesl5+duYgQG/el/zybuYLx/wP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+RgJnvh0Wz1mgTrBUeXXxJvVYy/oyZrP3tzxoy1F9v/+7+5lrNi RdE1rg7xt8eOyR28Ev5YmJ9r++wNvTs5n0vxLFn/NyJq8cz+wPt3dimxFGckGmoxFxUnAgAi MRVdvwIAAA== 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-20141102_200103_955813_D39B5FF8 X-CRM114-Status: UNSURE ( 9.32 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -5.6 (-----) Cc: kgene.kim@samsung.com, Samuel Ortiz , Sangbeom Kim , pankaj.dubey@samsung.com, Amit Daniel Kachhap , Lee Jones X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , 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=-2.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, 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 From: Pankaj Dubey This patch moves Exynos PMU driver implementation from "arm/mach-exynos" to "drivers/mfd". This driver is mainly used for setting misc bits of register from PMU IP of Exynos SoC which will be required to configure before Suspend/Resume. Currently all these settings are done in "arch/arm/mach-exynos/pmu.c" but moving ahead for ARM64 based SoC support, there is a need of DT based implementation of PMU driver. This driver uses already existing DT binding information. CC: Sangbeom Kim CC: Samuel Ortiz CC: Lee Jones Signed-off-by: Pankaj Dubey Signed-off-by: Amit Daniel Kachhap --- arch/arm/mach-exynos/Kconfig | 1 + arch/arm/mach-exynos/Makefile | 2 +- drivers/mfd/Kconfig | 9 +++++++++ drivers/mfd/Makefile | 1 + .../mach-exynos/pmu.c => drivers/mfd/exynos-pmu.c | 0 5 files changed, 12 insertions(+), 1 deletion(-) rename arch/arm/mach-exynos/pmu.c => drivers/mfd/exynos-pmu.c (100%) diff --git a/arch/arm/mach-exynos/pmu.c b/drivers/mfd/exynos-pmu.c similarity index 100% rename from arch/arm/mach-exynos/pmu.c rename to drivers/mfd/exynos-pmu.c diff --git a/arch/arm/mach-exynos/Kconfig b/arch/arm/mach-exynos/Kconfig index 96d56ab..c2aef3f 100644 --- a/arch/arm/mach-exynos/Kconfig +++ b/arch/arm/mach-exynos/Kconfig @@ -25,6 +25,7 @@ menuconfig ARCH_EXYNOS select S5P_DEV_MFC select SRAM select MFD_SYSCON + select MFD_EXYNOS_PMU help Support for SAMSUNG EXYNOS SoCs (EXYNOS4/5) diff --git a/arch/arm/mach-exynos/Makefile b/arch/arm/mach-exynos/Makefile index bcefb54..b91b382 100644 --- a/arch/arm/mach-exynos/Makefile +++ b/arch/arm/mach-exynos/Makefile @@ -9,7 +9,7 @@ ccflags-$(CONFIG_ARCH_MULTIPLATFORM) += -I$(srctree)/$(src)/include -I$(srctree) # Core -obj-$(CONFIG_ARCH_EXYNOS) += exynos.o pmu.o exynos-smc.o firmware.o +obj-$(CONFIG_ARCH_EXYNOS) += exynos.o exynos-smc.o firmware.o obj-$(CONFIG_EXYNOS_CPU_SUSPEND) += pm.o sleep.o obj-$(CONFIG_PM_SLEEP) += suspend.o diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig index cbdb109..619a9ba 100644 --- a/drivers/mfd/Kconfig +++ b/drivers/mfd/Kconfig @@ -1323,6 +1323,15 @@ config MFD_STW481X in various ST Microelectronics and ST-Ericsson embedded Nomadik series. +config MFD_EXYNOS_PMU + tristate "Support Exynos Power Management Unit" + depends on ARM || ARM64 + help + Exynos SoC have Power Management Unit (PMU) which controls power and + operation state of Exynos SoC in two different ways. This driver + provides implementation of PMU driver and provides basic functionality + required during these operation state. + menu "Multimedia Capabilities Port drivers" depends on ARCH_SA1100 diff --git a/drivers/mfd/Makefile b/drivers/mfd/Makefile index 8e679d6..33489b4 100644 --- a/drivers/mfd/Makefile +++ b/drivers/mfd/Makefile @@ -175,6 +175,7 @@ obj-$(CONFIG_MFD_STW481X) += stw481x.o obj-$(CONFIG_MFD_IPAQ_MICRO) += ipaq-micro.o obj-$(CONFIG_MFD_MENF21BMC) += menf21bmc.o obj-$(CONFIG_MFD_HI6421_PMIC) += hi6421-pmic-core.o +obj-$(CONFIG_MFD_EXYNOS_PMU) += exynos-pmu.o intel-soc-pmic-objs := intel_soc_pmic_core.o intel_soc_pmic_crc.o obj-$(CONFIG_INTEL_SOC_PMIC) += intel-soc-pmic.o