[U-Boot] [PATCH] mkimage: Fix generating multi and script images again
Tom Rini
trini at konsulko.com
Mon Dec 7 20:06:26 CET 2015
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 at denx.de>
> Cc: Tom Rini <trini at konsulko.com>
> Cc: Philippe De Swert <philippedeswert at gmail.com>
> Cc: Simon Glass <sjg at chromium.org>
After rewording the commit message a bit (and talking with Marek on IRC
about my reword), applied to u-boot/master, thanks!
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20151207/9022f4ca/attachment.sig>
More information about the U-Boot
mailing list