Devicetree
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzk@kernel.org>
To: Jiafei Pan <jiafei.pan@nxp.com>
Cc: "andersson@kernel.org" <andersson@kernel.org>,
	"mathieu.poirier@linaro.org" <mathieu.poirier@linaro.org>,
	Peng Fan <peng.fan@nxp.com>, Frank Li <frank.li@nxp.com>,
	"s.hauer@pengutronix.de" <s.hauer@pengutronix.de>,
	"kernel@pengutronix.de" <kernel@pengutronix.de>,
	"festevam@gmail.com" <festevam@gmail.com>,
	"imx@lists.linux.dev" <imx@lists.linux.dev>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"Z.Q. Hou" <zhiqiang.hou@nxp.com>,
	Mingkai Hu <mingkai.hu@nxp.com>,
	"linux-remoteproc@vger.kernel.org"
	<linux-remoteproc@vger.kernel.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>
Subject: Re: [PATCH v3 1/4] dt-bindings: remoteproc: add imx-rproc-psci
Date: Wed, 12 Aug 2026 12:02:58 +0200	[thread overview]
Message-ID: <9557331b-8d7e-4235-93c5-f8b799df6fff@kernel.org> (raw)
In-Reply-To: <MRWPR04MB1227740CFAD4D4AAF1758F8A48ADC2@MRWPR04MB12277.eurprd04.prod.outlook.com>

On 12/08/2026 11:19, Jiafei Pan wrote:
> 
> NXP Confidential
> On Wed, May 14, 2026 at 11:38:13AM +0000, Krzysztof Kozlowski wrote:
>>> +description:
>>> +  This binding provides support for managing Cortex-A cores as remote
>>> +  processors on i.MX platforms using the PSCI (Power State Coordination
>>> +  Interface) for CPU power management operations. This allows single
>>> +  Cortex-A core or multiple Cortex-A cores to be controlled by Linux as
>>> +  a remote processor, enabling them to run RTOS or bare-metal applications.
>>
>> Describe the hardware, not the binding.
> 
> Will fix. Updated to describe the hardware:
> 
>   NXP i.MX SoCs integrate multiple Cortex-A cores. On certain i.MX
>   platforms, one or more of these cores can be offloaded to run RTOS
>   or bare-metal firmware as a remote processor, while the remaining
>   cores run Linux. The cores are powered on and off via PSCI (Power
>   State Coordination Interface) CPU_ON/CPU_OFF calls to the firmware.
> 
>>> +  compatible:
>>> +    const: fsl,imx-rproc-psci
>>
>> Why isn't the compatible specific?
> 
> Will fix. Updated to use a SoC-specific compatible with a generic
> fallback:
> 
>   compatible:
>     - items:
>       - enum:
>           - fsl,imx93-ca53-rproc-
>       - const: fsl,imx-rproc-psci

Don't do generic fallbacks. Works poor, as visible in multiple cases now.


> 
>>> +  fsl,cpus-mask:
>>> +    $ref: /schemas/types.yaml#/definitions/uint32
>>> +    description:
>>> +      Bitmask indicating which CPU cores are assigned to this remote
>>> +      processor instance. Each bit represents a CPU core, where bit N
>>> +      corresponds to CPU N. For example, 0x2 (0b10) assigns CPU core 1,
>>> +      while 0x6 (0b110) assigns CPU cores 1 and 2.
>>
>> So you partition existing Cortex-A cores? Or how exactly? Why isn't this
>> deducible from the compatible (I assume you read carefully writing
>> bindings)?
> 
> Yes, we partition existing Cortex-A cores. On i.MX93 for example,
> there are 2 Cortex-A55 cores. Core 0 runs Linux as the primary OS,
> while core 1 (or any subset of the remaining cores on SoCs with more
> cores, e.g. 4x A55) can be assigned to a remoteproc instance to run
> RTOS or bare-metal firmware.
> 
> The reason fsl,cpus-mask cannot be deduced from the compatible is
> that the assignment is flexible and board/use-case specific. On a
> 4-core SoC, the user may assign core 1 only, cores 1+2, cores 2+3,
> or all non-primary cores to one or more remoteproc instances. This
> runtime flexibility cannot be encoded in the compatible string.
> 
> We considered using a `cpus` phandle list instead, but the CPU nodes
> in the DT are already claimed by the Linux CPU topology and do not
> naturally represent "remote processor" assignments. The bitmask
> approach directly maps to the PSCI CPU_ON/CPU_OFF MPIDR-based
> interface used by the firmware.
You replied three months after my comment. Well, you have such right but
so you know entire context is gone and I am not going to put my time to
read the binding again.

Just for you know - if you partition the cpus, they are gone from the
cpus list as well. Not sure how this affects the bitmask but remember to
model only available CPUs properly in DT.

Best regards,
Krzysztof

  reply	other threads:[~2026-08-12 10:03 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-11  2:39 [PATCH v3 0/4] remoteproc: add Cortex-A Core remoteproc support on i.MX platforms Jiafei Pan
2026-05-11  2:39 ` [PATCH v3 1/4] dt-bindings: remoteproc: add imx-rproc-psci Jiafei Pan
2026-05-11 22:41   ` sashiko-bot
2026-05-14 11:38   ` Krzysztof Kozlowski
2026-08-12  9:19     ` Jiafei Pan
2026-08-12 10:02       ` Krzysztof Kozlowski [this message]
2026-08-12 10:46   ` [PATCH v4 0/4] remoteproc: add Cortex-A Core remoteproc support on i.MX platforms Jiafei Pan
2026-08-12 10:46     ` [PATCH v4 1/4] dt-bindings: remoteproc: add imx-rproc-psci Jiafei Pan
2026-08-12 10:46     ` [PATCH v4 2/4] remoteproc: imx_rproc: add support for Cortex-A Core Jiafei Pan
2026-08-12 10:46     ` [PATCH v4 3/4] remoteproc: imx_rproc: add autoboot support for A-core Jiafei Pan
2026-08-12 10:46     ` [PATCH v4 4/4] arm64: dts: imx93: Cortex-A Core remoteproc device node Jiafei Pan
2026-05-11  2:39 ` [PATCH v3 2/4] remoteproc: imx_rproc: add support for Cortex-A Core Jiafei Pan
2026-05-11 23:10   ` sashiko-bot
2026-05-11  2:39 ` [PATCH v3 3/4] remoteproc: imx_rproc: add autoboot support for A-core Jiafei Pan
2026-05-12  0:00   ` sashiko-bot
2026-05-11  2:39 ` [PATCH v3 4/4] arm64: dts: imx93: Cortex-A Core remoteproc device node Jiafei Pan
2026-05-12  0:37   ` sashiko-bot
2026-05-11  7:00 ` [PATCH v3 0/4] remoteproc: add Cortex-A Core remoteproc support on i.MX platforms Peng Fan
2026-05-11 17:10   ` Mathieu Poirier

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=9557331b-8d7e-4235-93c5-f8b799df6fff@kernel.org \
    --to=krzk@kernel.org \
    --cc=andersson@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=festevam@gmail.com \
    --cc=frank.li@nxp.com \
    --cc=imx@lists.linux.dev \
    --cc=jiafei.pan@nxp.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-remoteproc@vger.kernel.org \
    --cc=mathieu.poirier@linaro.org \
    --cc=mingkai.hu@nxp.com \
    --cc=peng.fan@nxp.com \
    --cc=s.hauer@pengutronix.de \
    --cc=zhiqiang.hou@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