From patchwork Mon Feb 19 08:18:36 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Myl=C3=A8ne_Josserand?= X-Patchwork-Id: 10227275 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 6EC3C60392 for ; Mon, 19 Feb 2018 08:22:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 600A828389 for ; Mon, 19 Feb 2018 08:22:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 54798283FF; Mon, 19 Feb 2018 08:22:51 +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=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID autolearn=ham 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 D755128389 for ; Mon, 19 Feb 2018 08:22:50 +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:MIME-Version:References:In-Reply-To: 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: List-Owner; bh=o1yJXJ9ldrqJlA/KAOprap0FTGcwcGNoCO9S/2d3RH0=; b=MzGon1UiPEqTEr sQQxJGSPFKFkgl6mRZDAEJVP95GdXoZwzKP92NbWFts1W6NaVOmUWXFZub+ngOqx0NsCwkgHZmbqF U+L9mM2JCf8T0u0B5xhm3QMjj162+56dgurhm1l0w10S1uwZNz9cqg+mwB4IfBG8UmL2QBan9/znf 0GacesUFJD7ZCbnY7klsdr9moHsV3xPCRiL+c+0pwMw5XJ6EWXYKY8Wx91IZ+gMv7llG7ubJeT8ig U3wTtiKj86NHJeOxMoR21gr9en0pCIOgg77Xyzv2ZSwm/qgPaz6xb87kZYZEWXvDGSQhepez4kklp uH8ZuWFbY7jmjXuFG4gg==; 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 1engie-0001X6-8f; Mon, 19 Feb 2018 08:22:40 +0000 Received: from mail.free-electrons.com ([62.4.15.54]) by bombadil.infradead.org with esmtp (Exim 4.89 #1 (Red Hat Linux)) id 1engfQ-0006oB-DH for linux-arm-kernel@lists.infradead.org; Mon, 19 Feb 2018 08:19:28 +0000 Received: by mail.free-electrons.com (Postfix, from userid 110) id 23E4120740; Mon, 19 Feb 2018 09:19:05 +0100 (CET) Received: from dell-desktop.lan (LStLambert-657-1-97-87.w90-63.abo.wanadoo.fr [90.63.216.87]) by mail.free-electrons.com (Postfix) with ESMTPSA id C2DDF207B4; Mon, 19 Feb 2018 09:18:54 +0100 (CET) From: =?UTF-8?q?Myl=C3=A8ne=20Josserand?= To: maxime.ripard@bootlin.com, wens@csie.org, linux@armlinux.org.uk, robh+dt@kernel.org, mark.rutland@arm.com Subject: [PATCH v3 6/7] arm: dts: sun8i: a83t: Fix undefined offset with virtual timer Date: Mon, 19 Feb 2018 09:18:36 +0100 Message-Id: <20180219081837.15482-7-mylene.josserand@bootlin.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180219081837.15482-1-mylene.josserand@bootlin.com> References: <20180219081837.15482-1-mylene.josserand@bootlin.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180219_001920_815483_AF5230F2 X-CRM114-Status: GOOD ( 12.05 ) 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: devicetree@vger.kernel.org, quentin.schulz@bootlin.com, linux-kernel@vger.kernel.org, clabbe.montjoie@gmail.com, thomas.petazzoni@bootlin.com, mylene.josserand@bootlin.com, 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 The ARM architected timers use an offset between their physical and virtual counters. That offset should be configured by the bootloader in CNTVOFF. However, the A83t bootloader fails to do so, and we end up with an undefined offset (which in our case is random), meaning that each CPU will have a different time, which isn't working very well. Fix that by setting the arm,cpu-registers-not-fw-configured that will make Linux use the physical timers instead of the virtual ones. One possible side effect would be that the virtualization features would be disabled. However, due to the way the GIC has been integrated in the system, it is already unusable so we're effectively not losing any feature. Signed-off-by: Mylène Josserand --- arch/arm/boot/dts/sun8i-a83t.dtsi | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/boot/dts/sun8i-a83t.dtsi b/arch/arm/boot/dts/sun8i-a83t.dtsi index e97a6d17b8d0..b9bdb891cf2f 100644 --- a/arch/arm/boot/dts/sun8i-a83t.dtsi +++ b/arch/arm/boot/dts/sun8i-a83t.dtsi @@ -123,6 +123,7 @@ , , ; + arm,cpu-registers-not-fw-configured; }; clocks {