From: Peng Fan <[email protected]>
V4:
According to Bjorn's comments, add is_iomem for da to va usage
1/8, 2/8 is new patch
3/8, follow Bjorn's comments to correct/update the err msg.
6/8, new patch
8/8, use dev_err_probe to simplify code, use queue_work instead schedule_delayed_work
https://lkml.org/lkml/2020/12/4/82
V3:
Since I was quite busy in the past days, V3 is late
Rebased on Linux-next
Add R-b tags
1/7: Add R-b tag of Mathieu, add comments
4/7: Typo fix
5/7: Add R-b tag of Mathieu, drop index Per Mathieu's comments
6/7: Add R-b tag of Mathieu
7/7: Add comment for vqid << 16, drop unneeded timeout settings of mailbox
Use queue_work instead of schedule_delayed_work
free mbox channels when remove
V2:
Rebased on linux-next
Dropped early boot feature to make patchset simple.
Drop rsc-da
https://patchwork.kernel.org/project/linux-remoteproc/cover/[email protected]/
V1:
https://patchwork.kernel.org/cover/11682461/
This patchset is to support i.MX8MQ/M coproc.
The early boot feature was dropped to make the patchset small in V2.
Since i.MX specific TCM memory requirement, add elf platform hook.
Several patches have got reviewed by Oleksij and Mathieu in v1.
Peng Fan (8):
remoteproc: introduce is_iomem to rproc_mem_entry
remoteproc: add is_iomem to da_to_va
remoteproc: imx_rproc: correct err message
remoteproc: imx_rproc: use devm_ioremap
remoteproc: imx_rproc: add i.MX specific parse fw hook
remoteproc: imx_rproc: support i.MX8MQ/M
remoteproc: imx_rproc: ignore mapping vdev regions
remoteproc: imx_proc: enable virtio/mailbox
drivers/remoteproc/imx_rproc.c | 259 ++++++++++++++++++++-
drivers/remoteproc/ingenic_rproc.c | 2 +-
drivers/remoteproc/keystone_remoteproc.c | 2 +-
drivers/remoteproc/mtk_scp.c | 6 +-
drivers/remoteproc/omap_remoteproc.c | 2 +-
drivers/remoteproc/pru_rproc.c | 2 +-
drivers/remoteproc/qcom_q6v5_adsp.c | 2 +-
drivers/remoteproc/qcom_q6v5_pas.c | 2 +-
drivers/remoteproc/qcom_q6v5_wcss.c | 2 +-
drivers/remoteproc/qcom_wcnss.c | 2 +-
drivers/remoteproc/remoteproc_core.c | 7 +-
drivers/remoteproc/remoteproc_coredump.c | 8 +-
drivers/remoteproc/remoteproc_debugfs.c | 2 +-
drivers/remoteproc/remoteproc_elf_loader.c | 21 +-
drivers/remoteproc/remoteproc_internal.h | 2 +-
drivers/remoteproc/st_slim_rproc.c | 2 +-
drivers/remoteproc/ti_k3_dsp_remoteproc.c | 2 +-
drivers/remoteproc/ti_k3_r5_remoteproc.c | 2 +-
drivers/remoteproc/wkup_m3_rproc.c | 2 +-
include/linux/remoteproc.h | 4 +-
20 files changed, 298 insertions(+), 35 deletions(-)
--
2.28.0
From: Peng Fan <[email protected]>
We might need to map an region multiple times, becaue the region might
be shared between remote processors, such i.MX8QM with dual M4 cores.
So use devm_ioremap, not devm_ioremap_resource.
Reviewed-by: Oleksij Rempel <[email protected]>
Reviewed-by: Richard Zhu <[email protected]>
Signed-off-by: Peng Fan <[email protected]>
---
V4:
None
drivers/remoteproc/imx_rproc.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/remoteproc/imx_rproc.c b/drivers/remoteproc/imx_rproc.c
index fab772b02c9f..3915c7f5ac47 100644
--- a/drivers/remoteproc/imx_rproc.c
+++ b/drivers/remoteproc/imx_rproc.c
@@ -296,7 +296,8 @@ static int imx_rproc_addr_init(struct imx_rproc *priv,
if (b >= IMX7D_RPROC_MEM_MAX)
break;
- priv->mem[b].cpu_addr = devm_ioremap_resource(&pdev->dev, &res);
+ /* Not use resource version, because we might share region */
+ priv->mem[b].cpu_addr = devm_ioremap(&pdev->dev, res.start, resource_size(&res));
if (IS_ERR(priv->mem[b].cpu_addr)) {
dev_err(dev, "failed to remap %pr \n", &res);
err = PTR_ERR(priv->mem[b].cpu_addr);
--
2.28.0
Hi Bjorn,
> Subject: [PATCH 0/8] remoteproc: imx_rproc: support iMX8MQ/M
I forgot to add subject-prefix V4 when format-patch.
Do you need to send out v5? or you could take this v4 version if it
is ok for you?
Thanks,
Peng.
>
> From: Peng Fan <[email protected]>
>
> V4:
> According to Bjorn's comments, add is_iomem for da to va usage 1/8, 2/8
> is new patch 3/8, follow Bjorn's comments to correct/update the err msg.
> 6/8, new patch
> 8/8, use dev_err_probe to simplify code, use queue_work instead
> schedule_delayed_work
> https://lkml.org/lkml/2020/12/4/82
>
> V3:
> Since I was quite busy in the past days, V3 is late Rebased on Linux-next
> Add R-b tags
> 1/7: Add R-b tag of Mathieu, add comments
> 4/7: Typo fix
> 5/7: Add R-b tag of Mathieu, drop index Per Mathieu's comments
> 6/7: Add R-b tag of Mathieu
> 7/7: Add comment for vqid << 16, drop unneeded timeout settings of
> mailbox
> Use queue_work instead of schedule_delayed_work
> free mbox channels when remove
>
> V2:
> Rebased on linux-next
> Dropped early boot feature to make patchset simple.
> Drop rsc-da
>
> https://patchwork.kernel.org/project/linux-remoteproc/cover/20200927064
> [email protected]/
>
> V1:
> https://patchwork.kernel.org/cover/11682461/
>
> This patchset is to support i.MX8MQ/M coproc.
> The early boot feature was dropped to make the patchset small in V2.
>
> Since i.MX specific TCM memory requirement, add elf platform hook.
> Several patches have got reviewed by Oleksij and Mathieu in v1.
>
> Peng Fan (8):
> remoteproc: introduce is_iomem to rproc_mem_entry
> remoteproc: add is_iomem to da_to_va
> remoteproc: imx_rproc: correct err message
> remoteproc: imx_rproc: use devm_ioremap
> remoteproc: imx_rproc: add i.MX specific parse fw hook
> remoteproc: imx_rproc: support i.MX8MQ/M
> remoteproc: imx_rproc: ignore mapping vdev regions
> remoteproc: imx_proc: enable virtio/mailbox
>
> drivers/remoteproc/imx_rproc.c | 259
> ++++++++++++++++++++-
> drivers/remoteproc/ingenic_rproc.c | 2 +-
> drivers/remoteproc/keystone_remoteproc.c | 2 +-
> drivers/remoteproc/mtk_scp.c | 6 +-
> drivers/remoteproc/omap_remoteproc.c | 2 +-
> drivers/remoteproc/pru_rproc.c | 2 +-
> drivers/remoteproc/qcom_q6v5_adsp.c | 2 +-
> drivers/remoteproc/qcom_q6v5_pas.c | 2 +-
> drivers/remoteproc/qcom_q6v5_wcss.c | 2 +-
> drivers/remoteproc/qcom_wcnss.c | 2 +-
> drivers/remoteproc/remoteproc_core.c | 7 +-
> drivers/remoteproc/remoteproc_coredump.c | 8 +-
> drivers/remoteproc/remoteproc_debugfs.c | 2 +-
> drivers/remoteproc/remoteproc_elf_loader.c | 21 +-
> drivers/remoteproc/remoteproc_internal.h | 2 +-
> drivers/remoteproc/st_slim_rproc.c | 2 +-
> drivers/remoteproc/ti_k3_dsp_remoteproc.c | 2 +-
> drivers/remoteproc/ti_k3_r5_remoteproc.c | 2 +-
> drivers/remoteproc/wkup_m3_rproc.c | 2 +-
> include/linux/remoteproc.h | 4 +-
> 20 files changed, 298 insertions(+), 35 deletions(-)
>
> --
> 2.28.0