dtoc: Process nodes to set up required properties

Add logic to assign property values to nodes as required by dtoc. The
references allow nodes to refer to each other in C code. The macros used
by dtoc are not yet defined in driver model. They will be added along
with the actual driver model implementation.

Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
Simon Glass
2021-02-03 06:01:00 -07:00
parent e525fea211
commit fd471e2ce1
3 changed files with 124 additions and 0 deletions

View File

@@ -188,6 +188,17 @@ class Scanner:
self._uclass = {}
self._structs = {}
def get_driver(self, name):
"""Get a driver given its name
Args:
name (str): Driver name
Returns:
Driver: Driver or None if not found
"""
return self._drivers.get(name)
def get_normalized_compat_name(self, node):
"""Get a node's normalized compat name