summaryrefslogtreecommitdiffstats
path: root/drivers/remoteproc/imx_rproc.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2022-01-18 08:32:34 +0100
committerLinus Torvalds <torvalds@linux-foundation.org>2022-01-18 08:32:34 +0100
commit46a10fc3a2beddd79dafc3cd800f14bde0844387 (patch)
treef2d6d51d5117feeb3053ba2b6dd1203ffa5219e0 /drivers/remoteproc/imx_rproc.c
parentMerge tag 'rpmsg-v5.17' of git://git.kernel.org/pub/scm/linux/kernel/git/remo... (diff)
parentremoteproc: stm32: Improve crash recovery time (diff)
downloadlinux-46a10fc3a2beddd79dafc3cd800f14bde0844387.tar.xz
linux-46a10fc3a2beddd79dafc3cd800f14bde0844387.zip
Merge tag 'rproc-v5.17' of git://git.kernel.org/pub/scm/linux/kernel/git/remoteproc/linux
Pull remoteproc updates from Bjorn Andersson: "This introduces support for controlling the Cortex R7 co-processor in Renesas Gen3, support for R5F clusters and C71x DSPs on TI J721S2 and compute, audio and modem subsystems on Qualcomm SM6350. It fixes a couple of sparse errors related to memcpy_to/fromio and corrects the kerneldoc spelling of "Return:". The stm32 driver no longer attempts to communicate with the remote after the firmware has crashed" * tag 'rproc-v5.17' of git://git.kernel.org/pub/scm/linux/kernel/git/remoteproc/linux: (22 commits) remoteproc: stm32: Improve crash recovery time remoteproc: rcar_rproc: Remove trailing semicolon remoteproc: rcar_rproc: Fix pm_runtime_get_sync error check remoteproc: qcom: pas: Add SM6350 CDSP support remoteproc: qcom: pas: Add SM6350 ADSP support remoteproc: qcom: pas: Add SM6350 MPSS support dt-bindings: remoteproc: qcom: pas: Add SM6350 adsp, cdsp & mpss remoteproc: qcom: pas: Add missing power-domain "mxc" for CDSP remoteproc: imx_rproc: correct firmware reload remoteproc: qcom: pil_info: Don't memcpy_toio more than is provided remoteproc: Add Renesas rcar driver dt-bindings: remoteproc: Add Renesas R-Car remoteproc: Fix remaining wrong return formatting in documentation MAINTAINERS: Removing Ohad from remoteproc/rpmsg maintenance remoteproc: ingenic: Request IRQ disabled remoteproc: k3-r5: Extend support for R5F clusters on J721S2 SoCs remoteproc: k3-dsp: Extend support for C71x DSPs on J721S2 SoCs dt-bindings: remoteproc: k3-dsp: Update bindings for J721S2 SoCs dt-bindings: remoteproc: k3-r5f: Update bindings for J721S2 SoCs remoteproc: coredump: Correct argument 2 type for memcpy_fromio ...
Diffstat (limited to 'drivers/remoteproc/imx_rproc.c')
-rw-r--r--drivers/remoteproc/imx_rproc.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/remoteproc/imx_rproc.c b/drivers/remoteproc/imx_rproc.c
index ff8170dbbc3c..7a096f1891e6 100644
--- a/drivers/remoteproc/imx_rproc.c
+++ b/drivers/remoteproc/imx_rproc.c
@@ -34,7 +34,8 @@
#define IMX7D_M4_START (IMX7D_ENABLE_M4 | IMX7D_SW_M4P_RST \
| IMX7D_SW_M4C_RST)
-#define IMX7D_M4_STOP IMX7D_SW_M4C_NON_SCLR_RST
+#define IMX7D_M4_STOP (IMX7D_ENABLE_M4 | IMX7D_SW_M4C_RST | \
+ IMX7D_SW_M4C_NON_SCLR_RST)
/* Address: 0x020D8000 */
#define IMX6SX_SRC_SCR 0x00
@@ -45,7 +46,8 @@
#define IMX6SX_M4_START (IMX6SX_ENABLE_M4 | IMX6SX_SW_M4P_RST \
| IMX6SX_SW_M4C_RST)
-#define IMX6SX_M4_STOP IMX6SX_SW_M4C_NON_SCLR_RST
+#define IMX6SX_M4_STOP (IMX6SX_ENABLE_M4 | IMX6SX_SW_M4C_RST | \
+ IMX6SX_SW_M4C_NON_SCLR_RST)
#define IMX6SX_M4_RST_MASK (IMX6SX_ENABLE_M4 | IMX6SX_SW_M4P_RST \
| IMX6SX_SW_M4C_NON_SCLR_RST \
| IMX6SX_SW_M4C_RST)
@@ -684,7 +686,7 @@ static int imx_rproc_detect_mode(struct imx_rproc *priv)
return ret;
}
- if (!(val & dcfg->src_stop))
+ if ((val & dcfg->src_mask) != dcfg->src_stop)
priv->rproc->state = RPROC_DETACHED;
return 0;
@@ -804,6 +806,7 @@ static int imx_rproc_remove(struct platform_device *pdev)
clk_disable_unprepare(priv->clk);
rproc_del(rproc);
imx_rproc_free_mbox(rproc);
+ destroy_workqueue(priv->workqueue);
rproc_free(rproc);
return 0;