diff options
author | Tom Rini <trini@konsulko.com> | 2020-02-25 13:59:21 -0500 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2020-02-25 13:59:21 -0500 |
commit | 133276f14acfbad4268acd19a70d3cda0a60b5e3 (patch) | |
tree | f8ecc6c9ebf0a000cefe709ec1ab9b1358956a20 /tools | |
parent | c2358258c2ed3e964138eb7b66dbef5d6ef232ae (diff) | |
parent | be06032eb00b6b9315049bc5585e1f51e29c9179 (diff) |
Merge branch '2020-02-25-master-imports'
- Assorted fixes
Diffstat (limited to 'tools')
-rw-r--r-- | tools/image-host.c | 1 | ||||
-rwxr-xr-x | tools/moveconfig.py | 6 |
2 files changed, 4 insertions, 3 deletions
diff --git a/tools/image-host.c b/tools/image-host.c index 9483561bfa..76a361b9d6 100644 --- a/tools/image-host.c +++ b/tools/image-host.c @@ -12,7 +12,6 @@ #include <bootm.h> #include <image.h> #include <version.h> -#include <uboot_aes.h> /** * fit_set_hash_value - set hash value in requested has node diff --git a/tools/moveconfig.py b/tools/moveconfig.py index 36160a3977..d8bf7fd071 100755 --- a/tools/moveconfig.py +++ b/tools/moveconfig.py @@ -295,6 +295,7 @@ To see the complete list of supported options, run """ +import asteval import collections import copy import difflib @@ -808,10 +809,11 @@ def try_expand(line): return line try: + aeval = asteval.Interpreter( usersyms=SIZES, minimal=True ) cfg, val = re.split("=", line) val= val.strip('\"') if re.search("[*+-/]|<<|SZ_+|\(([^\)]+)\)", val): - newval = hex(eval(val, SIZES)) + newval = hex(aeval(val)) print("\tExpanded expression %s to %s" % (val, newval)) return cfg+'='+newval except: @@ -1215,7 +1217,7 @@ class Slot: "Failed to process.\n") if self.options.verbose: self.log += color_text(self.options.color, COLOR_LIGHT_CYAN, - self.ps.stderr.read()) + self.ps.stderr.read().decode()) self.finish(False) def do_defconfig(self): |