diff options
author | Simon Glass <sjg@chromium.org> | 2020-12-28 20:34:50 -0700 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2021-01-05 12:26:35 -0700 |
commit | 192c111cfce0684fa1cbbd4a4bd3df03720ef7a6 (patch) | |
tree | 05ad27a45dc1fce7b6821a9b763bd91c09cd2e35 /tools/dtoc/dtb_platdata.py | |
parent | de846cbb307486a1533dcf4d5c28568412149ddb (diff) | |
download | u-boot-192c111cfce0684fa1cbbd4a4bd3df03720ef7a6.zip u-boot-192c111cfce0684fa1cbbd4a4bd3df03720ef7a6.tar.gz u-boot-192c111cfce0684fa1cbbd4a4bd3df03720ef7a6.tar.bz2 |
dtoc: Allow providing a directory to write files to
At present dtoc writes only a single file on each invocation. U-Boot
writes the two files it needs by separate invocations of dtoc. Since dtoc
now scans all U-Boot driver source, this is fairly slow (about 1 second
per file).
It would be better if dtoc could write all the files at once.
In preparation for this, add a way to specify an output directory for the
files.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'tools/dtoc/dtb_platdata.py')
-rw-r--r-- | tools/dtoc/dtb_platdata.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/tools/dtoc/dtb_platdata.py b/tools/dtoc/dtb_platdata.py index 118b1a5..62a65d6 100644 --- a/tools/dtoc/dtb_platdata.py +++ b/tools/dtoc/dtb_platdata.py @@ -757,8 +757,9 @@ class DtbPlatdata(): self.out(''.join(self.get_buf())) -def run_steps(args, dtb_file, include_disabled, output, warning_disabled=False, - drivers_additional=None): + +def run_steps(args, dtb_file, include_disabled, output, output_dirs, + warning_disabled=False, drivers_additional=None): """Run all the steps of the dtoc tool Args: @@ -766,6 +767,9 @@ def run_steps(args, dtb_file, include_disabled, output, warning_disabled=False, dtb_file (str): Filename of dtb file to process include_disabled (bool): True to include disabled nodes output (str): Name of output file (None for stdout) + output_dirs (tuple of str): + Directory to put C output files + Directory to put H output files warning_disabled (bool): True to avoid showing warnings about missing drivers drivers_additional (list): List of additional drivers to use during |