From patchwork Wed Nov 14 15:30:58 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartlomiej Zolnierkiewicz X-Patchwork-Id: 10682773 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 5B5F114BA for ; Wed, 14 Nov 2018 15:31:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4DB012B8AA for ; Wed, 14 Nov 2018 15:31:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 421D62BA74; Wed, 14 Nov 2018 15:31: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=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8B3A72B8AA for ; Wed, 14 Nov 2018 15:31:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:References:MIME-Version:Date:Message-ID :Subject:From:To:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: List-Owner; bh=JSLqEEVQ9Ye6mFX2/4hX/Sw/uMchSfWVwr0Q5QjVidM=; b=XPpZUIZaLJqOcY 5Glr8FAMWRupo+P3pTMj4QOzt5RJC51Icar08kqB5mOUDsjsjBB2G4BoGmPpBqAUTcFtVuZ3P5jk+ M/byFcxAz0FuW5FeE4/28q3KAjLfO7P3uOTIlLwqw3KsYr0CN+XRXeSL2zkgcUU0rwIHlo9TRgmYc C3I0a73vohEXJuZoV4+sM1/laOdKMAzy3qyPuIFXJ4RjjPKFddkj+mURS3I/VJcpDfLVjHkb18J8B SyFjcbvIcBHQvqAKUzSK5JlCDsD+GZ/ZoKyjjUFCrHv6aBtu3sy3tXKrYj0/vVRgI9JDA7WBIwNDz CczB+dSTSnQjhHCPh8Mw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gMx8U-0003Cx-IN; Wed, 14 Nov 2018 15:31:22 +0000 Received: from merlin.infradead.org ([2001:8b0:10b:1231::1]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gMx8S-0003CU-U0 for linux-arm-kernel@bombadil.infradead.org; Wed, 14 Nov 2018 15:31:21 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=References:Content-Type: Content-Transfer-Encoding:MIME-Version:Date:Message-ID:Subject:From:Cc:To: Sender:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=tGeLJ0zJAa4AtbzWtUaLXivm2mYwCERxugzHwyHQB3U=; b=J44gPFJa+hh4Gjn4gPjN1jkS3 e88r6fqEYIF/lgePM+CQu1YI4XYzDI8uA4gf7mf5wvXlkvtFpSMtSsYOqt5OPedlpZo6qTMVhctRF UzLifde4eK7/10eqilgVPgHB3QRA+E9ukDDqeYVSATK67LjHeVhz8AqEvwfGkXGPN24QAdRtSRoQE 1DRBKMDdYBXqhaRU3LI96XsAiOdjBD7JJwLqoHymK2hxbQE67bGkku/7K/3n6t+CMt+9uW1eOYeSo dC5+VOQqZZeUb64dyC6yhXPC5MXBkYglVWk+px0EKh774UKYTnB3Flp683pOcFohmCaXNxPo3KUzW JeB0SnFpQ==; Received: from mailout1.w1.samsung.com ([210.118.77.11]) by merlin.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gMx8P-00085a-FO for linux-arm-kernel@lists.infradead.org; Wed, 14 Nov 2018 15:31:18 +0000 Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout1.w1.samsung.com (KnoxPortal) with ESMTP id 20181114153101euoutp01038f31d836207130e0274334594943d3~nB1WErts82570625706euoutp01I for ; Wed, 14 Nov 2018 15:31:01 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.w1.samsung.com 20181114153101euoutp01038f31d836207130e0274334594943d3~nB1WErts82570625706euoutp01I DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1542209461; bh=tGeLJ0zJAa4AtbzWtUaLXivm2mYwCERxugzHwyHQB3U=; h=To:Cc:From:Subject:Date:References:From; b=sofo6MX5U7leXBxl06AI02g4g6+maJ24PzMwPbk0wmtBlbpdVk2Y/f8yYpQ7GZTUd XR8vtdWLIRYjgONq6ehiptwPtIohAed09Bw92HTZ3F5r8HvpeOjSbJG+m9FIlMVPqZ qoGjew9Kh65fRkWtp5L0BfygQhI/fFySXmHQ3RVE= Received: from eusmges1new.samsung.com (unknown [203.254.199.242]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20181114153100eucas1p24b3e152fde079455082a3bfaeeb86227~nB1VqGOtk2481024810eucas1p20; Wed, 14 Nov 2018 15:31:00 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges1new.samsung.com (EUCPMTA) with SMTP id 9F.32.04441.4BF3CEB5; Wed, 14 Nov 2018 15:31:00 +0000 (GMT) Received: from eusmtrp1.samsung.com (unknown [182.198.249.138]) by eucas1p1.samsung.com (KnoxPortal) with ESMTPA id 20181114153100eucas1p1a48e0febdfacfe40dd08c91a6b0d045e~nB1U7iQu61663516635eucas1p1G; Wed, 14 Nov 2018 15:31:00 +0000 (GMT) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eusmtrp1.samsung.com (KnoxPortal) with ESMTP id 20181114153059eusmtrp1cb228619a8d82e577547ec9061296dac~nB1Us_M-f1901319013eusmtrp1U; Wed, 14 Nov 2018 15:30:59 +0000 (GMT) X-AuditID: cbfec7f2-5e3ff70000001159-be-5bec3fb4119d Received: from eusmtip1.samsung.com ( [203.254.199.221]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id 59.4E.04128.3BF3CEB5; Wed, 14 Nov 2018 15:30:59 +0000 (GMT) Received: from [106.120.53.102] (unknown [106.120.53.102]) by eusmtip1.samsung.com (KnoxPortal) with ESMTPA id 20181114153059eusmtip1c62ad51d0cf0abd9ffdf39e5a36240f9~nB1UZa6hp0883608836eusmtip1c; Wed, 14 Nov 2018 15:30:59 +0000 (GMT) To: Krzysztof Kozlowski From: Bartlomiej Zolnierkiewicz Subject: [PATCH v4] ARM: SAMSUNG: limit SAMSUNG_PM_DEBUG config option to non-Exynos platforms Message-ID: Date: Wed, 14 Nov 2018 16:30:58 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 MIME-Version: 1.0 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprDKsWRmVeSWpSXmKPExsWy7djPc7pb7N9EG3x5qmyxccZ6Vov+x6+Z Lc6f38BusenxNVaLy7vmsFnMOL+PyeLQ1L2MDuwel69dZPbYtKqTzWPzknqPvi2rGD0+b5IL YI3isklJzcksSy3St0vgypg1+ydzwVvxite777M3MHaJdDFyckgImEgs2z6ZsYuRi0NIYAWj xKLvb9khnC+MEt0Nl6Aynxkl+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E1 0RQkzCtgJzH7zHwWkDCLgKrEmpvOIGFRgQiJWw87WCBKBCVOznwCZjMLqEv8mXeJGcKWl9j+ dg7zBEb+WUjKZiEpm4WkbAEj8ypGkdTS4tz03GIjveLE3OLSvHS95PzcTYzAeNh27OeWHYxd 74IPMQpwMCrx8D648SpaiDWxrLgy9xCjBAezkgivv8GbaCHelMTKqtSi/Pii0pzU4kOMpkB3 T2SWEk3OB8ZqXkm8oamhuYWlobmxubGZhZI473mDyighgfTEktTs1NSC1CKYPiYOTqkGxnhT efl8Xw8H2eVn6j0Dpq23unTrquwUzkNv5hW+n2Zw+PCkpCUXzcw/eB++c+/gxmkmS93/rPh8 xIVdWi9BeYnZNafdPddm7zn5KnRqt5jox8K67TJljtOrEzx6drMr950zDtZmdu40mnA57BRf 4eZIzy2zG6zyb9wI6LWW+K1z0barY8cTDSWW4oxEQy3mouJEAAB1SdadAgAA X-CMS-MailID: 20181114153100eucas1p1a48e0febdfacfe40dd08c91a6b0d045e X-Msg-Generator: CA X-RootMTR: 20181114153100eucas1p1a48e0febdfacfe40dd08c91a6b0d045e X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20181114153100eucas1p1a48e0febdfacfe40dd08c91a6b0d045e References: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181114_103117_621246_7D2F3551 X-CRM114-Status: GOOD ( 16.32 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-samsung-soc@vger.kernel.org, Bartlomiej Zolnierkiewicz , linux-kernel@vger.kernel.org, Russell King , Kukjin Kim , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP "Samsung PM Suspend debug" feature (controlled by SAMSUNG_PM_DEBUG config option) is not working properly (debug messages are not displayed after resume) on Exynos platforms because GPIOs restore code is not implemented. Add PLAT_S3C24XX, ARCH_S3C64XX and ARCH_S5PV210 dependencies to SAMSUNG_PM_DEBUG config option to hide it on Exynos platforms. Then convert Exynos code to not require header (use pr_debug() directly instead of S3C_PMDBG() macro and remove redundant s3c_pm_*() calls). Signed-off-by: Bartlomiej Zolnierkiewicz --- v4: - rebased on top of next-20181114 v3: - don't move PM to the line below in Kconfig v2: - convert Exynos code to not require header arch/arm/mach-exynos/suspend.c | 14 ++++---------- arch/arm/plat-samsung/Kconfig | 1 + 2 files changed, 5 insertions(+), 10 deletions(-) Index: b/arch/arm/mach-exynos/suspend.c =================================================================== --- a/arch/arm/mach-exynos/suspend.c 2018-11-14 16:01:05.095080862 +0100 +++ b/arch/arm/mach-exynos/suspend.c 2018-11-14 16:03:36.699084680 +0100 @@ -30,8 +30,6 @@ #include #include -#include - #include "common.h" #define REG_TABLE_END (-1U) @@ -498,11 +496,9 @@ static int exynos_suspend_enter(suspend_ u32 eint_wakeup_mask = exynos_read_eint_wakeup_mask(); int ret; - s3c_pm_debug_init(); - - S3C_PMDBG("%s: suspending the system...\n", __func__); + pr_debug("%s: suspending the system...\n", __func__); - S3C_PMDBG("%s: wakeup masks: %08x,%08x\n", __func__, + pr_debug("%s: wakeup masks: %08x,%08x\n", __func__, exynos_irqwake_intmask, eint_wakeup_mask); if (exynos_irqwake_intmask == -1U @@ -512,7 +508,6 @@ static int exynos_suspend_enter(suspend_ return -EINVAL; } - s3c_pm_save_uarts(); if (pm_data->pm_prepare) pm_data->pm_prepare(); flush_cache_all(); @@ -525,12 +520,11 @@ static int exynos_suspend_enter(suspend_ if (pm_data->pm_resume_prepare) pm_data->pm_resume_prepare(); - s3c_pm_restore_uarts(); - S3C_PMDBG("%s: wakeup stat: %08x\n", __func__, + pr_debug("%s: wakeup stat: %08x\n", __func__, pmu_raw_readl(S5P_WAKEUP_STAT)); - S3C_PMDBG("%s: resuming the system...\n", __func__); + pr_debug("%s: resuming the system...\n", __func__); return 0; } Index: b/arch/arm/plat-samsung/Kconfig =================================================================== --- a/arch/arm/plat-samsung/Kconfig 2018-11-14 16:01:05.095080862 +0100 +++ b/arch/arm/plat-samsung/Kconfig 2018-11-14 16:01:05.055080861 +0100 @@ -239,6 +239,7 @@ comment "Power management" config SAMSUNG_PM_DEBUG bool "Samsung PM Suspend debug" depends on PM && DEBUG_KERNEL + depends on PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210 depends on DEBUG_EXYNOS_UART || DEBUG_S3C24XX_UART || DEBUG_S3C2410_UART help Say Y here if you want verbose debugging from the PM Suspend and