[PATCH master 1/2] dma: fix fixup warning for SoCs without /soc node
Ahmad Fatoum
a.fatoum at pengutronix.de
Thu Jan 16 06:11:47 PST 2025
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 at 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
More information about the barebox
mailing list