summaryrefslogtreecommitdiff
path: root/util/flashrom/flash.h
diff options
context:
space:
mode:
authorPeter Stuge <peter@stuge.se>2008-06-18 02:08:40 +0000
committerPeter Stuge <peter@stuge.se>2008-06-18 02:08:40 +0000
commit646eb245e6fd4f974a0dd3d1e57a1871cc7fb3c5 (patch)
tree82657e953506b5437bff4e0ed80e41ebf9d05958 /util/flashrom/flash.h
parent01441bd5cfee375c3170da0a34433e176b1796b3 (diff)
flashrom: Force read unknown flash chips
When flash chip detection fails, it is still useful and possible to read the flash chip contents. If no flash chip is found in normal probes and the -f -r -c CHIPNAME options are given, a successful probe for the specified chip is forced, and then flashrom reads the flash chip using either the read function for the specified chip, or if there is none, a simple memcpy(). The patch also moves the global variable int force in flashrom.c into main() and passes it as a parameter to layout.c:show_id(), which was the only other function that used the variable. This is needed to avoid confusion with the new parameter int force which is added to flashrom.c:probe_flash() and used to force probe success for the chip named in char *chip_to_probe. Signed-off-by: Peter Stuge <peter@stuge.se> Acked-by: Ward Vandewege <ward@gnu.org> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3367 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'util/flashrom/flash.h')
-rw-r--r--util/flashrom/flash.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/util/flashrom/flash.h b/util/flashrom/flash.h
index b7655555d3..17392ecbf0 100644
--- a/util/flashrom/flash.h
+++ b/util/flashrom/flash.h
@@ -394,7 +394,7 @@ extern int verbose;
int map_flash_registers(struct flashchip *flash);
/* layout.c */
-int show_id(uint8_t *bios, int size);
+int show_id(uint8_t *bios, int size, int force);
int read_romlayout(char *name);
int find_romentry(char *name);
int handle_romentries(uint8_t *buffer, uint8_t *content);