[coreboot] r3903 - trunk/util/flashrom
Peter Stuge
peter at stuge.se
Mon Jan 26 02:39:14 CET 2009
svn at coreboot.org wrote:
> flashrom: Abstract mmap() in physmap.c and only open /dev/mem on the first physmap() call.
..
> +++ trunk/util/flashrom/cbtable.c 2009-01-26 01:10:48 UTC (rev 3903)
..
> - if (low_1MB == MAP_FAILED) {
> - perror("Can't mmap memory using " MEM_DEV);
> - mmap_errmsg();
> - exit(-2);
> - }
> + low_1MB = physmap("low megabyte", 0x0, 1024*1024);
Note that in this one instance, flashrom will now exit(1) instead of
exit(-2) on failure. No other exit value has been changed in this
series of commits.
I would now like to suggest a change of the exit() codes in physmap.c
to 2 (for open) and 3 (for mmap) because 1 is already used all over
the flashrom codebase for every type of error. Anyone against?
//Peter
More information about the coreboot
mailing list