[PATCH 1/2] of: partitions: Support new binding

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

 



The new binding recommends to put the partitions into a subnode
with compatible "fixed-partitions". Add support for this binding.

Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx>
---
 drivers/of/partition.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/of/partition.c b/drivers/of/partition.c
index b6621f7..bdf5945 100644
--- a/drivers/of/partition.c
+++ b/drivers/of/partition.c
@@ -80,6 +80,13 @@ int of_parse_partitions(struct cdev *cdev, struct device_node *node)
 		return -EINVAL;
 
 	for_each_child_of_node(node, n) {
+		if (of_device_is_compatible(n, "fixed-partitions")) {
+			node = n;
+			break;
+		}
+	}
+
+	for_each_child_of_node(node, n) {
 		of_parse_partition(cdev, n);
 	}
 
-- 
2.10.1


_______________________________________________
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