Received: by 2002:a89:413:0:b0:1fd:dba5:e537 with SMTP id m19csp1622884lqs; Sat, 15 Jun 2024 18:56:09 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX3V7CL008dxDapcklb/3cGSk7/sCLJECK8ihgJL/rUtjgSLNq40YlaZrDz6SeLB/hfRyCTdfxhcAgxekG86vTTUmzw6hYl8gO8EB23/Q== X-Google-Smtp-Source: AGHT+IH1EJQDJPZmK0G6hLB3aAS7YMyL+mD5NSYh6858W8YiUASs4NYf19NzUEMvoU72afhhPSAF X-Received: by 2002:a05:6402:197:b0:57c:bf3b:76f6 with SMTP id 4fb4d7f45d1cf-57cbf3b78d4mr4252008a12.3.1718502969613; Sat, 15 Jun 2024 18:56:09 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718502969; cv=pass; d=google.com; s=arc-20160816; b=y3PRo0wqD+ilhLpp7vRk3GgdmFmDoa6ulm4eXf2tq4OiZS95zT6ZVao3K9g18iR42N 6flQ661Qr7jxjRWLgTHSwlkYSS0YcnemS5q8C2/sVLVWgvKiei2tstk1vwJA/PYWKlH/ WYSHXWPcJclpO1Ay0VdERKGDlbe78xYOx79+VpHcv2jyfPR9ZPsJYTBW8CFd1yEcafiD 2ae5zoTk/ZfC0Rxw3u3t3ATtUJrqvtrXtGZz6h42vWalyo8fVTsmKvIAIF2RgEl1WAXI cAuAW/PhoKk7JQUyNNCTBo+1Jc+vgvaStmMtWe2q5a4c+maJwxrVcjGWn0moY3dGq8PF +GzA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=tDYKB1w0bo2FQ2U8u3ozHVKFF/ufxd2dL8jVGoWI+BA=; fh=PU+aDknRObtBkVlouZM3wQ7OkOfHTDQxGSj43BT5jT4=; b=I/NWi2AwKh2nFJ829stg0PfrvBUtEFjN3G8f1+UYeklfJfmFt4NIJoG9tV/BVGssqx k8CNPSaqlBZRU8tIyQwPqgFooPN3MlB+oPzexMu7OnzF4aJjQV74eserB4Evwhn0WSDd bYPUy/WSXbZjsBgZfSa8I7emcT5cduIEoTgCMfL8MtbZEXZC9Jc3aazP7CKoWhL97gzO nw/cs22GcU9W5fVWPUHly68aDI+3m37/hvIBiY0Cq/M2cQdacSlHU9kppgPgBYNTESVB 52E/CJS8kCDJDoNaCNBVg13z9u0OvZRELCxj93Rs6Brfa7zMPKTQmawmfNHaTYjNnaKd x4sA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@tenstorrent.com header.s=google header.b=IbcOJjIF; arc=pass (i=1 spf=pass spfdomain=tenstorrent.com dkim=pass dkdomain=tenstorrent.com dmarc=pass fromdomain=tenstorrent.com); spf=pass (google.com: domain of linux-kernel+bounces-216086-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-216086-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=tenstorrent.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id 4fb4d7f45d1cf-57cb72e2a10si3189357a12.170.2024.06.15.18.56.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 15 Jun 2024 18:56:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-216086-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@tenstorrent.com header.s=google header.b=IbcOJjIF; arc=pass (i=1 spf=pass spfdomain=tenstorrent.com dkim=pass dkdomain=tenstorrent.com dmarc=pass fromdomain=tenstorrent.com); spf=pass (google.com: domain of linux-kernel+bounces-216086-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-216086-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=tenstorrent.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 2CE971F22419 for ; Sun, 16 Jun 2024 01:56:09 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9370D167273; Sun, 16 Jun 2024 01:55:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=tenstorrent.com header.i=@tenstorrent.com header.b="IbcOJjIF" Received: from mail-pf1-f178.google.com (mail-pf1-f178.google.com [209.85.210.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CF4731649C8 for ; Sun, 16 Jun 2024 01:55:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.178 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718502926; cv=none; b=ICi7oNS3B3ZZxtuLCeL02LlwoWyLig18D4Q21IHVLrinRIpQXIDbA813Yp4oTjtF/TeaMD04YLmIiTZICTTtjIGbov2vAB/jxyR5pNGLIpar/hiM7mz6BGv8kqG36XfbNK2lWgUNT0JmKskcJPsHXWAEKpqG8gYmsls6q3jMuV4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718502926; c=relaxed/simple; bh=aOj88rgDFr9OsXNqJrSMqZorSrYAxWXmKG05lo+T9jI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Hrxbh5pcGsktZFhYXjhGD72JT+MK3NG6BU/ruyF7z7/+EEzcbA+tuM4TaOvD/m4fjIFcSadxrzqajyoNFqqKbXzaM7anVtsYNONMVXF4B8YDLNqrexSQ1mQDBhTH1tfqWUApMpAGeCPqSopWRzRjwv7GqIwffMJzKzZHUocvMWc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=tenstorrent.com; spf=pass smtp.mailfrom=tenstorrent.com; dkim=pass (2048-bit key) header.d=tenstorrent.com header.i=@tenstorrent.com header.b=IbcOJjIF; arc=none smtp.client-ip=209.85.210.178 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=tenstorrent.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=tenstorrent.com Received: by mail-pf1-f178.google.com with SMTP id d2e1a72fcca58-705c0115192so2971962b3a.1 for ; Sat, 15 Jun 2024 18:55:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tenstorrent.com; s=google; t=1718502924; x=1719107724; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=tDYKB1w0bo2FQ2U8u3ozHVKFF/ufxd2dL8jVGoWI+BA=; b=IbcOJjIFGCN0rwyEUi6prm534wwSFT3RHvAkGbLc3ISA2gx6+X3Kecoi3G/pG+kpD3 IDdsbndoY4x7dvDU/hncPTjjvVUojmyB+ui0Ak9CjSl/cItZFct6Vqid8UQubH5s/IcJ pIyKct8c9uKaCxJcibmUD95qI+cFUKgsHUtM5GVNRUZq/MfmPHd80OCpfPjbXrUid5w3 BLLyrnUAWphUB6yy4R8zKd2AKJGeTukUinNor7+EvwbM9aMT+2ua1ZBG6DTWJUIHHhE4 Ecm2VqEbBmZRtv0ol7ryTlg+dKCq295ZXz2GivVLwH4Uhro6cX7fpStDcWaHRFnc3mU/ l6MA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718502924; x=1719107724; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=tDYKB1w0bo2FQ2U8u3ozHVKFF/ufxd2dL8jVGoWI+BA=; b=hmB4JFfDb6arPYil4KoT6GrdS8awrsdpVkidSjGXRmuk36r2GzJoVwArz16MFgySTx 09a37IdzHCmopmRenMuMy4iKrLpfjMO09/CzGtVztgS10yobrepUV+GZNACZvzdRF4Xx T28Y44349JH8zpJTWhOdeqE6+DFadTl3ckGfXcMG1Hh78SRzESyW7X8tgvTGpFKFIgjO MHahijyrs6a2jq+GTJhbwo7m/n2KQBTbaOy0c7n6FwloAHRTI1DZdrmHiLV/KpV4kf73 ZCqtzA0/OtpT8hMyPgB+Zb9n5B7kgAQwWouraq5V6Aj6rZbYAEI988/bCqjknldLU8HV aAxA== X-Forwarded-Encrypted: i=1; AJvYcCXF160yZieL0LIWBXGvSS9d0pqoSFcMn2YGpWvQpZj3nY0Exi9HjP2aMdmej6VeHAWmZw/8Iyrt00O1sM5Unfm1nCgIZYjjTny8OzWL X-Gm-Message-State: AOJu0YxIw5TSaSfm4XB63oqKDl7ZiOw/KP8Q49sVulpEtj/0DH5grSwe FTqQWnp4KM6a3PQHkso4J31ggfk6WR8EEf8oxWQJZ+GwtK1dWfrJIuP6G/LMS3U= X-Received: by 2002:a05:6a20:729d:b0:1ad:6c36:ee82 with SMTP id adf61e73a8af0-1bae7d85496mr8941088637.13.1718502924144; Sat, 15 Jun 2024 18:55:24 -0700 (PDT) Received: from [127.0.1.1] ([2601:1c2:1802:170:1cea:28dd:2ee0:e8e5]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c4a769aedbsm8751201a91.43.2024.06.15.18.55.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 15 Jun 2024 18:55:23 -0700 (PDT) From: Drew Fustini Date: Sat, 15 Jun 2024 18:54:33 -0700 Subject: [PATCH 4/6] riscv: dts: thead: change TH1520 uart nodes to use clock controller Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240615-th1520-clk-v1-4-3ba4978c4d6b@tenstorrent.com> References: <20240615-th1520-clk-v1-0-3ba4978c4d6b@tenstorrent.com> In-Reply-To: <20240615-th1520-clk-v1-0-3ba4978c4d6b@tenstorrent.com> To: Jisheng Zhang , Guo Ren , Fu Wei , Yangtao Li , Thomas Bonnefille , Emil Renner Berthing , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Paul Walmsley , Palmer Dabbelt , Albert Ou Cc: linux-riscv@lists.infradead.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Drew Fustini X-Mailer: b4 0.12.3 Change the clock property in TH1520 uart nodes to a clock provided by AP_SUBSYS clock controller. Signed-off-by: Drew Fustini --- arch/riscv/boot/dts/thead/th1520-beaglev-ahead.dts | 4 ---- .../boot/dts/thead/th1520-lichee-module-4a.dtsi | 4 ---- arch/riscv/boot/dts/thead/th1520.dtsi | 24 +++++++++++----------- 3 files changed, 12 insertions(+), 20 deletions(-) diff --git a/arch/riscv/boot/dts/thead/th1520-beaglev-ahead.dts b/arch/riscv/boot/dts/thead/th1520-beaglev-ahead.dts index d9b4de9e4757..164afd18b56c 100644 --- a/arch/riscv/boot/dts/thead/th1520-beaglev-ahead.dts +++ b/arch/riscv/boot/dts/thead/th1520-beaglev-ahead.dts @@ -52,10 +52,6 @@ &sdhci_clk { clock-frequency = <198000000>; }; -&uart_sclk { - clock-frequency = <100000000>; -}; - &dmac0 { status = "okay"; }; diff --git a/arch/riscv/boot/dts/thead/th1520-lichee-module-4a.dtsi b/arch/riscv/boot/dts/thead/th1520-lichee-module-4a.dtsi index 1365d3a512a3..1b7ede570994 100644 --- a/arch/riscv/boot/dts/thead/th1520-lichee-module-4a.dtsi +++ b/arch/riscv/boot/dts/thead/th1520-lichee-module-4a.dtsi @@ -33,10 +33,6 @@ &sdhci_clk { clock-frequency = <198000000>; }; -&uart_sclk { - clock-frequency = <100000000>; -}; - &dmac0 { status = "okay"; }; diff --git a/arch/riscv/boot/dts/thead/th1520.dtsi b/arch/riscv/boot/dts/thead/th1520.dtsi index 10a38ed55658..66df04ceb3e4 100644 --- a/arch/riscv/boot/dts/thead/th1520.dtsi +++ b/arch/riscv/boot/dts/thead/th1520.dtsi @@ -141,12 +141,6 @@ apb_clk: apb-clk-clock { #clock-cells = <0>; }; - uart_sclk: uart-sclk-clock { - compatible = "fixed-clock"; - clock-output-names = "uart_sclk"; - #clock-cells = <0>; - }; - sdhci_clk: sdhci-clock { compatible = "fixed-clock"; clock-frequency = <198000000>; @@ -195,7 +189,8 @@ uart0: serial@ffe7014000 { compatible = "snps,dw-apb-uart"; reg = <0xff 0xe7014000 0x0 0x100>; interrupts = <36 IRQ_TYPE_LEVEL_HIGH>; - clocks = <&uart_sclk>; + clocks = <&clk CLK_UART_SCLK>, <&clk CLK_UART0_PCLK>; + clock-names = "baudclk", "apb_pclk"; reg-shift = <2>; reg-io-width = <4>; status = "disabled"; @@ -232,7 +227,8 @@ uart1: serial@ffe7f00000 { compatible = "snps,dw-apb-uart"; reg = <0xff 0xe7f00000 0x0 0x100>; interrupts = <37 IRQ_TYPE_LEVEL_HIGH>; - clocks = <&uart_sclk>; + clocks = <&clk CLK_UART_SCLK>, <&clk CLK_UART1_PCLK>; + clock-names = "baudclk", "apb_pclk"; reg-shift = <2>; reg-io-width = <4>; status = "disabled"; @@ -242,7 +238,8 @@ uart3: serial@ffe7f04000 { compatible = "snps,dw-apb-uart"; reg = <0xff 0xe7f04000 0x0 0x100>; interrupts = <39 IRQ_TYPE_LEVEL_HIGH>; - clocks = <&uart_sclk>; + clocks = <&clk CLK_UART_SCLK>, <&clk CLK_UART3_PCLK>; + clock-names = "baudclk", "apb_pclk"; reg-shift = <2>; reg-io-width = <4>; status = "disabled"; @@ -324,7 +321,8 @@ uart2: serial@ffec010000 { compatible = "snps,dw-apb-uart"; reg = <0xff 0xec010000 0x0 0x4000>; interrupts = <38 IRQ_TYPE_LEVEL_HIGH>; - clocks = <&uart_sclk>; + clocks = <&clk CLK_UART_SCLK>, <&clk CLK_UART2_PCLK>; + clock-names = "baudclk", "apb_pclk"; reg-shift = <2>; reg-io-width = <4>; status = "disabled"; @@ -386,7 +384,8 @@ uart4: serial@fff7f08000 { compatible = "snps,dw-apb-uart"; reg = <0xff 0xf7f08000 0x0 0x4000>; interrupts = <40 IRQ_TYPE_LEVEL_HIGH>; - clocks = <&uart_sclk>; + clocks = <&clk CLK_UART_SCLK>, <&clk CLK_UART4_PCLK>; + clock-names = "baudclk", "apb_pclk"; reg-shift = <2>; reg-io-width = <4>; status = "disabled"; @@ -396,7 +395,8 @@ uart5: serial@fff7f0c000 { compatible = "snps,dw-apb-uart"; reg = <0xff 0xf7f0c000 0x0 0x4000>; interrupts = <41 IRQ_TYPE_LEVEL_HIGH>; - clocks = <&uart_sclk>; + clocks = <&clk CLK_UART_SCLK>, <&clk CLK_UART5_PCLK>; + clock-names = "baudclk", "apb_pclk"; reg-shift = <2>; reg-io-width = <4>; status = "disabled"; -- 2.40.1