summaryrefslogtreecommitdiffstats
path: root/82802ab.c
diff options
context:
space:
mode:
authorStefan Reinauer <stepan@coresystems.de>2007-04-06 11:58:03 +0000
committerStefan Reinauer <stefan.reinauer@coreboot.org>2007-04-06 11:58:03 +0000
commit7038564346f660ce043d7942398f3e8a3a2db7ad (patch)
tree2d6573bc465284fa3fc57fe2afaa8f7b1dabd1ad /82802ab.c
parent8e3a600123110d47076926cb8ee7c68195658f20 (diff)
downloadast2050-flashrom-7038564346f660ce043d7942398f3e8a3a2db7ad.zip
ast2050-flashrom-7038564346f660ce043d7942398f3e8a3a2db7ad.tar.gz
Trivial (cosmetic) cleanup
* Only open /dev/mem once and do it early. * Drop extern for function prototypes. * Minimize ts5300 impact in probe_flash() This cleanup will making ICH7 SPI support quite some easier. Corresponding to flashrom svn r100 and coreboot v2 svn r2585. Signed-off-by: Stefan Reinauer <stepan@coresystems.de> Acked-by: Stefan Reinauer <stepan@coresystems.de>
Diffstat (limited to '82802ab.c')
-rw-r--r--82802ab.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/82802ab.c b/82802ab.c
index 99776a1..c0f60ef 100644
--- a/82802ab.c
+++ b/82802ab.c
@@ -79,7 +79,7 @@ int probe_82802ab(struct flashchip *flash)
size_t size = flash->total_size * 1024;
// we need to mmap the write-protect space.
bios = mmap(0, size, PROT_WRITE | PROT_READ, MAP_SHARED,
- flash->fd_mem, (off_t) (0 - 0x400000 - size));
+ fd_mem, (off_t) (0 - 0x400000 - size));
if (bios == MAP_FAILED) {
// it's this part but we can't map it ...
perror("Error MMAP memory using " MEM_DEV );
OpenPOWER on IntegriCloud