scripts/dts/edtlib.py: error check enum
Make sure 'enum' is a list in the binding. Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
parent
62bf267bb2
commit
cd72ce122b
|
@ -1253,6 +1253,10 @@ def _check_binding(binding, binding_path):
|
|||
_err("missing, malformed, or empty 'description' for '{}' in "
|
||||
"'properties' in {}".format(prop_name, binding_path))
|
||||
|
||||
if "enum" in options and not isinstance(options["enum"], list):
|
||||
_err("enum in {} for property '{}' is not a list"
|
||||
.format(binding_path, prop_name))
|
||||
|
||||
|
||||
def _translate(addr, node):
|
||||
# Recursively translates 'addr' on 'node' to the address space(s) of its
|
||||
|
|
Loading…
Reference in New Issue