From patchwork Tue Nov 17 06:05:51 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pankaj Dubey X-Patchwork-Id: 7633351 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.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 9CE14BF90C for ; Tue, 17 Nov 2015 06:14:55 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id AB16A20525 for ; Tue, 17 Nov 2015 06:14:54 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8364C20527 for ; Tue, 17 Nov 2015 06:14:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752513AbbKQGOw (ORCPT ); Tue, 17 Nov 2015 01:14:52 -0500 Received: from mailout4.samsung.com ([203.254.224.34]:38892 "EHLO mailout4.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751465AbbKQGOv (ORCPT ); Tue, 17 Nov 2015 01:14:51 -0500 Received: from epcpsbgr1.samsung.com (u141.gpu120.samsung.co.kr [203.254.230.141]) by mailout4.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0NXY02PM140P6830@mailout4.samsung.com>; Tue, 17 Nov 2015 15:14:49 +0900 (KST) Received: from epcpsbgm1new.samsung.com ( [172.20.52.122]) by epcpsbgr1.samsung.com (EPCPMTA) with SMTP id F4.92.05274.9D5CA465; Tue, 17 Nov 2015 15:14:49 +0900 (KST) X-AuditID: cbfee68d-f79ae6d00000149a-d5-564ac5d97154 Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm1new.samsung.com (EPCPMTA) with SMTP id 27.22.23663.9D5CA465; Tue, 17 Nov 2015 15:14:49 +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:49 +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 Cc: kgene.kim@samsung.com, k.kozlowski@samsung.com, thomas.ab@samsung.com, amitdanielk@gmail.com, olof@lixom.net, khilman@linaro.org, arnd@arndb.de, Pankaj Dubey Subject: [PATCH v6 9/9] drivers: soc: Add support for Exynos PMU driver Date: Tue, 17 Nov 2015 11:35:51 +0530 Message-id: <1447740351-14246-10-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+NgFvrFLMWRmVeSWpSXmKPExsWyRsSkSvfmUa8wgyPHlC0+rn7JZvF30jF2 i9cvDC16F1xls/h6eAWjxabH11gtLu+aw2bxufcIo8WM8/uYLE5d/8xmsWjrF3aLjmWMDjwe v39NYvTYOesuu8eda3vYPDYvqfe4cqKJ1aNvyypGj8+b5ALYo7hsUlJzMstSi/TtErgylt34 yVxwW7Xi3fR/7A2M/QpdjJwcEgImEjMnfGCFsMUkLtxbz9bFyMUhJLCCUWLj4YnsMEVvl55i hUjMYpQ42nGOGcJpZZI49P4hM0gVm4CuxJP3c8ESIgKtjBLL9v9nAnGYBQ4wSuxY94oRpEpY wF3i2q0lYDaLgKrErtfTgXZwcPAKeErs218DYkoIyEksba4FqeAEiu5YeoQJJCwk4CHx7oQ6 xEGX2CVu3CyHGCIg8W3yIRaITlmJTQeYIUokJQ6uuMEygVF4ASPDKkbR1ILkguKk9CJDve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ijXl5/k6JY +/9FkqyN3edFV3UEubc1zjg6zUtl4QSeb3tnXQ079y5+tbJuQcl0nz233u/OC9qjscgq///e iQfbNNZt/f3lnIu4eB1nuhhXY96sR43fVm2KfVYT1pH3MHrq88dyR5w+GG88cTqeR+Lb+Uem VyR3aa3wuX257amxH8uullKO1Oc9SizFGYmGWsxFxYkArxk7GNsCAAA= 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=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, 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 PMU driver implementation from "arm/mach-exynos" to "drivers/soc/samsung". 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 this PMU driver in driver/* folder. This driver uses existing DT binding information and there should be no functionality change in the supported platforms. Signed-off-by: Amit Daniel Kachhap Signed-off-by: Pankaj Dubey Reviewed-by: Krzysztof Kozlowski --- arch/arm/mach-exynos/Kconfig | 1 + arch/arm/mach-exynos/Makefile | 4 +--- drivers/soc/samsung/Kconfig | 4 ++++ drivers/soc/samsung/Makefile | 2 ++ arch/arm/mach-exynos/pmu.c => drivers/soc/samsung/exynos-pmu.c | 0 {arch/arm/mach-exynos => drivers/soc/samsung}/exynos-pmu.h | 0 {arch/arm/mach-exynos => drivers/soc/samsung}/exynos3250-pmu.c | 0 {arch/arm/mach-exynos => drivers/soc/samsung}/exynos4-pmu.c | 0 {arch/arm/mach-exynos => drivers/soc/samsung}/exynos5250-pmu.c | 0 {arch/arm/mach-exynos => drivers/soc/samsung}/exynos5420-pmu.c | 0 10 files changed, 8 insertions(+), 3 deletions(-) rename arch/arm/mach-exynos/pmu.c => drivers/soc/samsung/exynos-pmu.c (100%) rename {arch/arm/mach-exynos => drivers/soc/samsung}/exynos-pmu.h (100%) rename {arch/arm/mach-exynos => drivers/soc/samsung}/exynos3250-pmu.c (100%) rename {arch/arm/mach-exynos => drivers/soc/samsung}/exynos4-pmu.c (100%) rename {arch/arm/mach-exynos => drivers/soc/samsung}/exynos5250-pmu.c (100%) rename {arch/arm/mach-exynos => drivers/soc/samsung}/exynos5420-pmu.c (100%) diff --git a/arch/arm/mach-exynos/pmu.c b/drivers/soc/samsung/exynos-pmu.c similarity index 100% rename from arch/arm/mach-exynos/pmu.c rename to drivers/soc/samsung/exynos-pmu.c diff --git a/arch/arm/mach-exynos/exynos-pmu.h b/drivers/soc/samsung/exynos-pmu.h similarity index 100% rename from arch/arm/mach-exynos/exynos-pmu.h rename to drivers/soc/samsung/exynos-pmu.h diff --git a/arch/arm/mach-exynos/exynos3250-pmu.c b/drivers/soc/samsung/exynos3250-pmu.c similarity index 100% rename from arch/arm/mach-exynos/exynos3250-pmu.c rename to drivers/soc/samsung/exynos3250-pmu.c diff --git a/arch/arm/mach-exynos/exynos4-pmu.c b/drivers/soc/samsung/exynos4-pmu.c similarity index 100% rename from arch/arm/mach-exynos/exynos4-pmu.c rename to drivers/soc/samsung/exynos4-pmu.c diff --git a/arch/arm/mach-exynos/exynos5250-pmu.c b/drivers/soc/samsung/exynos5250-pmu.c similarity index 100% rename from arch/arm/mach-exynos/exynos5250-pmu.c rename to drivers/soc/samsung/exynos5250-pmu.c diff --git a/arch/arm/mach-exynos/exynos5420-pmu.c b/drivers/soc/samsung/exynos5420-pmu.c similarity index 100% rename from arch/arm/mach-exynos/exynos5420-pmu.c rename to drivers/soc/samsung/exynos5420-pmu.c diff --git a/arch/arm/mach-exynos/Kconfig b/arch/arm/mach-exynos/Kconfig index 83c85f5..874cb38 100644 --- a/arch/arm/mach-exynos/Kconfig +++ b/arch/arm/mach-exynos/Kconfig @@ -16,6 +16,7 @@ menuconfig ARCH_EXYNOS select ARM_GIC select COMMON_CLK_SAMSUNG select EXYNOS_THERMAL + select EXYNOS_PMU select EXYNOS_SROM if PM select HAVE_ARM_SCU if SMP select HAVE_S3C2410_I2C if I2C diff --git a/arch/arm/mach-exynos/Makefile b/arch/arm/mach-exynos/Makefile index 2d58063..34d29df 100644 --- a/arch/arm/mach-exynos/Makefile +++ b/arch/arm/mach-exynos/Makefile @@ -9,9 +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 \ - exynos3250-pmu.o exynos4-pmu.o \ - exynos5250-pmu.o exynos5420-pmu.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/soc/samsung/Kconfig b/drivers/soc/samsung/Kconfig index 2833b5b..5855469 100644 --- a/drivers/soc/samsung/Kconfig +++ b/drivers/soc/samsung/Kconfig @@ -10,4 +10,8 @@ config EXYNOS_SROM bool depends on ARM && ARCH_EXYNOS && PM +config EXYNOS_PMU + bool + depends on ARM && ARCH_EXYNOS + endmenu diff --git a/drivers/soc/samsung/Makefile b/drivers/soc/samsung/Makefile index 9c554d5..cef7970 100644 --- a/drivers/soc/samsung/Makefile +++ b/drivers/soc/samsung/Makefile @@ -1 +1,3 @@ obj-$(CONFIG_EXYNOS_SROM) += exynos-srom.o +obj-$(CONFIG_EXYNOS_PMU) += exynos-pmu.o exynos3250-pmu.o exynos4-pmu.o \ + exynos5250-pmu.o exynos5420-pmu.o