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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 12777C77B7F for ; Wed, 3 May 2023 14:31:19 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id E7E9B84792; Wed, 3 May 2023 16:31:16 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=ti.com header.i=@ti.com header.b="YPAoqvo9"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 2878D8478D; Wed, 3 May 2023 16:31:15 +0200 (CEST) Received: from fllv0016.ext.ti.com (fllv0016.ext.ti.com [198.47.19.142]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 8B8DC8477F for ; Wed, 3 May 2023 16:31:11 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=nm@ti.com Received: from fllv0034.itg.ti.com ([10.64.40.246]) by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id 343EV5Tq022332; Wed, 3 May 2023 09:31:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1683124265; bh=42hsw4wP7DgfaT2qRCkHyN6VQu+hLsl5GmEBd5GfK00=; h=Date:From:To:CC:Subject:References:In-Reply-To; b=YPAoqvo9F9EUMoRTfc5+ue5xzAjCVpIlKDhNcWYKeFV27W2EEabJtEk0nQ7GM3cVv SruJmmniH8PSkOm8byo/FhIEGDoSz6wVAWTVvNGuD6zS5Dh0jg6c1xGfyQ1IJBSdPn z7FAHbH+8RwHUL/VRC+iM1+8HDXfBIuQdmiaPxjU= Received: from DLEE109.ent.ti.com (dlee109.ent.ti.com [157.170.170.41]) by fllv0034.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 343EV5wn011279 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Wed, 3 May 2023 09:31:05 -0500 Received: from DLEE115.ent.ti.com (157.170.170.26) by DLEE109.ent.ti.com (157.170.170.41) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Wed, 3 May 2023 09:31:05 -0500 Received: from lelv0327.itg.ti.com (10.180.67.183) by DLEE115.ent.ti.com (157.170.170.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Wed, 3 May 2023 09:31:04 -0500 Received: from localhost (ileaxei01-snat.itg.ti.com [10.180.69.5]) by lelv0327.itg.ti.com (8.15.2/8.15.2) with ESMTP id 343EV5oF093798; Wed, 3 May 2023 09:31:05 -0500 Date: Wed, 3 May 2023 09:31:04 -0500 From: Nishanth Menon To: Udit Kumar CC: , , , , , , , , , , Tony Lindgren Subject: Re: [PATCH 05/14] arch: arm: dts: k3-j7200: Configure pinctrl for timer IO pad Message-ID: <20230503143104.znig3wndx4mopkmp@defective> References: <20230503041326.1224717-1-u-kumar1@ti.com> <20230503041326.1224717-6-u-kumar1@ti.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20230503041326.1224717-6-u-kumar1@ti.com> X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean On 09:43-20230503, Udit Kumar wrote: > There are timer IO pads in the MCU domain, and in the MAIN domain. These > pads can be muxed for the related timers. > > There are timer IO control registers for input and output. The registers > for CTRLMMR_TIMER*_CTRL and CTRLMMR_MCU_TIMER*_CTRL are used to control > the input. The registers for CTCTRLMMR_TIMERIO*_CTRL and > CTRLMMR_MCU_TIMERIO*_CTRL the output. > > The multiplexing is documented in TRM "5.1.2.3.1.4 Timer IO Muxing Control > Registers" and "5.1.3.3.1.5 Timer IO Muxing Control Registers", and the > CASCADE_EN bit is documented in TRM "12.6.3.1 Timers Overview". > > For chaining timers, the timer IO control registers also have a CASCADE_EN > input bit in the CTRLMMR_TIMER*_CTRL in the registers. The CASCADE_EN bit > muxes the previous timer output, or possibly and external TIMER_IO pad > source, to the input clock of the selected timer instance for odd numered > timers. For the even numbered timers, the CASCADE_EN bit does not do > anything. The timer cascade input routing options are shown in TRM > "Figure 12-3224. Timers Overview". For handling beyond multiplexing, the > driver support for timer cascading should be likely be handled via the > clock framework. > > Cc: Nishanth Menon > Cc: Vignesh Raghavendra > Cc: Tony Lindgren > Signed-off-by: Udit Kumar > --- > arch/arm/dts/k3-j7200-main.dtsi | 18 ++++++++++++++++++ > arch/arm/dts/k3-j7200-mcu-wakeup.dtsi | 18 ++++++++++++++++++ > 2 files changed, 36 insertions(+) > > diff --git a/arch/arm/dts/k3-j7200-main.dtsi b/arch/arm/dts/k3-j7200-main.dtsi > index 54795db9c3..fb9e4842c1 100644 > --- a/arch/arm/dts/k3-j7200-main.dtsi > +++ b/arch/arm/dts/k3-j7200-main.dtsi > @@ -304,6 +304,24 @@ > }; > }; > > + /* TIMERIO pad input CTRLMMR_TIMER*_CTRL registers */ > + main_timerio_input: pinctrl@104200 { > + compatible = "pinctrl-single"; > + reg = <0x0 0x104200 0x0 0x50>; > + #pinctrl-cells = <1>; > + pinctrl-single,register-width = <32>; > + pinctrl-single,function-mask = <0x000001ff>; > + }; > + > + /* TIMERIO pad output CTCTRLMMR_TIMERIO*_CTRL registers */ > + main_timerio_output: pinctrl@104280 { > + compatible = "pinctrl-single"; > + reg = <0x0 0x104280 0x0 0x20>; > + #pinctrl-cells = <1>; > + pinctrl-single,register-width = <32>; > + pinctrl-single,function-mask = <0x0000001f>; > + }; > + > main_pmx0: pinctrl@11c000 { > compatible = "pinctrl-single"; > /* Proxy 0 addressing */ > diff --git a/arch/arm/dts/k3-j7200-mcu-wakeup.dtsi b/arch/arm/dts/k3-j7200-mcu-wakeup.dtsi > index 02c2493064..7ed6c31c7c 100644 > --- a/arch/arm/dts/k3-j7200-mcu-wakeup.dtsi > +++ b/arch/arm/dts/k3-j7200-mcu-wakeup.dtsi > @@ -183,6 +183,24 @@ > reg = <0x00 0x43000014 0x00 0x4>; > }; > > + /* MCU_TIMERIO pad input CTRLMMR_MCU_TIMER*_CTRL registers */ > + mcu_timerio_input: pinctrl@40f04200 { > + compatible = "pinctrl-single"; > + reg = <0x0 0x40f04200 0x0 0x28>; > + #pinctrl-cells = <1>; > + pinctrl-single,register-width = <32>; > + pinctrl-single,function-mask = <0x0000000F>; > + }; > + > + /* MCU_TIMERIO pad output CTRLMMR_MCU_TIMERIO*_CTRL registers */ > + mcu_timerio_output: pinctrl@40f04280 { > + compatible = "pinctrl-single"; > + reg = <0x0 0x40f04280 0x0 0x28>; > + #pinctrl-cells = <1>; > + pinctrl-single,register-width = <32>; > + pinctrl-single,function-mask = <0x0000000F>; > + }; > + > wkup_pmx0: pinctrl@4301c000 { > compatible = "pinctrl-single"; > /* Proxy 0 addressing */ > -- > 2.34.1 > Needs to get to k.org master. -- Regards, Nishanth Menon Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3 1A34 DDB5 849D 1736 249D