dts/extract_dts_includes.py: Quote strings values
If the value of the property is a string quote it on output. This lets us use things like label properties that will have values of strings. Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
parent
7b71d88ddd
commit
21ef8a6acc
1 changed files with 4 additions and 0 deletions
|
@ -380,10 +380,14 @@ def extract_single(node_address, yaml, prop, key, prefix, defs, def_label):
|
|||
for i, p in enumerate(prop):
|
||||
k = convert_string_to_label(key).upper()
|
||||
label = def_label + '_' + k
|
||||
if isinstance(p, str):
|
||||
p = "\"" + p + "\""
|
||||
prop_def[label + '_' + str(i)] = p
|
||||
else:
|
||||
k = convert_string_to_label(key).upper()
|
||||
label = def_label + '_' + k
|
||||
if isinstance(prop, str):
|
||||
prop = "\"" + prop + "\""
|
||||
prop_def[label] = prop
|
||||
|
||||
if node_address in defs:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue