diff options
author | Arthur Heymans <arthur@aheymans.xyz> | 2018-01-10 12:48:16 +0100 |
---|---|---|
committer | Nico Huber <nico.h@gmx.de> | 2018-10-23 21:15:05 +0000 |
commit | c82900b661420989856a969cd9edf27410b758eb (patch) | |
tree | 2f0ac2c60530769830ee6386047712fb46cdccd0 /flashrom.8.tmpl | |
parent | 4acc3f3a8990cda15f04e5eabf028c5cda0d6619 (diff) | |
download | flashrom-c82900b661420989856a969cd9edf27410b758eb.tar.gz flashrom-c82900b661420989856a969cd9edf27410b758eb.tar.bz2 flashrom-c82900b661420989856a969cd9edf27410b758eb.zip |
Add support to get layout from fmap (e.g. coreboot rom)
Flashmap, or simply fmap, is a binary data format for describing
region offsets, sizes, and certain attributes and is widely used by
coreboot. This patch adds support for the fmap data format version 1.1
and adds --fmap and --fmap-file arguments.
Using --fmap will make flashrom to search the ROM content for fmap
data. Using --fmap-file will make flashrom search a supplied file
for fmap data.
An example of how to update the COREBOOT region of a ROM:
flashrom -p programmer --fmap -w coreboot.rom -i COREBOOT
flashrom -p programmer --fmap-file coreboot.rom -w coreboot.rom -i COREBOOT
The fmap functions are mostly copied from cbfstool.
Currently it is made mutually exclusive with other layout options until
we are more clever about this input.
Change-Id: I0e7fad38ed79a84d41358e1f175c36d255786c12
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Signed-off-by: David Hendricks <dhendricks@fb.com>
Reviewed-on: https://review.coreboot.org/23203
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Tested-by: David Hendricks <david.hendricks@gmail.com>
Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Diffstat (limited to 'flashrom.8.tmpl')
-rw-r--r-- | flashrom.8.tmpl | 38 |
1 files changed, 32 insertions, 6 deletions
diff --git a/flashrom.8.tmpl b/flashrom.8.tmpl index f882dc67..c557af74 100644 --- a/flashrom.8.tmpl +++ b/flashrom.8.tmpl @@ -44,12 +44,10 @@ .SH NAME flashrom \- detect, read, write, verify and erase flash chips .SH SYNOPSIS -.B flashrom \fR[\fB\-h\fR|\fB\-R\fR|\fB\-L\fR|\fB\-z\fR|\ -\fB\-p\fR <programmername>[:<parameters>] - [\fB\-E\fR|\fB\-r\fR <file>|\fB\-w\fR <file>|\fB\-v\fR <file>] \ -[\fB\-c\fR <chipname>] - [(\fB\-l\fR <file>|\fB\-\-ifd\fR) [\fB\-i\fR <image>]] \ -[\fB\-n\fR] [\fB\-N\fR] [\fB\-f\fR]] +.B flashrom \fR[\fB\-h\fR|\fB\-R\fR|\fB\-L\fR|\fB\-z\fR|\fB\-p\fR <programmername>[:<parameters>] + [\fB\-E\fR|\fB\-r\fR <file>|\fB\-w\fR <file>|\fB\-v\fR <file>] [\fB\-c\fR <chipname>] + [(\fB\-l\fR <file>|\fB\-\-ifd|\fB \-\-fmap\fR|\fB\-\-fmap-file\fR <file>) [\fB\-i\fR <image>]] + [\fB\-n\fR] [\fB\-N\fR] [\fB\-f\fR]] [\fB\-V\fR[\fBV\fR[\fBV\fR]]] [\fB-o\fR <logfile>] .SH DESCRIPTION .B flashrom @@ -195,6 +193,34 @@ To update only the images named .sp Overlapping sections are not supported. .TP +.B "\-\-fmap" +Read layout from fmap in flash chip. +.sp +flashrom supports the fmap binary format which is commonly used by coreboot +for partitioning a flash chip. The on-chip fmap will be read and used to generate +the layout. +.sp +If you only want to update the +.BR "COREBOOT" +region defined in the fmap, run +.sp +.B " flashrom -p prog \-\-fmap \-\-image COREBOOT \-w some.rom" +.TP +.B "\-\-fmap-file <file>" +Read layout from a +.BR <file> +containing binary fmap (e.g. coreboot roms). +.sp +flashrom supports the fmap binary format which is commonly used by coreboot +for partitioning a flash chip. The fmap in the specified file will be read and +used to generate the layout. +.sp +If you only want to update the +.BR "COREBOOT" +region defined in the binary fmap file, run +.sp +.B " flashrom \-p prog \-\-fmap-file some.rom \-\-image COREBOOT \-w some.rom" +.TP .B "\-\-ifd" Read ROM layout from Intel Firmware Descriptor. .sp |