diff options
author | Stephen Warren <swarren@nvidia.com> | 2013-09-19 22:15:13 +1000 |
---|---|---|
committer | David Gibson <david@gibson.dropbear.id.au> | 2013-09-20 08:49:31 +1000 |
commit | b290428d711f5a38073ed993a63e6bbf1e6af66d (patch) | |
tree | 48a25d8053beda82a7bc1373483b50e477fee46f /tests/trees.S | |
parent | 9476db68b6470ec645d2ee61c263e127147f5073 (diff) | |
download | dtc-b290428d711f5a38073ed993a63e6bbf1e6af66d.zip dtc-b290428d711f5a38073ed993a63e6bbf1e6af66d.tar.gz dtc-b290428d711f5a38073ed993a63e6bbf1e6af66d.tar.bz2 |
Ensure all tests have matching reg and unit address
ePAPR 1.1 section 2.2.1.1 "Node Name Requirements" specifies that any
node that has a reg property must include a unit address in its name
with value matching the first entry in its reg property. Conversely, if
a node does not have a reg property, the node name must not include a
unit address.
Adjust all the dtc test-cases to conform to this rule.
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'tests/trees.S')
-rw-r--r-- | tests/trees.S | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/trees.S b/tests/trees.S index cae0187..2389cd3 100644 --- a/tests/trees.S +++ b/tests/trees.S @@ -92,9 +92,12 @@ test_tree1_struct: PROP_INT(test_tree1, prop_int, TEST_VALUE_1) PROP_INT64(test_tree1, prop_int64, TEST_VALUE64_1) PROP_STR(test_tree1, prop_str, TEST_STRING_1) + PROP_INT(test_tree1, address_cells, 1) + PROP_INT(test_tree1, size_cells, 0) BEGIN_NODE("subnode@1") PROP_STR(test_tree1, compatible, "subnode1") + PROP_INT(test_tree1, reg, 1) PROP_INT(test_tree1, prop_int, TEST_VALUE_1) BEGIN_NODE("subsubnode") @@ -108,10 +111,14 @@ test_tree1_struct: END_NODE BEGIN_NODE("subnode@2") + PROP_INT(test_tree1, reg, 2) PROP_INT(test_tree1, linux_phandle, PHANDLE_1) PROP_INT(test_tree1, prop_int, TEST_VALUE_2) + PROP_INT(test_tree1, address_cells, 1) + PROP_INT(test_tree1, size_cells, 0) BEGIN_NODE("subsubnode@0") + PROP_INT(test_tree1, reg, 0) PROP_INT(test_tree1, phandle, PHANDLE_2) PROP_STR(test_tree1, compatible, "subsubnode2\0subsubnode") PROP_INT(test_tree1, prop_int, TEST_VALUE_2) @@ -133,6 +140,9 @@ test_tree1_strings: STRING(test_tree1, prop_str, "prop-str") STRING(test_tree1, linux_phandle, "linux,phandle") STRING(test_tree1, phandle, "phandle") + STRING(test_tree1, reg, "reg") + STRING(test_tree1, address_cells, "#address-cells") + STRING(test_tree1, size_cells, "#size-cells") test_tree1_strings_end: test_tree1_end: |