Received: by 2002:a05:7412:ba23:b0:fa:4c10:6cad with SMTP id jp35csp2052123rdb; Sun, 21 Jan 2024 05:33:12 -0800 (PST) X-Google-Smtp-Source: AGHT+IEI5rZT5r77dXSwpg3WLF1ZOQLrC1/PEkiYtTDwiX+yqcepUOmU/anXv4SThNHIAOiosWpb X-Received: by 2002:a17:90a:fa0e:b0:28f:fc6e:7ecc with SMTP id cm14-20020a17090afa0e00b0028ffc6e7eccmr909643pjb.41.1705843992409; Sun, 21 Jan 2024 05:33:12 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705843992; cv=pass; d=google.com; s=arc-20160816; b=0HQDzMZH0I9Zqii+TZZpctzzf4dY3wNMdDvzV6krEy+GiW5aFP2oVqjDBRXn+vtoAH L5V8b5RGI9CSTtrKnhaLtGLUvOEwBM9NTgVBIzC4qDoOg7Cof/eRw9zgBpm5HWBUflq3 i9YqEUJ5SqwYK6EJ581M2TDMPsMRsKNaO9VtfIRnhh1nTw9rgPifMXv/+bfxgUBV5prM jOzZfJCZWkRzttkRjEMuZaTSy7qYDNQBhQjHlBtdpcXmbLKmy4xtOaFNjWKtBnbHzZgW IXumtQ0htLijxbFkkggZ9kzAZWzTaOww3kgyzwCmdQT9L6U9i4x5FlRok8ZuUwvh7KjH GkAQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=BJPnl20F1dSj0JWAOfRPp5XBIWtpRYozNhAzJ7VIE9o=; fh=mBquOaC/xX4bNqCekHyOz5Ozl++Uf4Ccjx/dntfkUdo=; b=zEeyoGIZwUlBQ4M/5bIrkiEnWBe819jJaTf5JEitaudjdKtXYKOgyuS6Gndw73PY6D Yxwap3lop1ikFSluFnI72jqxjUIuq6qGHLKZCKdJbAp3H+F2/KCWCFlMvh2Ceubg9VSL EMWSYh+ffGkID+CwG+pkoD1JRmh6rxYeup6AXdX778eMYWwhBbCaafZbja8jDZqPCj3p 2SfrzILaB2D1uRlZ5i7DyIj9aOPGzgAKPKc2QhtrVCTlrdvgDs5BiurtnSiDIsbhry5N RnDKBIg+/PqRwDSlL3CkFX6iJMYDZdSE4CssKiQFrV+tks6/WINuJM3J+OKjV3bk9NXO Xe8Q== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=lEiJlW4C; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-32066-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-32066-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id a5-20020a170902ee8500b001d74823fc26si975565pld.583.2024.01.21.05.33.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 21 Jan 2024 05:33:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-32066-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=lEiJlW4C; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-32066-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-32066-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org 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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 0E84D282F54 for ; Sun, 21 Jan 2024 13:33:12 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id DE3083717F; Sun, 21 Jan 2024 13:33:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="lEiJlW4C" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 01A1F36AFA; Sun, 21 Jan 2024 13:33:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705843983; cv=none; b=bBV1S1NIAyq7MCWSD66n7V1+ZDdmzIYOQ5SoSHE5w7U5NpztrVlskFEVeDfPensv9EO3aXWDxriAFWfgHo/N0PX5vjSU8Ghv0a63qAO10JrdBAt7wUAhwzIDGEdKrYYrL/EAfe3QnV6MDivE/4sg1MtGwmkl8sm+Q8mY6bJ+O7Y= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705843983; c=relaxed/simple; bh=WO1X2k3Tcsgw0LmomtyLLfnR3lITak/6PftppiXMzfE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=BL7arqdsKN4ltM4ddA0WHYFi7WqV6rmvVPWc1xb9IcI0FgGchxoHn8KmvD7gVZ7csa4QrmuySQ3V9nTukwsdX63WGuc/itjqfU4ek73z7TE7Nm8zfaAqIBfYVPo1LibDRF+GffM8gwRWbLnzMgcwQceGGSAtgb4q4CgIeGgSrLo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=lEiJlW4C; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id A5A2CC433F1; Sun, 21 Jan 2024 13:32:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1705843982; bh=WO1X2k3Tcsgw0LmomtyLLfnR3lITak/6PftppiXMzfE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=lEiJlW4Ca6fCl+Hnb5vYRfKXJdy+BoFzAQG23LXdeWDtfxunfmF0DEIjpCgGOrZ71 VyhUcjAcrnGmrZQj6KoEf2Tc4hrhna0AB2n8+nwqmRJRb85CNOzuOuGGp+X5F9O6Z7 7LtMmjELbNZcLMK06mu3+Z3mTXa9+H6fpBm7q/BPfVl47C1M65D+qirtmyAW3XiYn4 qjHaCGf+VcYGpKz2+eEPCKfTNOIPQrGiMC2t1N/seOgzfViYZfFOzeC5MOYAkqGE8I KVIRMgHsny5TGcndhvECpwmAWQwwUs937cmzJEiI9emplhCXwmiOaev85HLgk2/SAP 80fltvf5UuLUQ== Date: Sun, 21 Jan 2024 13:32:56 +0000 From: Conor Dooley To: Ghennadi Procopciuc Cc: Chester Lin , Andreas Farber , Matthias Brugger , Shawn Guo , Sascha Hauer , Fabio Estevam , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Michael Turquette , Stephen Boyd , NXP S32 Linux Team , Pengutronix Kernel Team , NXP Linux Team , linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, Ghennadi Procopciuc , Ciprian Costea Subject: Re: [PATCH 1/3] dt-bindings: clock: s32g: add uSDHC clock IDs Message-ID: <20240121-statutory-endurance-6d03d7e734c9@spud> References: <20240119130231.2854146-1-ghennadi.procopciuc@oss.nxp.com> <20240119130231.2854146-2-ghennadi.procopciuc@oss.nxp.com> <20240119-magnetic-racing-0adf8e5fbd4a@spud> <20240119-cattle-antarctic-432fa8e1c0ef@spud> <75a16ac3-39eb-4874-9100-d605b2cfadfc@oss.nxp.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="j8ddR5K2BQkdwnI0" Content-Disposition: inline In-Reply-To: <75a16ac3-39eb-4874-9100-d605b2cfadfc@oss.nxp.com> --j8ddR5K2BQkdwnI0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jan 19, 2024 at 11:25:57PM +0200, Ghennadi Procopciuc wrote: > On 1/19/24 18:14, Conor Dooley wrote: > > On Fri, Jan 19, 2024 at 04:11:37PM +0000, Conor Dooley wrote: > >> On Fri, Jan 19, 2024 at 03:02:28PM +0200, Ghennadi Procopciuc (OSS) wr= ote: > >>> From: Ghennadi Procopciuc > >>> > >>> Add the SCMI clock IDs for the uSDHC controller present on > >>> S32G SoCs. > >>> > >>> Signed-off-by: Ciprian Costea > >>> Signed-off-by: Ghennadi Procopciuc > >>> --- > >>> include/dt-bindings/clock/s32g-scmi-clock.h | 14 ++++++++++++++ > >>> 1 file changed, 14 insertions(+) > >>> create mode 100644 include/dt-bindings/clock/s32g-scmi-clock.h > >>> > >>> diff --git a/include/dt-bindings/clock/s32g-scmi-clock.h b/include/dt= -bindings/clock/s32g-scmi-clock.h > >>> new file mode 100644 > >>> index 000000000000..739f98a924c3 > >>> --- /dev/null > >>> +++ b/include/dt-bindings/clock/s32g-scmi-clock.h > >>> @@ -0,0 +1,14 @@ > >>> +/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause) */ > >>> +/* > >>> + * Copyright 2020-2024 NXP > >>> + */ > >>> +#ifndef _DT_BINDINGS_SCMI_CLK_S32G_H > >>> +#define _DT_BINDINGS_SCMI_CLK_S32G_H > >>> + > >>> +/* uSDHC */ > >>> +#define S32G_SCMI_CLK_USDHC_AHB 31 > >>> +#define S32G_SCMI_CLK_USDHC_MODULE 32 > >>> +#define S32G_SCMI_CLK_USDHC_CORE 33 > >>> +#define S32G_SCMI_CLK_USDHC_MOD32K 34 > >> > >> Why do these numbers not start at 0? > >=20 > > Ah, because these are the SCMI IDs directly. If these are numbers that > > are in the TRM, just use the numbers directly - there's no need to > > create bindings for that. > >=20 >=20 > Hi Conor, >=20 > I appreciate you taking the time to review the proposed changes. I > wanted to clarify that the IDs mentioned in the header are SCMI IDs > exported by the TF-A and are utilized by the second patch of this > series. These IDs are for the uSDHC controller to control its clocks. As > other SoCs use this model, I have included all the necessary IDs in a > dedicated header file: > - rk3588s (arch/arm64/boot/dts/rockchip/rk3588s.dtsi:97 [0]) > - stm32mp157c (arch/arm/boot/dts/st/stm32mp157c-ed1-scmi.dts:73 [1]) > - stm32mp131 (arch/arm/boot/dts/st/stm32mp131.dtsi:1372 [2]) >=20 > Should I remove the header and use raw numbers in the uSDHC node? IMO, yes. There's no abstraction/binding being created here if they're the SCMI IDs. Thanks, conor. > For > example: > > + usdhc0: mmc@402f0000 { > > + compatible =3D "nxp,s32g2-usdhc"; > > + reg =3D <0x402f0000 0x1000>; > > + interrupts =3D ; > > + clocks =3D <&clks 32>, > > + <&clks 31>, > > + <&clks 33>; > > + clock-names =3D "ipg", "ahb", "per"; > > + bus-width =3D <8>; > > + status =3D "disabled"; > > + }; >=20 > [0] > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/a= rch/arm64/boot/dts/rockchip/rk3588s.dtsi#n97 > [1] > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/a= rch/arm/boot/dts/st/stm32mp157c-ed1-scmi.dts#n73 > [2] > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/a= rch/arm/boot/dts/st/stm32mp131.dtsi#n1372 >=20 > --=20 > Regards, > Ghennadi >=20 --j8ddR5K2BQkdwnI0 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZa0dCAAKCRB4tDGHoIJi 0tbDAP9C3Ddt9YZ9DP7wBYaBEycx/ESvtGWww99gkrH/japApgD+JACED+ImvaAK GI58nfW2LBnYdiQEN0HZ6OvxWPwZtw0= =dtqZ -----END PGP SIGNATURE----- --j8ddR5K2BQkdwnI0--