1
0
Fork 0
remarkable-uboot/tools
Jon Povey 735eb0f0e6 tools/env: fix redundant env flag comparison
This fixes two bugs with comparison of redundant environment flags on
read.

flag0 and flag1 in fw_env_open() were declared signed instead of
unsigned char breaking BOOLEAN mode "== 0xFF" tests and in INCREMENTAL
mode the wrong environment would be chosen where the flag values are
127 and 128 (either way round). With both flags over 128, both signs
flipped and the logic worked by happy accident.

Also there was a logic bug in the INCREMENTAL test (after signedness was
fixed) in the case flag0=0, flag1=255, env 1 would be incorrectly chosen.

Fix both of these.

Signed-off-by: Jon Povey <jon.povey@racelogic.co.uk>
2011-04-21 00:25:08 +02:00
..
bddb Update Hymod Board Database PHP code in "tools" directory 2005-08-12 23:27:18 +02:00
easylogo easylogo: add support for 16-bit RGB565 2010-01-18 00:21:05 +01:00
env tools/env: fix redundant env flag comparison 2011-04-21 00:25:08 +02:00
gdb makefiles: fixes for building build tools 2009-12-02 22:58:46 +01:00
imls tools/imls: fix comment in Makefile 2010-10-12 21:49:28 +02:00
logos logos: add Freescale logo 2010-09-21 22:44:53 +02:00
scripts make-asm-offsets: fix sed script 2010-10-27 20:16:52 +02:00
updater cmd_usage(): simplify return code handling 2010-07-24 20:43:57 +02:00
.gitignore tools: update .gitignore 2010-09-19 19:29:49 +02:00
Makefile Makefile: move include for config.mk up 2010-11-14 23:53:00 +01:00
bin2header.c Add 'license' command to U-Boot command line 2008-08-18 23:21:49 +02:00
bmp_logo.c compiler.h: unify system ifdef cruft here 2009-07-19 21:41:46 +02:00
default_image.c tools: mkimage: split code into core, default and FIT image specific 2009-09-10 22:58:48 +02:00
envcrc.c Revert "env: only build env_embedded and envcrc when needed" 2009-10-27 20:46:31 +01:00
fdt_host.h [new uImage] Add libfdt support to mkimage 2008-02-29 16:00:24 +01:00
fit_image.c tools/fit_image.c: Remove unused fit_set_header() 2009-12-05 01:12:45 +01:00
gen_eth_addr.c gen_eth_addr: Use POSIX rand() and srand() 2009-04-04 01:09:56 +02:00
getline.c getline: split out for darwin systems 2010-01-26 00:07:13 +01:00
getline.h getline: split out for darwin systems 2010-01-26 00:07:13 +01:00
img2brec.sh Fix file permissions 2005-07-21 11:22:21 +02:00
img2srec.c img2srec: use standard types 2009-11-24 23:43:18 +01:00
imximage.c imximage: Add MX53 boot image support 2011-02-02 00:54:42 +01:00
imximage.h Drop config.h include in tools/imximage.h 2011-04-12 22:58:31 +02:00
inca-swap-bytes.c * Patch by Arun Dharankar, 4 Apr 2003: 2003-04-05 00:53:31 +00:00
jtagconsole Blackfin: jtagconsole: disable output processing 2010-07-25 15:17:23 -04:00
kwbimage.c Fix typo ("comand" instead of "command") 2011-01-19 00:07:22 +01:00
kwbimage.h mkimage: Add Kirkwood Boot Image support (kwbimage) 2009-09-10 22:58:48 +02:00
mingw_support.c getline: split out for darwin systems 2010-01-26 00:07:13 +01:00
mingw_support.h getline: split out for darwin systems 2010-01-26 00:07:13 +01:00
mkimage.c mkimage: add "-V" option to print version information 2011-04-12 22:58:33 +02:00
mkimage.h mkimage: Add Freescale imx Boot Image support (imximage) 2010-01-25 23:58:29 +01:00
mpc86x_clk.c * Patch by Anders Larsen, 18 Sep 2003: 2003-10-08 22:14:02 +00:00
ncb.c ncb: Check return value of write() 2009-04-28 01:16:46 +02:00
netconsole tools/netconsole: use ncb automatically if available 2009-09-15 22:55:45 +02:00
os_support.c getline: split out for darwin systems 2010-01-26 00:07:13 +01:00
os_support.h getline: split out for darwin systems 2010-01-26 00:07:13 +01:00
setlocalversion setlocalversion: add some more fallbacks for git describe 2010-09-21 21:33:16 +02:00
ubsha1.c ubsha1: drop unnecessary includes/prototypes 2010-01-21 22:59:29 +01:00