aboutsummaryrefslogtreecommitdiff
path: root/dtc-parser.y
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2007-12-05 10:43:50 +1100
committerJon Loeliger <jdl@freescale.com>2007-12-05 08:28:44 -0600
commitefbbef8e4f86f8043760f1e48b25ab2795ba3524 (patch)
tree78ab6f7d4509d31ce0f95da33d357e00e60a6d5e /dtc-parser.y
parent80c72a81cffdfde0965853d1ea834352b3e91f89 (diff)
downloaddtc-efbbef8e4f86f8043760f1e48b25ab2795ba3524.zip
dtc-efbbef8e4f86f8043760f1e48b25ab2795ba3524.tar.gz
dtc-efbbef8e4f86f8043760f1e48b25ab2795ba3524.tar.bz2
dtc: Implement path references
This patch extends dtc syntax to allow references (&label, or &{/full/path}) directly within property definitions, rather than inside a cell list. Such references are expanded to the full path of the referenced node, as a string, instead of to a phandle as references within cell lists are evaluated. A testcase is also included. Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'dtc-parser.y')
-rw-r--r--dtc-parser.y4
1 files changed, 4 insertions, 0 deletions
diff --git a/dtc-parser.y b/dtc-parser.y
index 43182fd..002ea7f 100644
--- a/dtc-parser.y
+++ b/dtc-parser.y
@@ -192,6 +192,10 @@ propdata:
{
$$ = data_merge($1, $3);
}
+ | propdataprefix DT_REF
+ {
+ $$ = data_add_marker($1, REF_PATH, $2);
+ }
| propdata DT_LABEL
{
$$ = data_add_marker($1, LABEL, $2);