mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH master 1/2] dma: fix fixup warning for SoCs without /soc node
@ 2025-01-16 14:11 Ahmad Fatoum
  2025-01-16 14:11 ` [PATCH master 2/2] kbuild: remove stale references to README Ahmad Fatoum
  2025-01-21  8:22 ` [PATCH master 1/2] dma: fix fixup warning for SoCs without /soc node Sascha Hauer
  0 siblings, 2 replies; 3+ messages in thread
From: Ahmad Fatoum @ 2025-01-16 14:11 UTC (permalink / raw)
  To: barebox; +Cc: Ahmad Fatoum

For SoCs without a /soc node, any DMA coherency fixups happen at the
device tree root. The root's full name is an empty string in barebox, so
this expectedly fails.

Handle this case specially.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 drivers/dma/of_fixups.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/dma/of_fixups.c b/drivers/dma/of_fixups.c
index 084ab94cc71c..7377c508cfda 100644
--- a/drivers/dma/of_fixups.c
+++ b/drivers/dma/of_fixups.c
@@ -16,7 +16,8 @@ static int of_dma_coherent_fixup(struct device_node *root, void *data)
 	else
 		coherency = DEV_DMA_COHERENCE_DEFAULT;
 
-	soc_kernel = of_find_node_by_path_from(root, soc_bb->full_name);
+	soc_kernel = of_find_node_by_path_from(root,
+		       *soc_bb->full_name ? soc_bb->full_name : "/");
 	if (!soc_kernel)
 		return -ENOENT;
 
-- 
2.39.5




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

end of thread, other threads:[~2025-01-21  8:22 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-01-16 14:11 [PATCH master 1/2] dma: fix fixup warning for SoCs without /soc node Ahmad Fatoum
2025-01-16 14:11 ` [PATCH master 2/2] kbuild: remove stale references to README Ahmad Fatoum
2025-01-21  8:22 ` [PATCH master 1/2] dma: fix fixup warning for SoCs without /soc node Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox