Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Frank Li <Frank.li@nxp.com>
To: Marc Kleine-Budde <mkl@pengutronix.de>
Cc: Mihalcea Laurentiu <laurentiumihalcea111@gmail.com>,
	Daniel Baluta <daniel.baluta@nxp.com>,
	Rob Herring <robh@kernel.org>, Conor Dooley <conor+dt@kernel.org>,
	devicetree@vger.kernel.org, Fabio Estevam <festevam@gmail.com>,
	Sascha Hauer <s.hauer@pengutronix.de>,
	linux-kernel@vger.kernel.org, imx@lists.linux.dev,
	Pengutronix Kernel Team <kernel@pengutronix.de>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Shawn Guo <shawnguo@kernel.org>,
	Shengjiu Wang <shengjiu.wang@nxp.com>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 4/5] arm64: dts: imx8mp: convert 'aips5' to 'aipstz5'
Date: Thu, 27 Feb 2025 11:45:36 -0500	[thread overview]
Message-ID: <Z8CWsI/DKZtDBkzE@lizhi-Precision-Tower-5810> (raw)
In-Reply-To: <20250227-monumental-whale-of-security-b1c84e-mkl@pengutronix.de>

On Thu, Feb 27, 2025 at 11:57:54AM +0100, Marc Kleine-Budde wrote:
> On 25.02.2025 16:14:34, Mihalcea Laurentiu wrote:
> >
> > On 21.02.2025 21:56, Frank Li wrote:
> > > On Fri, Feb 21, 2025 at 02:19:08PM -0500, Laurentiu Mihalcea wrote:
> > >> From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
> > >>
> > >> AIPS5 is actually AIPSTZ5 as it offers some security-related
> > >> configurations. Since these configurations need to be applied before
> > >> accessing any of the peripherals on the bus, it's better to make AIPSTZ5
> > >> be their parent instead of keeping AIPS5 and adding a child node for
> > >> AIPSTZ5. Also, because of the security configurations, the address space
> > >> of the bus has to be changed to that of the configuration registers.
> > > The orginal 0x30c0_0000..0x31200000 include 0x30df0000, why not map only
> > > config address part in your drivers.
> > >
> > > Frank
> >
> >
> > Any concerns/anything wrong with current approach?
> >
> >
> > I find it a bit awkward to have the whole bus address space
> > in the DT given that we're only interested in using the access
> > controller register space.
> >
> >
> > I'm fine with the approach you suggested but I don't see a
> > reason for using it?
>
> Looking at the "AIPS5 Memory Map" (page 34/35 in i.MX 8M Plus
> Applications Processor Reference Manual, Rev. 3, 08/2024), the
> AIPS5_Configuration is part of the AIPS5 bus. IMHO the bus is something
> different than the bus configuration. Why not model it as part of the
> bus?
>
> > >> diff --git a/arch/arm64/boot/dts/freescale/imx8mp.dtsi b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
> > >> index e0d3b8cba221..a1d9b834d2da 100644
> > >> --- a/arch/arm64/boot/dts/freescale/imx8mp.dtsi
> > >> +++ b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
> > >> @@ -1399,11 +1399,13 @@ eqos: ethernet@30bf0000 {
> > >>  			};
> > >>  		};
> > >>
> > >> -		aips5: bus@30c00000 {
> > >> -			compatible = "fsl,aips-bus", "simple-bus";
> > >> -			reg = <0x30c00000 0x400000>;
> > >> +		aips5: bus@30df0000 {
>                        ^^^^^^^^^^^^
> > >> +			compatible = "fsl,imx8mp-aipstz", "simple-bus";
> > >> +			reg = <0x30df0000 0x10000>;
> > >> +			power-domains = <&pgc_audio>;
> > >>  			#address-cells = <1>;
> > >>  			#size-cells = <1>;
> > >> +			#access-controller-cells = <0>;
> > >>  			ranges;
> > >>
> > >>  			spba-bus@30c00000 {
>                         ^^^^^^^^^^^^^^^^^
>
> This looks very strange: The aips5 bus starts at 0x30df0000 and has a
> child bus starting at 0x30c00000?

@30df0000 should match controller reg's address.

subnode address 0x30c00000,  should be descript in "ranges", which 1:1 map.

So it should be reasonable. another example:
i2c@1000 {

	device@1c <- which use difference address space.
}

The similar case also happen at pcie.

Frank

>
> regards,
> Marc
>
> --
> Pengutronix e.K.                 | Marc Kleine-Budde          |
> Embedded Linux                   | https://www.pengutronix.de |
> Vertretung Nürnberg              | Phone: +49-5121-206917-129 |
> Amtsgericht Hildesheim, HRA 2686 | Fax:   +49-5121-206917-9   |




  reply	other threads:[~2025-02-27 19:39 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-21 19:19 [PATCH 0/5] imx8mp: add support for the IMX AIPSTZ bridge Laurentiu Mihalcea
2025-02-21 19:19 ` [PATCH 1/5] dt-bindings: bus: add documentation " Laurentiu Mihalcea
2025-02-21 19:35   ` Frank Li
2025-02-23 11:50   ` Krzysztof Kozlowski
2025-02-21 19:19 ` [PATCH 2/5] dt-bindings: dsp: fsl,dsp: document 'access-controllers' property Laurentiu Mihalcea
2025-02-21 19:37   ` Frank Li
2025-02-24 17:35   ` Rob Herring (Arm)
2025-02-21 19:19 ` [PATCH 3/5] bus: add driver for IMX AIPSTZ bridge Laurentiu Mihalcea
2025-02-21 19:44   ` Frank Li
2025-02-24  7:55   ` Marco Felsch
2025-02-24 10:07     ` Mihalcea Laurentiu
2025-02-21 19:19 ` [PATCH 4/5] arm64: dts: imx8mp: convert 'aips5' to 'aipstz5' Laurentiu Mihalcea
2025-02-21 19:56   ` Frank Li
2025-02-25 14:14     ` Mihalcea Laurentiu
2025-02-25 16:16       ` Frank Li
2025-02-27 10:57       ` Marc Kleine-Budde
2025-02-27 16:45         ` Frank Li [this message]
2025-02-28  8:11           ` Marc Kleine-Budde
2025-02-28 10:19           ` Marco Felsch
2025-03-04 16:11             ` Laurentiu Mihalcea
2025-03-07 15:22               ` Marco Felsch
2025-03-10 20:24                 ` Laurentiu Mihalcea
2025-03-11 12:05                   ` Marco Felsch
2025-02-21 19:19 ` [PATCH 5/5] arm64: dts: imx8mp: make 'dsp' node depend on 'aips5' Laurentiu Mihalcea
2025-02-21 19:59   ` Frank Li

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Z8CWsI/DKZtDBkzE@lizhi-Precision-Tower-5810 \
    --to=frank.li@nxp.com \
    --cc=conor+dt@kernel.org \
    --cc=daniel.baluta@nxp.com \
    --cc=devicetree@vger.kernel.org \
    --cc=festevam@gmail.com \
    --cc=imx@lists.linux.dev \
    --cc=kernel@pengutronix.de \
    --cc=krzk+dt@kernel.org \
    --cc=laurentiumihalcea111@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mkl@pengutronix.de \
    --cc=robh@kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=shawnguo@kernel.org \
    --cc=shengjiu.wang@nxp.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox