From patchwork Fri Feb 22 10:47:08 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Szyprowski X-Patchwork-Id: 10825663 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5DC771390 for ; Fri, 22 Feb 2019 10:47:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4C65831A16 for ; Fri, 22 Feb 2019 10:47:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 408E931A5F; Fri, 22 Feb 2019 10:47:25 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 99C8131A16 for ; Fri, 22 Feb 2019 10:47:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726184AbfBVKrY (ORCPT ); Fri, 22 Feb 2019 05:47:24 -0500 Received: from mailout1.w1.samsung.com ([210.118.77.11]:54478 "EHLO mailout1.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726135AbfBVKrX (ORCPT ); Fri, 22 Feb 2019 05:47:23 -0500 Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout1.w1.samsung.com (KnoxPortal) with ESMTP id 20190222104721euoutp0102e51880dcdac3092f0e5cd7a1f6dee3~FqeOhiAen1488514885euoutp01q; Fri, 22 Feb 2019 10:47:21 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.w1.samsung.com 20190222104721euoutp0102e51880dcdac3092f0e5cd7a1f6dee3~FqeOhiAen1488514885euoutp01q DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1550832441; bh=bp2ARXaKSPnd7lzT3gQ3vTXHroqhoJW4hmTV/G6nEiw=; h=From:To:Cc:Subject:Date:References:From; b=cnDhV9UPFKK8BOGvMzzd/e9dN3GhxWzrPpe02dS8QKT+p386PZmQZ8gAtSKZ5zVX/ J8RZ0IqtN3EJafYMVrq3zDRjD5IXdNxvl7xowJxfAqtrw+zXnNVliSbnR1omSbf9Gm 1842zxbydUTPMufvxzzrxU3dRB0gIsmL5+ORR2tY= Received: from eusmges2new.samsung.com (unknown [203.254.199.244]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20190222104721eucas1p2c510f4d9b3129239928a7e3628a04fe8~FqeN9WnJD3254832548eucas1p2L; Fri, 22 Feb 2019 10:47:21 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges2new.samsung.com (EUCPMTA) with SMTP id 9F.AE.04294.833DF6C5; Fri, 22 Feb 2019 10:47:20 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20190222104720eucas1p24f14bfd053f6feea36c310e45f0cae42~FqeNT7VPs3253132531eucas1p2P; Fri, 22 Feb 2019 10:47:20 +0000 (GMT) X-AuditID: cbfec7f4-84fff700000010c6-86-5c6fd338cc75 Received: from eusync1.samsung.com ( [203.254.199.211]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id 91.5B.04284.833DF6C5; Fri, 22 Feb 2019 10:47:20 +0000 (GMT) Received: from AMDC2765.digital.local ([106.116.147.25]) by eusync1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0PNB001O3PYS8940@eusync1.samsung.com>; Fri, 22 Feb 2019 10:47:20 +0000 (GMT) From: Marek Szyprowski To: linux-samsung-soc@vger.kernel.org Cc: Marek Szyprowski , Krzysztof Kozlowski , Bartlomiej Zolnierkiewicz , Seung-Woo Kim Subject: [PATCH] ARM: exynos: Set MCPM as mandatory for Exynos542x/5800 SoCs Date: Fri, 22 Feb 2019 11:47:08 +0100 Message-id: <20190222104708.28447-1-m.szyprowski@samsung.com> X-Mailer: git-send-email 2.17.1 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrHLMWRmVeSWpSXmKPExsWy7djP87oWl/NjDNZNsrbYOGM9q8X58xvY LWac38dksfbIXSBr8ks2B1aPTas62Tz6tqxi9Pi8SS6AOYrLJiU1J7MstUjfLoErY23fLuaC s5IVR67MZWlgfC/axcjJISFgIvHk7EX2LkYuDiGBFYwSjxc9YgFJCAl8ZpRoniMJUzR9cTcr RNEyRomvDTtYIJwGJonNk9uZQarYBAwlut52sYHYIgKqEp/bFoCNZRbYwSjxYPkcdpCEsICP xJz1H8BsFqCiq2f/gdm8ArYSn+73M0Gsk5dYveEAM0izhMBZVom7N9cwQiRcJA7sXMwOYctI dHYcZIIoamaUaJ8xix3C6WGU2DpnBxtElbXE4eMXWUFsZgE+iUnbpgON5QCK80p0tAlBlHhI TPj2lh3i6ViJa/3XmSYwii9gZFjFKJ5aWpybnlpslJdarlecmFtcmpeul5yfu4kRGCun/x3/ soNx15+kQ4wCHIxKPLwWG/NihFgTy4orcw8xSnAwK4nw7jqZHyPEm5JYWZValB9fVJqTWnyI UZqDRUmct5rhQbSQQHpiSWp2ampBahFMlomDU6qBsWXVhKB91yW/+oTmtLXVO0z+EmlxKb7o wtZr+1f8/772kcK/25KntnVPeJmpcG75+a9fhX8XSEtGmnw2jnc7zLd829xN7B8kzhk/Spb/ U5pR8INJ0OTAi562Gx9n7HLI8FmyUmGTlsmfdRoh9qxeXRvN70qr39/l8kn05LodUW8rDc+X LHVv61diKc5INNRiLipOBAD+AwMAkQIAAA== X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrDJMWRmVeSWpSXmKPExsVy+t/xy7oWl/NjDBa85bfYOGM9q8X58xvY LWac38dksfbIXSBr8ks2B1aPTas62Tz6tqxi9Pi8SS6AOYrLJiU1J7MstUjfLoErY23fLuaC s5IVR67MZWlgfC/axcjJISFgIjF9cTdrFyMXh5DAEkaJ41+fsUA4TUwSe1onMINUsQkYSnS9 7WIDsUUEVCU+ty1gByliFtjFKNG6/CQLSEJYwEdizvoP7CA2C1DR1bP/wGxeAVuJT/f7mSDW yUus3nCAeQIj1wJGhlWMIqmlxbnpucWGesWJucWleel6yfm5mxiBft527OfmHYyXNgYfYhTg YFTi4bXYmBcjxJpYVlyZe4hRgoNZSYR318n8GCHelMTKqtSi/Pii0pzU4kOM0hwsSuK85w0q o4QE0hNLUrNTUwtSi2CyTBycUg2MNhv2drYY5L4/27Jhq5Zey5J56fL7unbJzbjiqpH+83jr i2tnjHdl3HoQI2+u4PufX7wvpHnJWvv1ZjbLLjjIK015v1jR/QDf+dqd70z/ZfpeEguczjv5 pdPstRaHsk0a8+70nCj4V8Cbr3V7g3tdlftpn6NTHR8c23bz4levkwzL3iXq/n23W4mlOCPR UIu5qDgRAG2o6DfvAQAA X-CMS-MailID: 20190222104720eucas1p24f14bfd053f6feea36c310e45f0cae42 CMS-TYPE: 201P X-CMS-RootMailID: 20190222104720eucas1p24f14bfd053f6feea36c310e45f0cae42 References: Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Support for Exynos5420/5422/5800 SoCs requires MCPM to properly boot all CPU cores on all currectly supported platforms: Peach Pit (Exynos5420), Odroid XU3/XU3lite/XU4/HC1 (Exynos5422) and Peach Pi (Exynos5800). Without it some CPU cores fail to come online. Remove then the ability to disable MCPM and make it mandatory when Exynos542x/5800 support is enabled. Signed-off-by: Marek Szyprowski --- arch/arm/mach-exynos/Kconfig | 12 +++--------- arch/arm/mach-exynos/Makefile | 2 +- arch/arm/mach-exynos/suspend.c | 12 ++++-------- 3 files changed, 8 insertions(+), 18 deletions(-) diff --git a/arch/arm/mach-exynos/Kconfig b/arch/arm/mach-exynos/Kconfig index b40963cf91c7..62b734a8092b 100644 --- a/arch/arm/mach-exynos/Kconfig +++ b/arch/arm/mach-exynos/Kconfig @@ -106,21 +106,15 @@ config SOC_EXYNOS5420 bool "SAMSUNG EXYNOS5420" default y depends on ARCH_EXYNOS5 + select MCPM + select ARM_CCI400_PORT_CTRL + select ARM_CPU_SUSPEND config SOC_EXYNOS5800 bool "SAMSUNG EXYNOS5800" default y depends on SOC_EXYNOS5420 -config EXYNOS5420_MCPM - bool "Exynos5420 Multi-Cluster PM support" - depends on MCPM && SOC_EXYNOS5420 - select ARM_CCI400_PORT_CTRL - select ARM_CPU_SUSPEND - help - This is needed to provide CPU and cluster power management - on Exynos5420 implementing big.LITTLE. - config EXYNOS_CPU_SUSPEND bool select ARM_CPU_SUSPEND diff --git a/arch/arm/mach-exynos/Makefile b/arch/arm/mach-exynos/Makefile index cd00c82a1add..fb381d69f8d1 100644 --- a/arch/arm/mach-exynos/Makefile +++ b/arch/arm/mach-exynos/Makefile @@ -18,5 +18,5 @@ plus_sec := $(call as-instr,.arch_extension sec,+sec) AFLAGS_exynos-smc.o :=-Wa,-march=armv7-a$(plus_sec) AFLAGS_sleep.o :=-Wa,-march=armv7-a$(plus_sec) -obj-$(CONFIG_EXYNOS5420_MCPM) += mcpm-exynos.o +obj-$(CONFIG_SOC_EXYNOS5420) += mcpm-exynos.o CFLAGS_mcpm-exynos.o += -march=armv7-a diff --git a/arch/arm/mach-exynos/suspend.c b/arch/arm/mach-exynos/suspend.c index 0850505ac78b..c94ffa5e542c 100644 --- a/arch/arm/mach-exynos/suspend.c +++ b/arch/arm/mach-exynos/suspend.c @@ -267,10 +267,8 @@ static int exynos5420_cpu_suspend(unsigned long arg) writel_relaxed(0x0, pm_state.sysram_base + EXYNOS5420_CPU_STATE); - if (IS_ENABLED(CONFIG_EXYNOS5420_MCPM)) { - mcpm_set_entry_vector(cpu, cluster, exynos_cpu_resume); - mcpm_cpu_suspend(); - } + mcpm_set_entry_vector(cpu, cluster, exynos_cpu_resume); + mcpm_cpu_suspend(); pr_info("Failed to suspend the system\n"); @@ -345,8 +343,7 @@ static void exynos5420_pm_prepare(void) exynos_pm_enter_sleep_mode(); /* ensure at least INFORM0 has the resume address */ - if (IS_ENABLED(CONFIG_EXYNOS5420_MCPM)) - pmu_raw_writel(__pa_symbol(mcpm_entry_point), S5P_INFORM0); + pmu_raw_writel(__pa_symbol(mcpm_entry_point), S5P_INFORM0); tmp = pmu_raw_readl(EXYNOS_L2_OPTION(0)); tmp &= ~EXYNOS_L2_USE_RETENTION; @@ -444,8 +441,7 @@ static void exynos3250_pm_resume(void) static void exynos5420_prepare_pm_resume(void) { - if (IS_ENABLED(CONFIG_EXYNOS5420_MCPM)) - WARN_ON(mcpm_cpu_powered_up()); + WARN_ON(mcpm_cpu_powered_up()); } static void exynos5420_pm_resume(void)