History log of /u-boot/tools/sunxi-spl-image-builder.c
Revision Date Author Comments
# f59a3b21 04-May-2017 xypron.glpk@gmx.de <xypron.glpk@gmx.de>

tools: sunxi: avoid read after end of string

The evaluation of option -c is incorrect:

According to the C99 standard endptr in the first strtol is always
set as &endptr is not NULL.
So the first part of the or condition is always true.
If all digits in optarg are valid endptr will point to the closing \0
and the second strtol will read beyond the end of the string optarg
points to.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>


# 594b4cc7 27-Feb-2017 Maxime Ripard <maxime.ripard@free-electrons.com>

tools: sunxi: Add spl image builder

This program generates raw SPL images that can be flashed on the NAND with
the ECC and randomizer properly set up.

This has been copied (and tweaked to find the right headers) from the
sunxi-tools (https://github.com/linux-sunxi/sunxi-tools) upstream
repository, commit 1c3a6ca5.

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>