From: Simon Glass Date: Mon, 19 Jun 2017 04:08:56 +0000 (-0600) Subject: dtoc: Use self._options instead of the global options X-Git-Tag: v2017.09-rc1~214^2~36 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=418355cbaa4dfe1a202538c1584f0b7b147f59c0;p=u-boot dtoc: Use self._options instead of the global options This class should use the options object passed to it rather than finding the global one. Fix it. Signed-off-by: Simon Glass --- diff --git a/tools/dtoc/dtoc.py b/tools/dtoc/dtoc.py index c0ab13ad34..056f5157c9 100755 --- a/tools/dtoc/dtoc.py +++ b/tools/dtoc/dtoc.py @@ -177,7 +177,7 @@ class DtbPlatdata: for node in root.subnodes: if 'compatible' in node.props: status = node.props.get('status') - if (not options.include_disabled and not status or + if (not self._options.include_disabled and not status or status.value != 'disabled'): self._valid_nodes.append(node) phandle_prop = node.props.get('phandle') @@ -203,7 +203,7 @@ class DtbPlatdata: for node in self.fdt.GetRoot().subnodes: if 'compatible' in node.props: status = node.props.get('status') - if (not options.include_disabled and not status or + if (not self._options.include_disabled and not status or status.value != 'disabled'): node_list.append(node) phandle_prop = node.props.get('phandle')