linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] remoteproc: imx_rproc: Use strstarts for "rsc-table" check
@ 2025-12-08 23:33 Shenwei Wang
  2025-12-09 12:36 ` Daniel Baluta
                   ` (6 more replies)
  0 siblings, 7 replies; 10+ messages in thread
From: Shenwei Wang @ 2025-12-08 23:33 UTC (permalink / raw)
  To: Bjorn Andersson, Mathieu Poirier, Shawn Guo, Sascha Hauer
  Cc: Pengutronix Kernel Team, Fabio Estevam, linux-remoteproc, imx,
	linux-arm-kernel, linux-kernel, linux-imx, Shenwei Wang

The resource name may include an address suffix, for example:
rsc-table@1fff8000.

To handle such cases, use strstarts() instead of strcmp() when checking
for "rsc-table".

Signed-off-by: Shenwei Wang <shenwei.wang@nxp.com>
---
 drivers/remoteproc/imx_rproc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/remoteproc/imx_rproc.c b/drivers/remoteproc/imx_rproc.c
index 3be8790c14a2..33f21ab24c92 100644
--- a/drivers/remoteproc/imx_rproc.c
+++ b/drivers/remoteproc/imx_rproc.c
@@ -694,7 +694,7 @@ static int imx_rproc_addr_init(struct imx_rproc *priv,
 		}
 		priv->mem[b].sys_addr = res.start;
 		priv->mem[b].size = resource_size(&res);
-		if (!strcmp(res.name, "rsc-table"))
+		if (strstarts(res.name, "rsc-table"))
 			priv->rsc_table = priv->mem[b].cpu_addr;
 		b++;
 	}
-- 
2.43.0



^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2025-12-16 20:53 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-12-08 23:33 [PATCH] remoteproc: imx_rproc: Use strstarts for "rsc-table" check Shenwei Wang
2025-12-09 12:36 ` Daniel Baluta
2025-12-09 16:05 ` Frank Li
2025-12-11  6:20 ` Zhongqiu Han
2025-12-15  2:19 ` Mathieu Poirier
2025-12-15 11:11   ` Peng Fan
2025-12-15 10:15 ` Peng Fan
2025-12-15 10:20   ` Peng Fan
2025-12-15 11:13 ` Peng Fan
2025-12-16 20:53 ` Mathieu Poirier

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).