From patchwork Fri Mar 20 16:16:45 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Javier Martinez Canillas X-Patchwork-Id: 6058011 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.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id B8F879F318 for ; Fri, 20 Mar 2015 16:20:21 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C47BD20519 for ; Fri, 20 Mar 2015 16:20:20 +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 E0F2D201FA for ; Fri, 20 Mar 2015 16:20:19 +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 1YYzbr-0004T9-Br; Fri, 20 Mar 2015 16:17:19 +0000 Received: from bhuna.collabora.co.uk ([93.93.135.160]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1YYzbl-0004PY-SR for linux-arm-kernel@lists.infradead.org; Fri, 20 Mar 2015 16:17:15 +0000 Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: javier) with ESMTPSA id 4ACBC600741 Message-ID: <550C47ED.3010301@collabora.co.uk> Date: Fri, 20 Mar 2015 17:16:45 +0100 From: Javier Martinez Canillas User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.2.0 MIME-Version: 1.0 To: Abhilash Kesavan Subject: Re: exynos5800-peach-pi: suspend/resume (still) broken References: <550953ED.10508@collabora.co.uk> In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150320_091714_250804_7DF64C63 X-CRM114-Status: GOOD ( 18.54 ) X-Spam-Score: -0.0 (/) Cc: Kevin Hilman , Vikas Sajjan , "linux-samsung-soc@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , Pankaj Dubey 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, 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 Hello Abhilash, On 03/20/2015 03:23 PM, Abhilash Kesavan wrote: >> On 03/17/2015 06:35 PM, Kevin Hilman wrote: >>> >>> Anyone else having better luck with suspend/resume on peach-pi? >>> >> >> # echo +2 > /sys/class/rtc/rtc0/wakealarm && echo mem > /sys/power/state >> >> Suspend and CPUs shutdown seems to succeed according to [0] but the system >> never wakes up... >> >> I also tried to wakeup the system with the keyboard and the trackpad that is >> a wake up source but it does not work either. >> >> I remember that when the 5420 s2r support series were posted, aclk200_disp1 >> and aclk300_disp1 clocks needed to be marked as CLK_IGNORE_UNUSED but afaiu >> that was only because display support was not yet merged but it is now. >> >> I tried anyways both marking those clocks as CLK_IGNORE_UNUSED and passing >> the clk_ignore_unused to the kernel command line but did not work either. >> >> Abhilash, Vikas, Pankaj, >> >> Any ideas of what could be causing this regression? It seems that by the >> time the Exynos5420 S2R support landed in mainline, it was already not >> working which makes it hard to bisect what caused the issue. > > I remember the Pi power LED changing color from blue on suspend. Does Thanks a lot for answering. Who manages that LED? is the kernel or the firwmare in the EC? I tried suspend to ram using ChromeOS 3.8 kernel and I see that the blue LED is indeed turned off on suspend but that does not happen in mainline. > that happen ? I'll try reproducing the issue and then probably use an > old working s2r branch in one of my local repos to track this down. > If I checkout mainline with HEAD in your commit adc548d77c22 ("ARM: EXYNOS: Use MCPM call-backs to support S2R on exynos5420") + the patch you mentioned back then to keep the aclk200_disp1 and aclk300_disp1 clocks enabled even when not used [0], I have S2R working. But even with that commit, I don't see the blue LED to be turn off like is the case in the ChromeOS 3.8 kernel. So I think you can use that as a base. I tried bisecting but it is tricky due other issues masking the S2R regression. I also tried to compare the diff between adc548d77c22 and v3.19-rc1 that is the first known bad afaict but didn't find any relevant either. By adding printouts I can tell that all the CPUs enter exynos_power_down() in arch/arm/mach-exynos/mcpm-exynos.c and also the last man disables the cluster for both Cortex A-15 and A-7 clusters. So it seems that the problem is on the resume path. > Regards, > Abhilash >> Best regards, Javier [0]: diff --git a/drivers/clk/samsung/clk-exynos5420.c b/drivers/clk/samsung/clk-exynos5420.c index 848d602efc06..d8b66339d564 100644 --- a/drivers/clk/samsung/clk-exynos5420.c +++ b/drivers/clk/samsung/clk-exynos5420.c @@ -932,14 +932,14 @@ static struct samsung_gate_clock exynos5x_gate_clks[] __initdata = { GATE(0, "aclk400_mscl", "mout_user_aclk400_mscl", GATE_BUS_TOP, 17, 0, 0), GATE(0, "aclk200_disp1", "mout_user_aclk200_disp1", - GATE_BUS_TOP, 18, 0, 0), + GATE_BUS_TOP, 18, CLK_IGNORE_UNUSED, 0), GATE(CLK_SCLK_MPHY_IXTAL24, "sclk_mphy_ixtal24", "mphy_refclk_ixtal24", GATE_BUS_TOP, 28, 0, 0), GATE(CLK_SCLK_HSIC_12M, "sclk_hsic_12m", "ff_hsic_12m", GATE_BUS_TOP, 29, 0, 0), GATE(0, "aclk300_disp1", "mout_user_aclk300_disp1", - SRC_MASK_TOP2, 24, 0, 0), + SRC_MASK_TOP2, 24, CLK_IGNORE_UNUSED, 0), GATE(CLK_MAU_EPLL, "mau_epll", "mout_mau_epll_clk", SRC_MASK_TOP7, 20, 0, 0),