summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeng Fan <peng.fan@nxp.com>2026-01-09 15:08:03 +0300
committerMathieu Poirier <mathieu.poirier@linaro.org>2026-01-13 19:47:59 +0300
commitedd2a9956055ecb50e230cd02c7791205fc8d009 (patch)
tree498419f15a8adaf0ef9e3bb8f0c8c86dcae7e574
parent454cb78611479bd5da4f191480456f42aca7f07b (diff)
downloadlinux-edd2a9956055ecb50e230cd02c7791205fc8d009.tar.xz
remoteproc: imx_rproc: Introduce prepare ops for imx_rproc_dcfg
Allow each platform to provide its own prepare operations, preparing for i.MX95 LMM and CPU ops support. No functional changes. Reviewed-by: Daniel Baluta <daniel.baluta@nxp.com> Reviewed-by: Frank Li <Frank.Li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com> Link: https://lore.kernel.org/r/20260109-imx95-rproc-2026-1-8-v6-3-d2fefb36263d@nxp.com Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
-rw-r--r--drivers/remoteproc/imx_rproc.c5
-rw-r--r--drivers/remoteproc/imx_rproc.h1
2 files changed, 6 insertions, 0 deletions
diff --git a/drivers/remoteproc/imx_rproc.c b/drivers/remoteproc/imx_rproc.c
index 78659c8fb84d..b0857a1a9660 100644
--- a/drivers/remoteproc/imx_rproc.c
+++ b/drivers/remoteproc/imx_rproc.c
@@ -527,6 +527,11 @@ static int imx_rproc_prepare(struct rproc *rproc)
rproc_coredump_add_segment(rproc, da, resource_size(&res));
rproc_add_carveout(rproc, mem);
}
+
+ if (priv->ops && priv->ops->prepare)
+ return priv->ops->prepare(rproc);
+
+ return 0;
}
static int imx_rproc_parse_fw(struct rproc *rproc, const struct firmware *fw)
diff --git a/drivers/remoteproc/imx_rproc.h b/drivers/remoteproc/imx_rproc.h
index 1b2d9f4d6d19..37417568a0ad 100644
--- a/drivers/remoteproc/imx_rproc.h
+++ b/drivers/remoteproc/imx_rproc.h
@@ -24,6 +24,7 @@ struct imx_rproc_plat_ops {
int (*stop)(struct rproc *rproc);
int (*detach)(struct rproc *rproc);
int (*detect_mode)(struct rproc *rproc);
+ int (*prepare)(struct rproc *rproc);
};
struct imx_rproc_dcfg {