[PATCH 0/3] remoteproc: imx_rproc: allow attaching to running core kicked by the bootloader

Hiago De Franco hiagofranco at gmail.com
Mon May 5 08:48:46 PDT 2025


From: Hiago De Franco <hiago.franco at toradex.com>

For the i.MX8X and i.MX8 family SoCs, currently when the remotecore is
started by the bootloader and the M core and A core are in the same
partition, the driver is not capable to detect the remote core and
report the correct state of it.

This series of patches implement an API call to the SCU which will
return the power mode of a given resource (M core in this case) and if
it is already powered on, the driver will attach to it. This SCU API was
already being used inside pmdomain/imx/scu-pd.c driver, therefore it has
been moved to firmware/imx/misc.c so it can be accessed by imx_rproc
driver.

Finally, the imx_rproc_clk_enable() function was also changed to make it
return before dev_clk_get() is called, as it currently generates an SCU
fault reset if the remote core is already running and the kernel tries
to enable the clock again. These changes are a follow up from a v1 sent
to imx_rproc [1] and from a reported regression [2].

[1] https://lore.kernel.org/lkml/20250423155131.101473-1-hiagofranco@gmail.com/
[2] https://lore.kernel.org/lkml/20250404141713.ac2ntcsjsf7epdfa@hiago-nb/

Hiago De Franco (3):
  remoteproc: imx_rproc: skip clock enable when M-core is managed by the
    SCU
  firmware: imx: move get power mode function from scu-pd.c to misc.c
  remoteproc: imx_rproc: add power mode check for remote core attachment

 drivers/firmware/imx/misc.c           | 47 +++++++++++++++++++++++++++
 drivers/pmdomain/imx/scu-pd.c         | 29 ++++-------------
 drivers/remoteproc/imx_rproc.c        | 27 +++++++++++++--
 include/linux/firmware/imx/svc/misc.h |  8 +++++
 4 files changed, 87 insertions(+), 24 deletions(-)

-- 
2.39.5




More information about the linux-arm-kernel mailing list