summaryrefslogtreecommitdiffstats
path: root/layout.h
diff options
context:
space:
mode:
authorDaniel Campello <campello@chromium.org>2021-04-16 15:26:42 -0600
committerEdward O'Callaghan <quasisec@chromium.org>2021-05-02 23:45:43 +0000
commitce983bccaab450d358854494f15c2d8a1846d56b (patch)
tree79d41a980587c2a1ebe40b65f837edd16232d387 /layout.h
parent0969e43b3fae48c90aaf1df284560f6b76f84efd (diff)
downloadflashrom-ce983bccaab450d358854494f15c2d8a1846d56b.tar.gz
flashrom-ce983bccaab450d358854494f15c2d8a1846d56b.tar.bz2
flashrom-ce983bccaab450d358854494f15c2d8a1846d56b.zip
cli_classic.c: add -x option for do_extract()
This change introduces a new option to extract all layout regions to files with the name of each region (or with the provided filename via -i region:file). It is implemented by mutating the flash layout to include all regions and backfilling the entry->file with entry->name (replacing spaces with underscores) Signed-off-by: Daniel Campello <campello@chromium.org> Change-Id: I8c69223fa92cf5b50abe070f1ab9f19d3b42f6ff Reviewed-on: https://review.coreboot.org/c/flashrom/+/52450 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>
Diffstat (limited to 'layout.h')
-rw-r--r--layout.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/layout.h b/layout.h
index b11c4325d..327f5bf86 100644
--- a/layout.h
+++ b/layout.h
@@ -69,5 +69,6 @@ int process_include_args(struct flashrom_layout *l, const struct layout_include_
const struct romentry *layout_next_included_region(const struct flashrom_layout *, chipoff_t);
const struct romentry *layout_next_included(const struct flashrom_layout *, const struct romentry *);
int included_regions_overlap(const struct flashrom_layout *const flashrom_layout);
+void prepare_layout_for_extraction(struct flashrom_flashctx *flash);
#endif /* !__LAYOUT_H__ */