[PATCH] of: base.c: Use correct device-tree in of_add_initrd()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Otherwise only the internal DT is modified, not necessarily the one passed
to the kernel.

Signed-off-by: David Jander <david@xxxxxxxxxxx>
---
 drivers/of/base.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/of/base.c b/drivers/of/base.c
index 34a06c2..ce474be 100644
--- a/drivers/of/base.c
+++ b/drivers/of/base.c
@@ -1732,7 +1732,7 @@ int of_add_initrd(struct device_node *root, resource_size_t start,
 	struct device_node *chosen;
 	__be32 buf[2];
 
-	chosen = of_find_node_by_path("/chosen");
+	chosen = of_find_node_by_path_from(root, "/chosen");
 	if (!chosen)
 		return -EINVAL;
 
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux