From patchwork Wed Jan 10 21:04:47 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Agner X-Patchwork-Id: 858569 Return-Path: X-Original-To: incoming-imx@patchwork.ozlabs.org Delivered-To: patchwork-incoming-imx@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.infradead.org (client-ip=65.50.211.133; helo=bombadil.infradead.org; envelope-from=linux-arm-kernel-bounces+incoming-imx=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="kTnuOiyp"; dkim=fail reason="signature verification failed" (1024-bit key; secure) header.d=agner.ch header.i=@agner.ch header.b="OTaabf7h"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3zH1kq15hMz9s7g for ; Thu, 11 Jan 2018 08:05:55 +1100 (AEDT) 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:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=3taxwMrNDwFq4JDKN+lW8zwH+8LlaviNoO8cIlpXuDU=; b=kTn uOiypzhVjvwzHCDcTDhqzsKfAH6ak439X4p0q4YFAvMRYX+9z+wBmirV6b6MUTQBM/crppx2A8lkc n4N5+jxBWDurovBLnpdTNubBdDStwFkcD6oA6fVQE1zb/MEstcf6aqJwl9ZJ1HyIkghqNrKDfC/vv mrzDqhnk7vZF3PyOR0Wijlf8KURMPpql/WnNpgSaxsApEtdqVg3ojDLwLk5Y5QXVMQwMtRr4CN7pZ y+5Z2mi+BrHce5SfJpnqU3xhk9fIC0dOzDopZI4QLM7L3NS7a49+okkEb4CId+UdR331Pn5/hc1RF 7tZzcA+tpsoe2ZIqJEVOwJ4kkJx/obw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.89 #1 (Red Hat Linux)) id 1eZNZG-0006Dr-Mn; Wed, 10 Jan 2018 21:05:50 +0000 Received: from mail.kmu-office.ch ([2a02:418:6a02::a2]) by bombadil.infradead.org with esmtps (Exim 4.89 #1 (Red Hat Linux)) id 1eZNYb-0003yq-Av for linux-arm-kernel@lists.infradead.org; Wed, 10 Jan 2018 21:05:12 +0000 Received: from trochilidae.lan (unknown [IPv6:2001:1620:c6e::127]) by mail.kmu-office.ch (Postfix) with ESMTPSA id 326BE5C3A55; Wed, 10 Jan 2018 21:58:14 +0100 (CET) From: Stefan Agner To: shawnguo@kernel.org, kernel@pengutronix.de Subject: [PATCH v2 1/7] ARM: imx: add timer stop flag to ARM power off state Date: Wed, 10 Jan 2018 22:04:47 +0100 Message-Id: <20180110210453.19264-1-stefan@agner.ch> X-Mailer: git-send-email 2.15.1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=agner.ch; s=dkim; t=1515617894; bh=2A7cXtdm0uzBn4yPvAF+RMA2Ao6n1xu5YTLGKYSgDgM=; h=From:To:Cc:Subject:Date:Message-Id; b=OTaabf7hNrV0hhd/7PHT1NplSL/xNW85PSiihTsM9/fLB7/7Sx2gBBmoiP76Z1DD1AhyTpA74v/pycnebr0I10qVyufCpIlYEu9AZssuHBO0V+kOh4GCdVuyIts1C81QT6oIIJYJScKW+T/08wneDpPW+StvO78dX6F5AhpDTLs= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180110_130509_577757_3A623490 X-CRM114-Status: GOOD ( 10.78 ) X-Spam-Score: -2.0 (--) X-Spam-Report: SpamAssassin version 3.4.1 on bombadil.infradead.org summary: Content analysis details: (-2.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 SPF_PASS SPF: sender matches SPF record -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: mark.rutland@arm.com, devicetree@vger.kernel.org, Anson Huang , linux-kernel@vger.kernel.org, Stefan Agner , robh+dt@kernel.org, fabio.estevam@nxp.com, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+incoming-imx=patchwork.ozlabs.org@lists.infradead.org List-Id: linux-imx-kernel.lists.patchwork.ozlabs.org When the CPU is in ARM power off state the ARM architected timers are stopped. The flag is already present in the higher power WAIT mode. This allows to use the ARM generic timer on i.MX 6UL/6ULL SoC. Without the flag the kernel freezes when the timer enters the first time ARM power off mode. Note: The default timer on i.MX6SX is the i.MX GPT timer which is not disabled during CPU idle. However, the timer is not affected by the CPUIDLE_FLAG_TIMER_STOP flag. The flag only affects CPU local timers. Cc: Anson Huang Signed-off-by: Stefan Agner Reviewed-by: Lucas Stach --- arch/arm/mach-imx/cpuidle-imx6sx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/mach-imx/cpuidle-imx6sx.c b/arch/arm/mach-imx/cpuidle-imx6sx.c index c5a5c3a70ab1..d0f14b761ff7 100644 --- a/arch/arm/mach-imx/cpuidle-imx6sx.c +++ b/arch/arm/mach-imx/cpuidle-imx6sx.c @@ -89,6 +89,7 @@ static struct cpuidle_driver imx6sx_cpuidle_driver = { */ .exit_latency = 300, .target_residency = 500, + .flags = CPUIDLE_FLAG_TIMER_STOP, .enter = imx6sx_enter_wait, .name = "LOW-POWER-IDLE", .desc = "ARM power off",