2006-11-20 21:32:35 +01:00
|
|
|
-------------------------------------------------------------------------------
|
|
|
|
Flashrom README
|
|
|
|
-------------------------------------------------------------------------------
|
2003-10-25 19:01:29 +02:00
|
|
|
|
2008-01-18 18:48:51 +01:00
|
|
|
Flashrom is a universal flash programming utility for DIP, PLCC, or SPI
|
|
|
|
flash ROM chips. It can be used to flash BIOS/coreboot/firmware images.
|
|
|
|
|
|
|
|
(see http://coreboot.org for details on coreboot)
|
|
|
|
|
2006-11-20 21:32:35 +01:00
|
|
|
|
|
|
|
Build Requirements
|
2005-12-01 11:51:08 +01:00
|
|
|
------------------
|
|
|
|
|
2008-06-22 20:50:25 +02:00
|
|
|
To build the flashrom utility you need to install the following packages:
|
2005-12-01 11:51:08 +01:00
|
|
|
|
|
|
|
* pciutils
|
2008-06-22 20:50:25 +02:00
|
|
|
* pciutils-devel / pciutils-dev / libpci-dev
|
2006-12-20 15:53:22 +01:00
|
|
|
* zlib-devel / zlib1g-dev
|
2005-12-01 11:51:08 +01:00
|
|
|
|
|
|
|
|
2006-11-20 21:32:35 +01:00
|
|
|
Usage
|
2005-12-01 11:51:08 +01:00
|
|
|
-----
|
|
|
|
|
2007-10-18 02:29:05 +02:00
|
|
|
$ flashrom [-rwvEVfh] [-c chipname] [-s exclude_start] [-e exclude_end]
|
2008-01-27 17:21:21 +01:00
|
|
|
[-m [vendor:]part] [-l file.layout] [-i imagename] [file]
|
|
|
|
-r | --read: read flash and save into file
|
|
|
|
-w | --write: write file into flash (default when
|
|
|
|
file is specified)
|
|
|
|
-v | --verify: verify flash against file
|
|
|
|
-E | --erase: erase flash device
|
|
|
|
-V | --verbose: more verbose output
|
|
|
|
-c | --chip <chipname>: probe only for specified flash chip
|
|
|
|
-s | --estart <addr>: exclude start position
|
|
|
|
-e | --eend <addr>: exclude end postion
|
|
|
|
-m | --mainboard <[vendor:]part>: override mainboard settings
|
|
|
|
-f | --force: force write without checking image
|
|
|
|
-l | --layout <file.layout>: read rom layout from file
|
|
|
|
-i | --image <name>: only flash image name from flash layout
|
2003-10-25 19:01:29 +02:00
|
|
|
|
2005-11-26 22:55:36 +01:00
|
|
|
If no file is specified, then all that happens
|
|
|
|
is that flash info is dumped and the flash chip is set to writable.
|
2003-10-25 19:01:29 +02:00
|
|
|
|
|
|
|
|
2008-01-18 16:33:10 +01:00
|
|
|
coreboot Table and Mainboard Identification
|
2005-11-26 22:55:36 +01:00
|
|
|
--------------------------------------------
|
|
|
|
|
2008-01-18 16:33:10 +01:00
|
|
|
Flashrom reads the coreboot table to determine the current mainboard
|
|
|
|
(parse DMI as well in future?). If no coreboot table could be read
|
2006-11-20 21:32:35 +01:00
|
|
|
or if you want to override these values, you can specify -m, e.g.:
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2008-06-22 20:50:25 +02:00
|
|
|
$ flashrom -w --mainboard AGAMI:ARUMA agami_aruma.rom
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2008-06-22 20:50:25 +02:00
|
|
|
See the 'Supported mainboards' section in the output of 'flashrom -L' for
|
|
|
|
a list of boards which require the specification of the board name, if no
|
|
|
|
coreboot table is found.
|
2007-10-18 02:29:05 +02:00
|
|
|
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2006-11-20 21:32:35 +01:00
|
|
|
ROM Layout Support
|
2005-11-26 22:55:36 +01:00
|
|
|
------------------
|
|
|
|
|
2008-01-18 18:48:51 +01:00
|
|
|
Flashrom supports ROM layouts. This allows you to flash certain parts of
|
2006-11-20 21:32:35 +01:00
|
|
|
the flash chip only. A ROM layout file looks like follows:
|
2005-11-26 22:55:36 +01:00
|
|
|
|
|
|
|
00000000:00008fff gfxrom
|
|
|
|
00009000:0003ffff normal
|
|
|
|
00040000:0007ffff fallback
|
|
|
|
|
|
|
|
i.e.:
|
|
|
|
startaddr:endaddr name
|
|
|
|
|
2007-10-18 02:29:05 +02:00
|
|
|
All addresses are offsets within the file, not absolute addresses!
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2006-11-20 21:32:35 +01:00
|
|
|
If you only want to update the normal image in a ROM you can say:
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2007-10-18 02:29:05 +02:00
|
|
|
flashrom -w --layout rom.layout --image normal agami_aruma.rom
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2006-11-20 21:32:35 +01:00
|
|
|
To update normal and fallback but leave the VGA BIOS alone, say:
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2007-10-18 02:29:05 +02:00
|
|
|
flashrom -w -l rom.layout -i normal -i fallback agami_aruma.rom
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2006-11-20 21:32:35 +01:00
|
|
|
Currently overlapping sections are not supported.
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2006-11-20 21:32:35 +01:00
|
|
|
ROM layouts should replace the -s and -e option since they are more
|
|
|
|
flexible and they should lead to a ROM update file format with the
|
2007-10-18 02:29:05 +02:00
|
|
|
ROM layout and the ROM image in one file (cpio, zip or something?).
|
2005-11-26 22:55:36 +01:00
|
|
|
|
|
|
|
|
2007-10-18 02:29:05 +02:00
|
|
|
Disk on Chip support
|
|
|
|
--------------------
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2008-06-22 19:54:03 +02:00
|
|
|
Disk on Chip support was removed from flashrom in r3382. It had already
|
2008-06-22 19:06:41 +02:00
|
|
|
been disabled by default in flashrom for several years because the code
|
|
|
|
was considered unstable and incomplete. The products intended to work
|
|
|
|
have been End-Of-Lifed by the manufacturer for a long time.
|
2005-11-26 22:55:36 +01:00
|
|
|
|
2003-10-25 19:01:29 +02:00
|
|
|
|
2008-06-22 20:50:25 +02:00
|
|
|
Supported Flash Chips / Chipsets / Mainboards
|
|
|
|
---------------------------------------------
|
|
|
|
|
|
|
|
Please check the output of 'flashrom -L' for the list of supported
|
|
|
|
flash chips, chipsets/southbridges, and mainboards.
|
|
|
|
|
|
|
|
See also http://coreboot.org/Flashrom for more details.
|
2006-12-04 09:15:47 +01:00
|
|
|
|