Relate to commit 46a8a26905
("fastboot: add RK_AVB_LIBAVB_ENABLE_ATH_UNLOCK config")
Export config can help us select it easily.
Change-Id: I43a210f1efb35ff679102c8686cbca219d2def97
Signed-off-by: zain wang <wzz@rock-chips.com>
This reverts commit 9671243e8d10defb06f2ea24fac138c87697d7fc.
Change-Id: Ie34f9feb06aa0525c9fa59d79ecf687a9a572491
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
This reverts commit a645831ca0962532660e4db3155a8be85e5ca312.
Change-Id: Ida32a1a893b88503cffe432705d5d02921dfab09
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
when CMD_CRYPTO is enabled, SHA512 will be selected.
Change-Id: I2a4dfa1ed024b9a6cc39417836e45ee1309fdfa1
Signed-off-by: Lin Jinhan <troy.lin@rock-chips.com>
This converts the following to Kconfig:
CONFIG_SPI
This partly involves updating code that assumes that CONFIG_SPI implies
things that are specific to the MPC8xx SPI driver. For now, just update
the CONFIG tests. This also involves reworking the default for
CONFIG_SYS_DEF_EEPROM_ADDR so that we don't set it when we cannot make a
reasonable default, as it does not cause any compile failures.
Signed-off-by: Adam Ford <aford173@gmail.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
(cherry picked from commit f1b1f77060beadbfe9f42a3be00019bd025afbd6)
Change-Id: Ie9f15ada869105eb407f41d4df7eecbaa916b940
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
CONFIG_8xx doesn't mean much outside of arch/powerpc/
This patch renames it CONFIG_MPC8xx just like CONFIG_MPC85xx etc ...
It also renames 8xx_immap.h to immap_8xx.h to be consistent with
other file names.
Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
(cherry picked from commit ee1e600c13d16febd517ab7d0d2c243db174789b)
Change-Id: I564708bb6517b699749e8a54c013d032f785e459
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
1.dev_desc->if_type == IF_TYPE_MMC for SD and eMMC device,
dev_desc->devnum == 1 is SD devices,
dev_desc->devnum == 0 is eMMC devices
2.SD devices do not have rpmb
3.we prefer to use rpmb for eMMC devices, use security
partition for nand or SD devices
Change-Id: Ifc21bd4da7c3ee91e2ecc845c343182c78d52dc1
Signed-off-by: Hisping Lin <hisping.lin@rock-chips.com>
cmd/mtd.c:447:13: warning: ‘mtd_help_text’ defined but not used [-Wunused-variable]
static char mtd_help_text[] =
^~~~~~~~~~~~~
When SYS_LONGHELP is not defined. After looking at how other commands
work, we should surround the whole help text (even its declaration) with
an #ifdef CONFIG_SYS_LONGHELP, since it's compiled out when calling
_CMD_HELP[1] on the help text variable argument to U_BOOT_CMD.
[1] https://elixir.bootlin.com/u-boot/latest/source/include/command.h#L181
Change-Id: If84aae3167fd8826e33f717b7debefe32920dd0b
Signed-off-by: Quentin Schulz <quentin.schulz@bootlin.com>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
(cherry picked from commit a645831ca0962532660e4db3155a8be85e5ca312)
It's way simpler this way, and we also gain auto-completion support for
free (MTD name auto-completion has been added with mtd_name_complete())
change-Id: I4292fde7affaddd8eb5a51fe8ec4265ae4984a21
Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
(cherry picked from commit 9671243e8d10defb06f2ea24fac138c87697d7fc)
Since the command mtd is used in the file cmd/mtd.c, rename
the command mtd to mtd_blk.
Change-Id: I3a76aa8cc1da3f4b098f376d13fb0cdcf76ab246
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
This patch update the behavior introduced by
commit 96907c0fe5 ("dm: spi: Read default speed and mode values from DT")
In case of DT boot, don't read default speed and mode for SPI from
CONFIG_* but instead read from DT node. This will make sure that boards
with multiple SPI/QSPI controllers can be probed at different
bus frequencies and SPI modes.
Remove also use in boards of the value speed=0 (no more supported)
for ENV in SPI by using CONFIG_ENV_SPI_MAX_HZ=0.
DT values will be always used when available (full DM support of
SPI slave with available DT node) even if speed and mode are requested;
for example in splash screen support (in splash_sf_read_raw)
or in SPL boot (in spl_spi_load_image).
The caller of spi_get_bus_and_cs() no more need to force speed=0.
But the current behavior don't change if the SPI slave is not
present (device with generic driver is created automatically)
or if platdata is used (CONFIG_OF_PLATDATA).
Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Acked-by: Jagan Teki <jagan@amarulasolutions.com>
Change-Id: I6f5990b73f33815a7acb9b5da9c90dce48b6211d
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
(cherry picked from commit b0cc1b846fcb310c0ac2f8cbeb4ed5947dc52912)
There should not be a 'nand' command, a 'sf' command and certainly not
a new 'spi-nand' command. Write a 'mtd' command instead to manage all
MTD devices/partitions at once. This should be the preferred way to
access any MTD device.
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Acked-by: Jagan Teki <jagan@openedev.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Reviewed-by: Boris Brezillon <boris.brezillon@bootlin.com>
Change-Id: I68bcf4f0126c3a9d6ae0481dafcfcaab0506bd3f
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
(cherry picked from commit 5db66b3aee6f2c057706d8715f7e5c472e82f047)
This converts the following to Kconfig:
CONFIG_MTD_PARTITIONS
CONFIG_MTD_DEVICE
Signed-off-by: Adam Ford <aford173@gmail.com>
Change-Id: I90c45c7716965009c00d18a19f5491f19b1ab8b3
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
(cherry picked from commit 9c5b00973bceb7c0192bd6b03672d69b092700b4)
This header was renamed to rawnand.h in Linux.
The following is the corresponding commit in Linux.
commit d4092d76a4a4e57b65910899948a83cc8646c5a5
Author: Boris Brezillon <boris.brezillon@free-electrons.com>
Date: Fri Aug 4 17:29:10 2017 +0200
mtd: nand: Rename nand.h into rawnand.h
We are planning to share more code between different NAND based
devices (SPI NAND, OneNAND and raw NANDs), but before doing that
we need to move the existing include/linux/mtd/nand.h file into
include/linux/mtd/rawnand.h so we can later create a nand.h header
containing all common structure and function prototypes.
Change-Id: Ia387c26297c268a449e3451c7adfabcd6417b278
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
(cherry picked from commit 6ae3900a86b52429bf7a73ad832f0ad02acc2282)
Some special characters will be treated as a path in windows environment,
such as '\\' and '/'. If the usb upload its serial number with these
special characters, the usb drive will unwork. So use '_' to replace them.
Change-Id: Ic249316f2b03b0dcb73680078f122e23003e6e3d
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Find the current device before find mmc device, otherwise '-1'
will be use as curr_device and error occur. The error log is
"MMC Device -1 not found".
Change-Id: Id6157f73d006f4bbe1c4d105244eb59ca7290c13
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
The driver implementation refers to env/mmc.c, the storage media
binding to block layer can use it(Nand/Nor Flash...).
Support configure:
- CONFIG_ENV_OFFSET
- CONFIG_ENV_SIZE
- CONFIG_ENV_OFFSET_REDUND (optional)
- CONFIG_ENV_SIZE_REDUND (optional)
- CONFIG_SYS_MMC_ENV_PART (optional)
Change-Id: Ibb16f0dd7af1331f454784968fbdc9002f4b769c
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
cmd depends on DM_CHARGE_DISPLAY and default y.
Change-Id: I5e685e0020c4aa1da80ffc27e5a576bc8969c3be
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
- import memblk id to manage memory blocks;
- change "sysmem_property" to generic "memblock";
- use alloc instead of reserve for all memory blocks;
- clean up and fix some logic;
- add U-Boot cmd for sysmem;
Change-Id: I614223ce3bf97a7b3566412a9d1864fb30b68fd8
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Simply return magic char if one is trying to read data beyond 32MB.
Fixes: 628c827 ("usb: rockusb: forbid reading data beyond addr 32MB")
Change-Id: If2cdf05dbf9d6dcdd4cf8f9605ab84480fbca32d
Signed-off-by: Shunqian Zheng <zhengsq@rock-chips.com>
A cmd only returned with CMD_RET_XXX defined
by command_ret_t can ensure it work well when
called from shell.
Change-Id: I16e76ed62928380eaaf3c352efb4df9463b7e72d
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
Use the sysmem to test fastboot memory is available or not.
Change-Id: I021152827b6948fabd5ea41e111ea20adf43167f
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
Forbid reading data beyong addr 32MB to protect user data & firmware. Excess
partial is filled with 0xcc. The addr 32MB is quoted from pre-loader.
Change-Id: I96f4fb3bb0d88a309fef20650863011cd9f0dfd9
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
This avoids user misunderstanding the system is hang
when enter fastboot mode without any warning message.
Change-Id: Ie6238c825342c8e322b2a5be746e4bba020e1ec9
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Available address for testing may start from 0x00.
Change-Id: If3468c11a096c55cf7fff93dff0034679791b3a9
Signed-off-by: Tang Yun ping <typ@rock-chips.com>
Fix DQ to exact level when doing memtester by argument fix_bit and
fix_level.
Change-Id: I4b67b5e499f3e0c4d500d658bc05574f5e50543a
Signed-off-by: Tang Yun ping <typ@rock-chips.com>
1.mmc testsecurestorage to test secure storage
2.test secure storage in rpmb and test secure storage in
security partition when use emmc
3.test secure storage in security partition when use nand
Change-Id: Id6f72893c002c5040cb1790051c9685911878df7
Signed-off-by: Hisping Lin <hisping.lin@rock-chips.com>
Both cmd and its implement shoud be in the same MACRO.
Change-Id: I93587c425f999d9701d88b1d278fcc2a70d64133
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
Extract keymaster CA module from OpteeClientInterface
refactoring code for keymaster reads and writes form caller module
Change-Id: I1069fce0d29d9d9815f71e7f3b4d231754382acd
Signed-off-by: Jian Qiu <qiujian@rock-chips.com>
1. Moving some common code to ddr_tester_common.c to share with ddr tool.
2. io_map.c get dram bandwidth by using get_ddr_bw().
Change-Id: I90641f35c4474846a2357f4959415bfaa6230769
Signed-off-by: Tang Yun ping <typ@rock-chips.com>
For all rk chip, bandwidth is 32bit. Fix to 32bit to improve test
effect.
Change-Id: I4b7f2f3722d6c820886bec46179badc73719496a
Signed-off-by: Tang Yun ping <typ@rock-chips.com>
RK3328/RK3326/PX30: enable CONFIG_OF_LIVE, CONFIG_ROCKCHIP_DMC and
CONFIG_CMD_DDR_TEST_TOOL.
RK1808/RK3399pro npu: enable CONFIG_CMD_DDR_TEST_TOOL.
When enable, it will create a 'ddr_test' command for user in U-Boot shell.
Change-Id: Iaa286e461d53b1caa4bcc069d37a7aad16a3e5e3
Signed-off-by: Tang Yun ping <typ@rock-chips.com>
Thomas reported U-Boot failed to build host tools if libfdt-devel
package is installed because tools include libfdt headers from
/usr/include/ instead of using internal ones.
This commit moves the header code:
include/libfdt.h -> include/linux/libfdt.h
include/libfdt_env.h -> include/linux/libfdt_env.h
and replaces include directives:
#include <libfdt.h> -> #include <linux/libfdt.h>
#include <libfdt_env.h> -> #include <linux/libfdt_env.h>
Change-Id: I6c0f7e50e8b571106627f25ddac008a62bd2994e
Reported-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
For some legacy reasons, rockchip use mkbootimg tool to pack android
images with special pack parameters(SDK version lower than 8.1) to
assign kernel/ramdisk/seconds address and page size.
Android hdr on RK3399 SDK-7.1:
kernel size: 1299808
kernel address: 60408000
ramdisk size: 1e6b80
ramdisk addrress: 62000000
second size: 41c00
second address: 60f00000
tags address: 60088000
page size: 4000
header_version: 0
os_version: e041114 (ver: 1.7.2, level: 2017.4)
name:
cmdline: buildvariant=userdebug
The kernel/ramdisk/seconds address base is not from 0x10000000 and
page size is not 0x800!
This patch makes bootflow to compatible with above legacy packing.
Change-Id: I663a0d1386694658c97586706ff21ed887d6a2e7
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
solve some words match mistakes due to strstr().
Change-Id: I79ca9bc9ed1e9aeb5472e158650890023afa3da3
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
dtimg command allows user to work with Android DTB/DTBO image format.
Such as, getting the address of desired DTB/DTBO file, printing the dump
of the image in U-Boot shell, etc.
This command is needed to provide Android boot with new Android DT image
format further.
Change-Id: I2a626f333f604b6f0424aa03feaddab4e8506a3f
Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>
Signed-off-by: Zhangbin Tong <zebulun.tong@rock-chips.com>
(am from http://patchwork.ozlabs.org/patch/925871/)
1.In rkflash driver, SPI Nand and SPI Nor are registered as two
different if_type
block dev. They are both the child_dev of sfc;
2.Here we send cmd to "rksfc" to operate it's child-dev spi flash device.
Change-Id: I9314ef9c556f8cfbe023021bd66bebec137a4e71
Signed-off-by: Dingqiang Lin <jon.lin@rock-chips.com>
This is a revert to :
a5710920b7 cmd_mmc: make mmc dev always re-probe the HW
For emmc device, we should not re-init the HW with 'mmc dev' cmd,
please use 'mmc rescan' when need HW re-init.
Change-Id: I994d12beb7215db568e7a0ed58be3e36dfda5744
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
This enables the following fastboot commands:
fastboot oem unlock
fastboot oem unlock_accept
fastboot oem lock
fastboot getvar oem-unlock
Android 8.1 need the oem unlock status attach to bootargs on boot.
Change-Id: Icc83451336a4dea2cbcf4927287de23bc8e28cb1
Signed-off-by: Jian Qiu <qiujian@rock-chips.com>
This patch add auto parse the compress format of kernel image.
Then decompress the compressed kernel image for arm64, as for
arm32 zImage, we only need to load it to a higher memory, then
the kernel will handle the decompress itself.
Test on RK3308 AARCH64 mode (Cortex A35 816 MHZ) boot with eMMC:
------------------------------------------------------------------
Format | Size(Byte) | Ratio | Decomp time(ms) | Boot time(ms) |
-------------------------------------------------------------------
Image | 7720968 | | | 488 |
-------------------------------------------------------------------
Image.lz4 | 4119448 | 53% | 59 | 455 |
-------------------------------------------------------------------
Image.lzo | 3858322 | 49% | 141 | 536 |
-------------------------------------------------------------------
Image.gz | 3529108 | 45% | 222 | 609 |
-------------------------------------------------------------------
Image.bz2 | 3295914 | 42% | 2940 | |
-------------------------------------------------------------------
Image.lzma| 2683750 | 34% | | |
-------------------------------------------------------------------
Note: the boot time is counted from first ddr init log to first Kernel log.
Change-Id: I73b12ec944fbc8238b0e061a37e2f31aa3093231
Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
provide ignore option to filter unused key words from a
list of new string which is ready to be appended.
Change-Id: I82d61ee21ec658e73549de42ad94ed259582cb7a
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
trusty_write_vbootkey_hash will set secure boot flag
when we write vboot key hash success, we should remove it
Change-Id: I7b45739918b10b6847a7f5bf6b7c740f3b802870
Signed-off-by: Hisping Lin <hisping.lin@rock-chips.com>
We need to check if the storage(sdmmc) have IDB data so that
we can use it as boot device.
Change-Id: I7373b8f1a6c4c41c1d2cb1c94cd5d20c0780b5db
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
Read oem unlock status from optee_client api
and attach it to bootargs
Change-Id: Ib8b1a9bc115ec9cb7e5ce09dc50845cfd7c1c81b
Signed-off-by: Qiu Jian <qiujian@rock-chips.com>
Add methods to read attestation key from the misc partition of
last 64K, store key and certificate chain data in secure storage.
When CONFIG_OPTEE_CLIENT is defined,
uboot support load attestation data.
Change-Id: I8f3bd7096a7856de9e58d294822a818d5fe380ba
Signed-off-by: qiujian <qiujian@rock-chips.com>
The kernel image follows the header(default 0x800) in boot.img, we need to fix
the load address for boot.img so that kernel image can align to 0x80000 as
required by ARM64 kernel booting.
Change-Id: I526ff38bfce2d8fd1571aff817ade11086f196e3
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
The commit point is updated to google external/avb/
which commit point is cf8c56208d2d9643804a7f123b196c7ebc9af276.
Change-Id: I5a10a8a45d3e9e2c9d20d9b3d44946073c9a49ff
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
This is the most flexsible way for all fuel gauge driver to get
fdt config info from charge animation platdata.
Change-Id: I33aa52c34f2c62c10b58003a10e5a8d1d6e5d7d3
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Add a command which exercises the logging system.
Change-Id: I4eb139b69937c752d7f6fc42dde3f757260b832b
Signed-off-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit ef11ed8239bf02b347e7fb9fc6d980aec0c7810a)
Add a command for adjusting the log level.
Change-Id: I51e15c61e860f4f0bdb980f1d7aa88c492f55d49
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit d5f61f272d5b7b86bf6321512ba6326c7c075e72)
This does not appear to be used by any boards. Before introducing a new
log system, remove this old one.
Change-Id: I798cd4aff50b7136ae9f84362185f9f73b04f710
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit c5404b64fb5a35d41f7eff6d12b8ffdb0c851040)
sdram sub command of i2c command does not support Drivers Model.
This adds Drivers Model support to sdram sub command.
Change-Id: I405d05b9b697715759a68ba71597cd9ae63d9565
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Heiko Schocher <hs@denx.de>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit 28df8ed07f2ae936e9af28c146d555ed4d0c122a)
Remove an unreachable return statement.
Change-Id: I523a83571eade593a08b685519757c1df4ffab25
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit 254eedee7f383066b70ac4da01bc792a3256a4b3)
Usb tree/info commands iterate over all usb uclass devices recursively.
Blk uclass devices based on struct blk_desc are created for mass storage
device, treating them as usb uclass devices based on struct usb_device
and referencing usb config interface descriptors cause crash.
To fix, ignore blk and usb_emul uclass devices in usb_show_info
and usb_tree_graph. Also avoid addition of preamble for blk uclass
child devices, otherwise tree dump gets messed up.
Change-Id: If25ca43b08c0918c44583f71282a07c928e5bf53
Signed-off-by: Suneel Garapati <suneelglinux@gmail.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Tested-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit abd7cedb19ab7979467734b3933a39879bd8935a)
Since the compiler is free to place a char array to any address in
memory (in this case the stack), also to a non word aligned address the
function "fdt_prop_parse" runs into troubles upon it wants to write some
(fdt32_t *) to such a variable (if it has been placed to a none word
aligned address).
To avoid this we tell the compiler to always align this scratchpad to a
word aligned address.
Change-Id: I6ea64827a9c245db4ba2a2ff522aaddea647c2f2
Signed-off-by: Bernhard Messerklinger <bernhard.messerklinger@br-automation.com>
Reviewed-by: Hannes Schmelzer <oe5hpm@oevsv.at>
Tested-by: Hannes Schmelzer <oe5hpm@oevsv.at>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit 6dfd65f81fd060a85c961a84f85a286e8e96332c)
As the code currently stands, we first check that the length of the
given command line, along with ip_str/mac_str along with an additional 1
for the NULL termination will fit within the buffer we have, and if not,
we return an error. The way this code was originally written however
left Coverity "unhappy" due to using strcat rather than strncat.
Switching this to strncat however causes clang to be unhappy that we
aren't enforcing the "1" portion within strncat. Rather than further
re-work the code to include a "- 1" in this case as well, make the
strcat code only be done within the else side of the length test. This
keeps both clang and Coverity happy.
Fixes: 48ee0a87bc46 ("cmd/pxe.c: Rework initrd and bootargs handling slightly")
Change-Id: I6a3d3ea54d6b7e1f3c2aed200b2f706f42d570d4
Signed-off-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit 59ee8f83b6e77550d5697fced4899e9b5173981f)
Last user of this option went away in commit:
fdc7718999 ("board: usb_a9263: Update to support DT and DM")
Change-Id: Id05869deccb88c1102700dd5af58a8c249e3e9e2
Signed-off-by: Tuomas Tynkkynen <tuomas.tynkkynen@iki.fi>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit c68c03f52badc90951dbf8a054c0e500e04bf365)
Last user of this option went away in commit:
fdc7718999 ("board: usb_a9263: Update to support DT and DM")
Change-Id: Ie6cec28e4daf26b669f3f35db026427bdb47a5b6
Signed-off-by: Tuomas Tynkkynen <tuomas.tynkkynen@iki.fi>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit 7b7341d7f3ee915c89a7f8ab7054e39872057d90)
CONFIG_CMD_SPL_WRITE_SIZE is used for writing parameters to non-volatile
storage. So far it is only used for NAND. Fix compiling error when this
macro is not used for SD.
Change-Id: I879971e42fb333e1e0ff4e21ce6b34caf8498aa5
Signed-off-by: York Sun <york.sun@nxp.com>
CC: Anatolij Gustschin <agust@denx.de>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit b65ac633f52da596cfa573bb4a597e2edd2318c8)
In the Linux Kernel on ARM64, the Image.COMPRESSION file is not
self-extracting in the way that x86 and ARM images are. So when
CMD_BOOTI is enabled we should also default to enabling CMD_UNZIP and
CONFIG_LZMA in order for the user to be able to decompress many of the
common compressions that will be done to an Image file.
Change-Id: Ic7958458ddc16c8b78ea40ff56d380d02883d76a
Signed-off-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit 99e46dfc6a9176f6f0680c9dfdf33c97d56336ce)
On case-insensitive file systems we have collision between
scripts/kconfig/ directory and scripts/Kconfig file. This patch moves
scripts/Kcofnig contents to cmd/Kconfig to fix that.
Change-Id: Ia60682a7eb9c3379e6e257b07e799b06e304c95f
Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>
Acked-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit 610eec7f0593574c034054ba54fc1c934755e208)
The recent changes to these files did not completely fix the previous
issues, or introduced different (minor) issues. In cmd/gpt.c we need to
dereference str_disk_guid to be sure that malloc worked. In
cmd/nvedit.c we need to be careful that we can also fit in that leading
space when adding to the string. And in tools/fit_image.c we need to
re-work the error handling slightly in fit_import_data() so that we only
call munmap() once. We have two error paths here, one where we have an
fd to close and one where we do not. Adjust labels to match this.
Change-Id: I66fafd0ed8d1c290a7773bba5ece8d11bfc15b50
Reported-by: Coverity (CID: 167366, 167367, 167370)
Signed-off-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit bf52fcdef4aac242b5e6b6b9827acf6d69ce1951)
We cannot leave this uninitialized, set it to 0.
Change-Id: Ic8f3dd4d7395921bf4269a618aaf92a717dbfe46
Reported-by: Coverity (CID: 144426)
Signed-off-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit 146dda391126d4f199c7692f2342efcc34b45ebd)
For the initrd portion of handling our bootm arguments we do not have a
sufficiently long enough buffer for some improbable 64bit cases. Expand
this buffer to allow for a 64bit address and almost 256MB initrd to be
used. Make use of strncpy/strncat when constructing the values here
since we know what the worst case valid values are, length wise.
Similarly for bootargs themselves, we need to make use of strlen/sizeof
and strncpy/strncat to ensure that we don't overflow bootargs itself.
Cc: Simon Glass <sjg@chromium.org>
Cc: Alexander Graf <agraf@suse.de>
Change-Id: I86151e4bde53972d9b6105f3a85db93b114e22d8
Reported-by: Coverity (CID: 131256)
Signed-off-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit 48ee0a87bc46a6f863ffd9e0396b7a068dd68c50)
When we have multiple messages provided, we need to be sure that we do
not exceed the length of our 'message' buffer. In the for loop, make
sure that pos is not larger than message. Only copy in at most however
much of the message buffer remains. Finally, if we have not reached the
end of the message buffer, put in a space and NULL, and if we have,
ensure the buffer is now NULL termined.
Change-Id: I0c4f88803f8525eb6ef0207a6b7fdbec2b43e9ff
Reported-by: Coverity (CID: 165116)
Signed-off-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
(cherry picked from commit c667723ffb50b00585b729ee0da7b0e8c93ffa13)