From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 590D8C10F05 for ; Tue, 5 Dec 2023 18:14:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:References :In-Reply-To:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=lwt5306ADCcL5GbrxDkmpx+oPl7zZLxC6NZpuYNbdLY=; b=Wi3qKtNtoCdblW dWy9AS5rdjz/SU/UcXCioazalhEcC6VpJ6GtsvbawLZ7k51WDXKigRLpkTV/dhLXTILrGM0NQMOo2 N56FxeS9a4lsKO6gG0acrUOGYW0zzCieEU3XXoZnChK+Y+Lbqzj0RNDUrgzwX0dT57QgNrc5he5ya IQb1tUIZUUHCilw8WD+wxJ3Ray+4/sDS7f37fkAFV1LrqIdEY4Di8oWBJXnj0JCrtpC4mKqdxu+hM gDKvgR9Kh4vSkJ2XxwG1ii/8M0OocsvzM+rk3guiycNr8IEg4v+gXpWwRJ2B9KGplZrY0OziAjP3V ajkdWEOcKOUrywZqW+HQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rAZvp-0088BA-0b; Tue, 05 Dec 2023 18:14:05 +0000 Received: from mail-pf1-f179.google.com ([209.85.210.179]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rAZvm-008881-14 for linux-arm-kernel@lists.infradead.org; Tue, 05 Dec 2023 18:14:04 +0000 Received: by mail-pf1-f179.google.com with SMTP id d2e1a72fcca58-6ce5a0c37cfso1855101b3a.3 for ; Tue, 05 Dec 2023 10:13:59 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701800039; x=1702404839; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=f6O3k1fVwKBlR9l5h/5iOcOYL+vrfkO7m0bwm2f3PUY=; b=URbNSHr1vSUZIbA8PPJ0trBfkxw3u0JpJvlC/MoJiHrwfnSbECMF4klpc2UrOyK+30 TivAn3GvXRwsFvgMtK1UwwJu44MqSXZDeKkhklL+NjilPMvz7/aHXQulxbVnQYeiVY+e 4Um4anB/POWuj03qgoOSdb5e23jh1OR7xL1a4aOO9QnBtH46sZasORCnV1Blp/hpi7zl VZKz3+yo5Fh1KrIokwZfvMXGBWvb9+6Yag9Ijb5gdH2kIesBRKus14er2V70gZzRpv5N TTEJk177Qs27qFAwykg5BOkeXs4lJ5rAagjccZbfBcp4Aytrl4ujKne+ugiaH2sp5h0G BCGw== X-Gm-Message-State: AOJu0YxEhw6ljyuiyAg1m4FCvF388aSuJ5I4fk4ic17wC7vr4VIbrzkb dPkbc5yiafBD5ZRzSzCmyJWr/Q== X-Google-Smtp-Source: AGHT+IFGoWu4itf8bKlSc1tdncXMBMxZOM89k8FZfHLXfBhCe0/dkLvWZKn7t/8Qk11x0KbdHGPe7g== X-Received: by 2002:a05:6a20:840d:b0:18d:1e16:8017 with SMTP id c13-20020a056a20840d00b0018d1e168017mr14397847pzd.8.1701800038431; Tue, 05 Dec 2023 10:13:58 -0800 (PST) Received: from localhost (75-172-121-199.tukw.qwest.net. [75.172.121.199]) by smtp.gmail.com with ESMTPSA id bm10-20020a056a00320a00b006cbafd6996csm9733230pfb.123.2023.12.05.10.13.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Dec 2023 10:13:57 -0800 (PST) From: Kevin Hilman To: Tony Lindgren , Nishanth Menon , Vignesh Raghavendra Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Dhruva Gole Subject: Re: [PATCH v2 1/1] arm64: dts: ti: k3-am62-wakeup: Configure ti-sysc for wkup_uart0 In-Reply-To: <20231114073209.40756-1-tony@atomide.com> References: <20231114073209.40756-1-tony@atomide.com> Date: Tue, 05 Dec 2023 10:13:57 -0800 Message-ID: <7h5y1c7c0q.fsf@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231205_101402_372266_2BB62133 X-CRM114-Status: GOOD ( 23.38 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Tony Lindgren writes: > The devices in the wkup domain are capable of waking up the system from > suspend. We can configure the wkup domain devices in a generic way using > the ti-sysc interconnect target module driver like we have done with the > earlier TI SoCs. > > As ti-sysc manages the SYSCONFIG related registers independent of the > child hardware device, the wake-up configuration is also set even if > wkup_uart0 is reserved by sysfw. > > The wkup_uart0 device has interconnect target module register mapping like > dra7 wkup uart. There is a 1 MB interconnect target range with one uart IP > block in the target module. The power domain and clock affects the whole > interconnect target module. > > Note we change the functional clock name to follow the ti-sysc binding > and use "fck" instead of "fclk". > > Tested-by: Dhruva Gole > Signed-off-by: Tony Lindgren > --- > > Changes since v1: > > - Added Tested-by from Dhruva > > --- > arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi | 33 ++++++++++++++++++---- > 1 file changed, 27 insertions(+), 6 deletions(-) > > diff --git a/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi b/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi > --- a/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi > +++ b/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi > @@ -5,6 +5,8 @@ > * Copyright (C) 2020-2022 Texas Instruments Incorporated - https://www.ti.com/ > */ > > +#include > + > &cbass_wakeup { > wkup_conf: syscon@43000000 { > bootph-all; > @@ -21,14 +23,33 @@ chipid: chipid@14 { > }; > }; > > - wkup_uart0: serial@2b300000 { > - compatible = "ti,am64-uart", "ti,am654-uart"; > - reg = <0x00 0x2b300000 0x00 0x100>; > - interrupts = ; > + target-module@2b300000 { > + compatible = "ti,sysc-omap2", "ti,sysc"; > + reg = <0 0x2b300050 0 0x4>, > + <0 0x2b300054 0 0x4>, > + <0 0x2b300058 0 0x4>; > + reg-names = "rev", "sysc", "syss"; > + ti,sysc-mask = <(SYSC_OMAP2_ENAWAKEUP | > + SYSC_OMAP2_SOFTRESET | > + SYSC_OMAP2_AUTOIDLE)>; > + ti,sysc-sidle = , > + , > + , > + ; > + ti,syss-mask = <1>; > power-domains = <&k3_pds 114 TI_SCI_PD_EXCLUSIVE>; > clocks = <&k3_clks 114 0>; I'm a little confused why these power-domain and clocks stay here and are not moved under the wkup_uart0 node... > - clock-names = "fclk"; > - status = "disabled"; > + clock-names = "fck"; > + #address-cells = <1>; > + #size-cells = <1>; > + ranges = <0 0 0x2b300000 0x100000>; > + > + wkup_uart0: serial@2b300000 { > + compatible = "ti,am64-uart", "ti,am654-uart"; > + reg = <0 0x100>; > + interrupts = ; > + status = "disabled"; ...here. The SCI device ID 114 is specifically for wkup_uart0[1], so it seems to me those should be in the wkup_uart0 node. Kevin [1] https://software-dl.ti.com/tisci/esd/latest/5_soc_doc/am62x/devices.html _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pf1-f169.google.com (mail-pf1-f169.google.com [209.85.210.169]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 59E5FB0 for ; Tue, 5 Dec 2023 10:13:59 -0800 (PST) Received: by mail-pf1-f169.google.com with SMTP id d2e1a72fcca58-6ce26a03d9eso2246308b3a.0 for ; Tue, 05 Dec 2023 10:13:59 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701800039; x=1702404839; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=f6O3k1fVwKBlR9l5h/5iOcOYL+vrfkO7m0bwm2f3PUY=; b=MLgDGh1dQmCGJS6ghAxXQHY7RAefNdkH7PBUQef/uhp3DeIWz3478f/hU5t3/Om6Iy eBcREPqK2IfCQXrd+P4+XLQQrpYwEjhAJr2+G1T9PVjcHEucp/jpF8qpsHSxa9fXfYH3 UyMUooosTjEA6ZNDMiadAJCCylBIeQYd/+qLIxPymMMtWwMC9bGUv83p60YRyC4pe2pm rjyULOI68cuHc9sKkYuJcYPwgm50fyM4Ito9CQKLZr+i3lWyNZkco/KrIFRgN4CGjLVW fQz/VIM/tZiNRIQMk2fpq/U8rpnKUAqsRwwqnPj2HeFHiPK254l+t4IK5Hr1iy1mp7JN b+3w== X-Gm-Message-State: AOJu0Yyj2jUSonu4fWB7HZ1fMvahsocbd4U0y+nNFqwJn/Tb2wuRPTqZ ko739pZPnZdT727IzrUn3SzsXA== X-Google-Smtp-Source: AGHT+IFGoWu4itf8bKlSc1tdncXMBMxZOM89k8FZfHLXfBhCe0/dkLvWZKn7t/8Qk11x0KbdHGPe7g== X-Received: by 2002:a05:6a20:840d:b0:18d:1e16:8017 with SMTP id c13-20020a056a20840d00b0018d1e168017mr14397847pzd.8.1701800038431; Tue, 05 Dec 2023 10:13:58 -0800 (PST) Received: from localhost (75-172-121-199.tukw.qwest.net. [75.172.121.199]) by smtp.gmail.com with ESMTPSA id bm10-20020a056a00320a00b006cbafd6996csm9733230pfb.123.2023.12.05.10.13.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Dec 2023 10:13:57 -0800 (PST) From: Kevin Hilman To: Tony Lindgren , Nishanth Menon , Vignesh Raghavendra Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Dhruva Gole Subject: Re: [PATCH v2 1/1] arm64: dts: ti: k3-am62-wakeup: Configure ti-sysc for wkup_uart0 In-Reply-To: <20231114073209.40756-1-tony@atomide.com> References: <20231114073209.40756-1-tony@atomide.com> Date: Tue, 05 Dec 2023 10:13:57 -0800 Message-ID: <7h5y1c7c0q.fsf@baylibre.com> Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain Tony Lindgren writes: > The devices in the wkup domain are capable of waking up the system from > suspend. We can configure the wkup domain devices in a generic way using > the ti-sysc interconnect target module driver like we have done with the > earlier TI SoCs. > > As ti-sysc manages the SYSCONFIG related registers independent of the > child hardware device, the wake-up configuration is also set even if > wkup_uart0 is reserved by sysfw. > > The wkup_uart0 device has interconnect target module register mapping like > dra7 wkup uart. There is a 1 MB interconnect target range with one uart IP > block in the target module. The power domain and clock affects the whole > interconnect target module. > > Note we change the functional clock name to follow the ti-sysc binding > and use "fck" instead of "fclk". > > Tested-by: Dhruva Gole > Signed-off-by: Tony Lindgren > --- > > Changes since v1: > > - Added Tested-by from Dhruva > > --- > arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi | 33 ++++++++++++++++++---- > 1 file changed, 27 insertions(+), 6 deletions(-) > > diff --git a/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi b/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi > --- a/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi > +++ b/arch/arm64/boot/dts/ti/k3-am62-wakeup.dtsi > @@ -5,6 +5,8 @@ > * Copyright (C) 2020-2022 Texas Instruments Incorporated - https://www.ti.com/ > */ > > +#include > + > &cbass_wakeup { > wkup_conf: syscon@43000000 { > bootph-all; > @@ -21,14 +23,33 @@ chipid: chipid@14 { > }; > }; > > - wkup_uart0: serial@2b300000 { > - compatible = "ti,am64-uart", "ti,am654-uart"; > - reg = <0x00 0x2b300000 0x00 0x100>; > - interrupts = ; > + target-module@2b300000 { > + compatible = "ti,sysc-omap2", "ti,sysc"; > + reg = <0 0x2b300050 0 0x4>, > + <0 0x2b300054 0 0x4>, > + <0 0x2b300058 0 0x4>; > + reg-names = "rev", "sysc", "syss"; > + ti,sysc-mask = <(SYSC_OMAP2_ENAWAKEUP | > + SYSC_OMAP2_SOFTRESET | > + SYSC_OMAP2_AUTOIDLE)>; > + ti,sysc-sidle = , > + , > + , > + ; > + ti,syss-mask = <1>; > power-domains = <&k3_pds 114 TI_SCI_PD_EXCLUSIVE>; > clocks = <&k3_clks 114 0>; I'm a little confused why these power-domain and clocks stay here and are not moved under the wkup_uart0 node... > - clock-names = "fclk"; > - status = "disabled"; > + clock-names = "fck"; > + #address-cells = <1>; > + #size-cells = <1>; > + ranges = <0 0 0x2b300000 0x100000>; > + > + wkup_uart0: serial@2b300000 { > + compatible = "ti,am64-uart", "ti,am654-uart"; > + reg = <0 0x100>; > + interrupts = ; > + status = "disabled"; ...here. The SCI device ID 114 is specifically for wkup_uart0[1], so it seems to me those should be in the wkup_uart0 node. Kevin [1] https://software-dl.ti.com/tisci/esd/latest/5_soc_doc/am62x/devices.html