
On Mon, Dec 07, 2015 at 06:01:54PM +0100, Marek Vasut wrote:
Seems 6ae6e160 broke creating multi and script type images and even building of mkimage itself. There are two problems with that patch.
First is that expression (!(x == 0) || !(x == 1)) is always true for unsigned int x. The expression must use AND (&&) not OR (||) to be correct.
Second is the coding which causes gcc 4.9.x and newer scream gruesome death and murder. The expression !x == 0 && !x == 1 is ambiguous and should instead be rewritten into (x != 0) && (x != 1) to be correct. The parenthesis are added for clarity.
Signed-off-by: Marek Vasut marex@denx.de Cc: Tom Rini trini@konsulko.com Cc: Philippe De Swert philippedeswert@gmail.com Cc: Simon Glass sjg@chromium.org
After rewording the commit message a bit (and talking with Marek on IRC about my reword), applied to u-boot/master, thanks!