Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3170884pxk; Mon, 7 Sep 2020 05:25:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw5U2QGtfcISAdygvNbt2I1oyauU/Xb5wu1zYCcmlSTSeR/asHbd9QQJiSEvKhi4Yy9xM1P X-Received: by 2002:a17:906:b154:: with SMTP id bt20mr21601157ejb.272.1599481523427; Mon, 07 Sep 2020 05:25:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599481523; cv=none; d=google.com; s=arc-20160816; b=CuCPjJuedgOinJpvW2bj40MT+PXVT2ASs2yUbfTN+VvGkJm0Eppitjw6VfVezb7bYw DQIVtc2B+aufUsyTNA737U5b1O7T/XgGrgS2GaG8cpbkjlrYVzLNTlsKcG+g9nEZTNim YBNt91FaIah7/pPrSrdxGMjCQbZ8LrH8WIu+Pr1iHwv5FZKBFOsSp1DQOj+argiO+j5J BYTVxVkvvELxHhWZN1f+N7lmU+RTijx1AjopgVPNbqfnlV2PsUuAuZswHv4n7QjQxXT4 nYR/5/6GnQFAuI6IEC0J52LC8TJgSUMs1QDQuwiEyrV0PrmFbs1aDcfCnVc9wjAF5zE3 6a4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=nuKGqf/vF7EL7LkiPwEr5Yfqankz1VKxyRqGv5D7V/s=; b=BxuiUYtsJfnNTcbQIbYIHeBe39dcB/+MYJSt+6l0IHIJ/neJdY0WzGulq5NNV2pT2n JJM4nEH2d/gn05mmxFHSbM0RYXwykO7mkYsugHVXlwY39WTkm6ivYaXDQ6f27dda3K6e eTDB3Gi+yT1VN5mDBVEPD+GmWoQzrw7RTLu59qTlqFENp/b114RP6K7KFirzxt/V3cPF A8BBpw56X5ZXuge0uI7ECLjgBlN32VJHjbfINrPl8LK7e4yUfDHVUurBURNYbTmT+GtH qo2Zyrx4i+dN/bBxoVa8Qa7s0xcbQWrYPnc9SRa/nmkiB2cCINmmzGutxo/+UAqQmAoD qDuQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d20si5542300ejr.206.2020.09.07.05.25.00; Mon, 07 Sep 2020 05:25:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729265AbgIGMVI (ORCPT + 99 others); Mon, 7 Sep 2020 08:21:08 -0400 Received: from foss.arm.com ([217.140.110.172]:34368 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729308AbgIGMSo (ORCPT ); Mon, 7 Sep 2020 08:18:44 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id DB2361424; Mon, 7 Sep 2020 05:18:43 -0700 (PDT) Received: from donnerap.arm.com (donnerap.cambridge.arm.com [10.1.195.35]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id C20CB3F66E; Mon, 7 Sep 2020 05:18:42 -0700 (PDT) From: Andre Przywara To: soc@kernel.org Cc: Rob Herring , devicetree@vger.kernel.org, Wei Xu , Chanho Min , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 4/6] arm64: dts: hisilicon: Fix SP805 clocks Date: Mon, 7 Sep 2020 13:18:29 +0100 Message-Id: <20200907121831.242281-5-andre.przywara@arm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200907121831.242281-1-andre.przywara@arm.com> References: <20200907121831.242281-1-andre.przywara@arm.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The SP805 DT binding requires two clocks to be specified, but Hisilicon platform DTs currently only specify one clock. In practice, Linux would pick a clock named "apb_pclk" for the bus clock, and the Linux and U-Boot SP805 driver would use the first clock to derive the actual watchdog counter frequency. Since currently both are the very same clock, we can just double the clock reference, and add the correct clock-names, to match the binding. Signed-off-by: Andre Przywara --- arch/arm64/boot/dts/hisilicon/hi3660.dtsi | 10 ++++++---- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 5 +++-- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/arch/arm64/boot/dts/hisilicon/hi3660.dtsi b/arch/arm64/boot/dts/hisilicon/hi3660.dtsi index d25aac5e0bf8..994140fbc916 100644 --- a/arch/arm64/boot/dts/hisilicon/hi3660.dtsi +++ b/arch/arm64/boot/dts/hisilicon/hi3660.dtsi @@ -1089,16 +1089,18 @@ compatible = "arm,sp805-wdt", "arm,primecell"; reg = <0x0 0xe8a06000 0x0 0x1000>; interrupts = ; - clocks = <&crg_ctrl HI3660_OSC32K>; - clock-names = "apb_pclk"; + clocks = <&crg_ctrl HI3660_OSC32K>, + <&crg_ctrl HI3660_OSC32K>; + clock-names = "wdog_clk", "apb_pclk"; }; watchdog1: watchdog@e8a07000 { compatible = "arm,sp805-wdt", "arm,primecell"; reg = <0x0 0xe8a07000 0x0 0x1000>; interrupts = ; - clocks = <&crg_ctrl HI3660_OSC32K>; - clock-names = "apb_pclk"; + clocks = <&crg_ctrl HI3660_OSC32K>, + <&crg_ctrl HI3660_OSC32K>; + clock-names = "wdog_clk", "apb_pclk"; }; tsensor: tsensor@fff30000 { diff --git a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi index 3d189d9f0d24..6578f8191d71 100644 --- a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi +++ b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi @@ -843,8 +843,9 @@ compatible = "arm,sp805-wdt", "arm,primecell"; reg = <0x0 0xf8005000 0x0 0x1000>; interrupts = ; - clocks = <&ao_ctrl HI6220_WDT0_PCLK>; - clock-names = "apb_pclk"; + clocks = <&ao_ctrl HI6220_WDT0_PCLK>, + <&ao_ctrl HI6220_WDT0_PCLK>; + clock-names = "wdog_clk", "apb_pclk"; }; tsensor: tsensor@0,f7030700 { -- 2.17.1