summaryrefslogtreecommitdiffstats
path: root/tools/binman
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2019-07-08 14:25:32 -0600
committerSimon Glass <sjg@chromium.org>2019-07-24 12:54:08 -0700
commite430440232e455c0b670a3f5647fbab649e34f4b (patch)
treef5cbda86979a2fb88edbba8c9761fd56138eb358 /tools/binman
parentc073ced7a325b46dab14183af26e4b8bc3c4f3d0 (diff)
downloadu-boot-e430440232e455c0b670a3f5647fbab649e34f4b.tar.gz
u-boot-e430440232e455c0b670a3f5647fbab649e34f4b.tar.xz
u-boot-e430440232e455c0b670a3f5647fbab649e34f4b.zip
binman: Allow easy importing of entry modules
At present entry modules can only be accessed using Entry.Lookup() or Entry.Create(). Most of the time this is fine, but sometimes a module needs to provide constants or helper functions useful to other modules. It is easier in this case to use 'import'. Add an __init__ file to permit this. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'tools/binman')
-rw-r--r--tools/binman/entry.py2
-rw-r--r--tools/binman/etype/__init__.py0
2 files changed, 2 insertions, 0 deletions
diff --git a/tools/binman/entry.py b/tools/binman/entry.py
index 00bb1d190a..a04e149d96 100644
--- a/tools/binman/entry.py
+++ b/tools/binman/entry.py
@@ -513,6 +513,8 @@ features to produce new behaviours.
modules.remove('_testing')
missing = []
for name in modules:
+ if name.startswith('__'):
+ continue
module = Entry.Lookup(name, name)
docs = getattr(module, '__doc__')
if test_missing == name:
diff --git a/tools/binman/etype/__init__.py b/tools/binman/etype/__init__.py
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/tools/binman/etype/__init__.py