Commit Graph

18039 Commits

Author SHA1 Message Date
Miquel Raynal
350988ff1a tpm: fix typo in kernel doc
The udevice given to the open() function of course must be opened,
not closed.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2018-07-28 11:55:31 -04:00
Tom Rini
0e8a8a3110 Merge git://git.denx.de/u-boot-fsl-qoriq 2018-07-27 13:09:30 -04:00
Tom Rini
11e409284e openrd: Once again shrink binary size
With some recent changes to relevant drivers here the openrd board
(openrd_client in this case) does not fit within its size constraint.
We can however drop the slightly extended baudrate table and then the
duplication of mtdparts/mtdids in the default environment.  These
defaults are set in the environment by the 'mtdparts' command and
otherwise referenced throughout the code.

Signed-off-by: Tom Rini <trini@konsulko.com>
2018-07-27 07:56:59 -04:00
Vagrant Cascadian
d06ac6034d arm: odroid: Inherit default value for bootdelay from distro_bootcmd.
The default value with distro_bootcmd is 2 seconds, which is
reasonably fast, and provides a consistent experience across platforms
supporting distro_bootcmd.

The current bootdelay value of 0 seconds is a bit challenging to
interrupt when desired.

Acked-by: Lukasz Majewski <lukma@denx.de>

Signed-off-by: Vagrant Cascadian <vagrant@debian.org>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2018-07-27 11:19:55 +09:00
Vagrant Cascadian
ef41aea96e arm: odroid: Enable distro_bootcmd support.
Enable distro_bootcmd for a standardized boot process across multiple
platforms.

Acked-by: Lukasz Majewski <lukma@denx.de>
Signed-off-by: Vagrant Cascadian <vagrant@debian.org>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2018-07-27 11:19:55 +09:00
Vagrant Cascadian
22297aaa4f arm: odroid: Increase default env size in preparation for distro_bootcmd.
Adding distro_bootcmd support bumps the default environment size over
4500. Increase to SZ_16K to allow for room to grow in the future.

Acked-by: Lukasz Majewski <lukma@denx.de>

Signed-off-by: Vagrant Cascadian <vagrant@debian.org>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2018-07-27 11:19:55 +09:00
Vagrant Cascadian
93716afbbe arm: odroid: Use standard environment variable names kernel_addr_r, ramdisk_addr_r and fdt_addr_r.
Replace non-standard variable names kerneladdr, initrdaddr and fdtaddr
with kernel_addr_r, ramdisk_addr_r and fdt_addr_r, as documented in
u-boot README.

Acked-by: Lukasz Majewski <lukma@denx.de>
Signed-off-by: Vagrant Cascadian <vagrant@debian.org>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2018-07-27 11:19:55 +09:00
Guillaume GARDET
a53729456b snow: set fdtfile
Needed to boot with EFI distro boot.

Signed-off-by: Guillaume GARDET <guillaume.gardet@free.fr>

Cc: Akshay Saraswat <akshay.s@samsung.com>
Cc: Tom Rini <trini@konsulko.com>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2018-07-27 11:19:49 +09:00
Grygorii Strashko
eef0b8a930 net: phy: add ofnode node to struct phy_device
Now the UCLASS_ETH device "node" field is owerwritten by some network drivers in
case of Ethernet PHYs which are linked to UCLASS_ETH device using
"phy-handle" DT property and when Ethernet PHY driver needs to read some
additional information from DT. In such cases following happens (in
general):

- network drivers
	priv->phydev = phy_connect(priv->bus, priv->phyaddr, dev,
				   priv->interface);
	<-- phydev is connected to dev which is UCLASS_ETH device

	if (priv->phy_of_handle > 0)
		dev_set_of_offset(priv->phydev->dev, priv->phy_of_handle);
	<-- phydev->dev->node is overwritten by phy-handle DT node

- PHY driver in .config() callback
	int node = dev_of_offset(dev);
	<-- PHY driver uses overwritten dev->node
        const void *fdt = gd->fdt_blob;

	 if (fdtdec_get_bool(fdt, node, "property"))
		...

As result, UCLASS_ETH device can't be used any more for DT accessing.

This patch adds additional ofnode node field to struct phy_device which can
be set explicitly by network drivers and used by PHY drivers, so
overwriting can be avoided. Also add helper function phy_get_ofnode()
which will check and return phy_device->node or dev_ofnode(phydev->dev) for
backward compatibility with existing drivers.

Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2018-07-26 14:08:22 -05:00
Joe Hershberger
f070b1a27a phy: Break include cycle
Because some phy wants to export some functions [1], export.h was
including the whole phy subsystem which pulls in lots of stuff that
causes some ordering and redefinition issues. Split out the only part
that is actually needed in export.h and include it there and in phy.h.

[1] commit 9527931507 ("board/ls2085rdb: Export functions for
			  standalone AQ FW load apps")

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2018-07-26 14:08:22 -05:00
Joe Hershberger
6ab1283092 net: Consolidate the parsing of bootfile
The same basic parsing was implemented in tftp and nfs, so add a helper
function to do the work once.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2018-07-26 14:08:20 -05:00
Joe Hershberger
3a66fcb7c3 net: When checking prerequisites, consider boot_file_name
For net_boot_common, we allow the serverip to be specified as part of
the boot file name. For net commands that require serverip, include that
source as a valid specification of serverip.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Reviewed-by: Alexander Graf <agraf@suse.de>
2018-07-26 14:08:19 -05:00
York Sun
038b965c2b armv8: ls1046ardb: Add falcon mode for for QSPI boot
A new defconfig is introduced to support SPL boot from QSPI NOR
flash. This is to support falcon mode for faster booting into
Linux.

Signed-off-by: York Sun <york.sun@nxp.com>
2018-07-26 11:51:23 -07:00
York Sun
67b4f5302a powerpc: mpc85xx: Drop u-boot-with-spl.bin on selected boards
For SoCs with PBL, u-boot-with-spl-pbl.bin is the final image for
SPL boot. Drop unused u-boot-with-spl.bin.

Signed-off-by: York Sun <york.sun@nxp.com>
CC: Ashish Kumar <ashish.kumar@nxp.com>
CC: Ruchika Gupta <ruchika.gupta@nxp.com>
CC: Priyanka Jain <priyanka.jain@nxp.com>
CC: Shengzhou Liu <Shengzhou.Liu@nxp.com>
2018-07-26 10:59:35 -07:00
York Sun
18b6dd6cb0 armv8: layerscape: Drop u-boot-with-spl.bin for selected boards
For SPL boot with PBL, u-boot-with-spl-pbl.bin is the final image.
Drop unused u-boot-with-spl.bin.

Signed-off-by: York Sun <york.sun@nxp.com>
CC: Mingkai Hu <mingkai.hu@nxp.com>
CC: Ruchika Gupta <ruchika.gupta@nxp.com>
CC: Prabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
CC: Udit Agarwal <udit.agarwal@nxp.com>
CC: Sumit Garg <sumit.garg@nxp.com>
CC: Priyanka Jain <priyanka.jain@nxp.com>
2018-07-26 10:59:35 -07:00
York Sun
80bec96ecf armv8: ls1046ardb: Enable IFC for SPL build
Commit a52ff334c5 ("armv8: ls1046ardb: SPL size reduction") reduced
image size for SPL. IFC was disabled. If PPA is loaded in SPL, MMU is
enabled as a result. Removing IFC skips IFC region in the MMU table,
causing later failure in RAM version U-boot when accessing CPLD
through IFC. Only disable IFC if PPA is not enabled for SPL.

Signed-off-by: York Sun <york.sun@nxp.com>
2018-07-26 10:59:35 -07:00
York Sun
02d8dc9678 armv8: ls1046ardb: ls1046aqds: Move SPL macros to defconfig
Instead of defining Kconfig macros in header file, move them to
defconfig files.

Signed-off-by: York Sun <york.sun@nxp.com>
2018-07-26 10:59:35 -07:00
Ashish Kumar
32dab9100e armv8: ls2088ardb: Move CONFIG_SPI_FLASH, CONFIG_SPI_FLASH_SPANSION to defconfig
Move CONFIG_SPI_FLASH_SPANSION, CONFIG_SPI_FLASH, to defconfig.
Also disable disable 4K erase size option.

Signed-off-by: Ashish Kumar <Ashish.Kumar@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
2018-07-26 10:59:35 -07:00
Vinitha V Pillai
fe6636f14c LS1088ARDB: Secure Boot:Change load address of dpl header in SD
Change address of DPL header in SD.

Signed-off-by: Vinitha V Pillai <vinitha.pillai@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
2018-07-26 10:59:35 -07:00
Jagdish Gediya
f4ef476d20 armv8: ls1088a: change dpl load command from apply to lazyapply
use "fsl_mc lazyapply dpl addr" instead of "fsl_mc apply dpl addr"

change dpl load addr to 0x80001000 from 0x80200000 because dpl gets
corrupted at 0x80200000 during bootm command excecution.

Signed-off-by: Jagdish Gediya <jagdish.gediya@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
2018-07-26 10:59:35 -07:00
Heinrich Schuchardt
197005ae2a efi_loader: remove unused efi_get_time_init()
Remove unused function efi_get_time_init().

Initialization of the RTC has to be done in board bring up not in the EFI
subsystem.

There is no RTC device in the UEFI spec. The RTC is only accessed through
the runtime services.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 15:00:24 +02:00
Heinrich Schuchardt
8aa8360eca efi_loader: correct signature of CalculateCrc32()
Use const for the buffer. We are not changing the buffer.
Use efi_uintn_t where prescribed by the UEFI spec.
Prefer u32 over uint32_t.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 15:00:24 +02:00
Heinrich Schuchardt
4182a129ef efi_loader: allocate configuration table array
The system table contains a link to the list of configurations tables.
These include the device tree, SMBIOS table, and the ACPI table.

This array is currently statically linked. With the patch it is allocated
as EFI_RUNTIME_SERVICES_DATA. Due to the structure of the system table we
cannot work with a linked list here.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 15:00:24 +02:00
Heinrich Schuchardt
640adadf81 efi_loader: calculate crc32 for EFI tables
For the boot and runtime services tables and for the system table the
crc32 has to be set in the header.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 15:00:24 +02:00
Heinrich Schuchardt
0b386537a5 efi_loader: provide firmware revision
Provide a firmware revision in the system table using the Makefile
variables VERSION and PATCHLEVEL, e.g. 0x20180700 for v2018.07.

Correct the type of the firmware vendor. It is a u16* pointer.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 14:59:44 +02:00
Heinrich Schuchardt
bdfb894a3e efi_loader: correct EFI_RUNTIME_SERVICES_SIGNATURE
The value for EFI_RUNTIME_SERVICES_SIGNATURE does not match the
UEFI spec 2.7.

Reported-by: Takahiro Akashi <takahiro.akashi@linaro.org>
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 14:59:44 +02:00
Heinrich Schuchardt
112f243016 efi_loader: specify UEFI spec revision
Both in the boot and the runtime services tables we have to specify the
UEFI spec revision. The same value is already used for the system
table. So let's use a common constant.

In the boot services table we have to provide the header signature.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 14:59:44 +02:00
Heinrich Schuchardt
95147313a9 efi_loader: set revision in loaded image protocol
The revision number has to be set in the loaded image protocol.

The problem was detected by running the SCT in
Protocol/LoadedImage/BlackBoxTest/LoadedImageBBTestMain.c:890

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 14:59:44 +02:00
Heinrich Schuchardt
1fcb7ea284 efi_loader: check map_key in ExitBootServices
The UEFI spec requires that the memory map key is checked in
ExitBootServices().

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 14:59:44 +02:00
Alexander Graf
7e21fbca26 efi_loader: Rename sections to allow for implicit data
Some times gcc may generate data that is then used within code that may
be part of an efi runtime section. That data could be jump tables,
constants or strings.

In order to make sure we catch these, we need to ensure that gcc emits
them into a section that we can relocate together with all the other
efi runtime bits. This only works if the -ffunction-sections and
-fdata-sections flags are passed and the efi runtime functions are
in a section that starts with ".text".

Up to now we had all efi runtime bits in sections that did not
interfere with the normal section naming scheme, but this forces
us to do so. Hence we need to move the efi_loader text/data/rodata
sections before the global *(.text*) catch-all section.

With this patch in place, we should hopefully have an easier time
to extend the efi runtime functionality in the future.

Signed-off-by: Alexander Graf <agraf@suse.de>
[agraf: Fix x86_64 breakage]
2018-07-25 14:57:44 +02:00
Alexander Graf
dae73c4cdc elf: Move x86 reloc defines to common elf.h
We need to know about x86 relocation definitions even in cases where
we don't officially build against the x86 target, such as with sandbox.

So let's move the x86 definitions into the common elf header, where all
other architectures already have them.

Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 14:57:43 +02:00
Alexander Graf
beb077a2a8 efi_loader: Introduce ms abi vararg helpers
Varargs differ between sysv and ms abi. On x86_64 we have to follow the ms
abi though, so we also need to make sure we use x86_64 varargs helpers.

This patch introduces generic efi vararg helpers that adhere to the
respective EFI ABI. That way we can deal with them properly from efi
loader code and properly interpret variable arguments.

This fixes the InstallMultipleProtocolInterfaces tests in the efi selftests
on x86_64 for me.

Signed-off-by: Alexander Graf <agraf@suse.de>
2018-07-25 14:57:43 +02:00
Tom Rini
73a555d12a Merge branch 'master' of git://git.denx.de/u-boot-uniphier 2018-07-24 22:46:50 -04:00
Masahiro Yamada
7ef5b1e7ed ARM: uniphier: enable distro boot
Switch to the distro boot for UniPhier platform.

 - Remove the environment vairalbes used to load images from raw
   block devices.

 - Keep the command to download images via tftp.  This will be
   useful to boot the kernel when no valid kernel image is ready
   yet in the file system.

 - Use root.cpio.gz instead of root.cpio.uboot because we always know
   the file size of the init ramdisk; it is loaded via either a file
   system or network.

 - Rename fit_addr_r to kernel_addr_r, which the distro command
   checks to get the load address of FIT image.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2018-07-25 08:47:53 +09:00
Masahiro Yamada
5f4e32d058 fdt_support: make fdt_fixup_mtdparts() prototype more specific
The second argument of fdt_fixup_mtdparts() is an opaque pointer,
'void *node_info', hence callers can pass any pointer.

Obviously, fdt_fixup_mtdparts() expects 'struct node_info *'
otherwise, it crashes run-time.

Change the prototype so that it is compile-time checked.

Also, add 'const' qualifier to it so that callers can constify
the struct node_info arrays.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2018-07-25 08:47:52 +09:00
Heinrich Schuchardt
0cd07a90a9 config: remove unused CONFIG_SPL_RELOC_STACK_SIZE
Symbol CONFIG_SPL_RELOC_STACK_SIZE is not used anywhere. So remove it.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2018-07-24 09:25:23 -04:00
Patrice Chotard
4807c40c2f board: STiH410-B2260: Set SYS_BOOTM_LEN to 16M
With recent kernel v4.18-rcx, uImage becomes bigger than 8MB.
Set SYS_BOOTM_LEN to 16MB, this fix the following error message:
"Fix Loading Kernel Image ... Image too large: increase
CONFIG_SYS_BOOTM_LEN"

Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
2018-07-24 09:25:23 -04:00
Miquel Raynal
980f65dc6c mtd: remove stale comment in mtd_oob_ops structure
A comment in the kernel doc of the mtd_oob_ops structure tells that it
is not possible to write more than one page with OOB. This was
probably true at some time in the past but today it is entirely wrong.

As one can see for instance in the nand_do_write_ops() helper available
in the NAND core, this implementation called by mtd->_write_oob()
simply loops over the pages until everything has been written.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
2018-07-24 09:25:23 -04:00
Rafał Miłecki
323a73adc9 mtd: nand: add new enum for storing ECC algorithm
Our nand_ecc_modes_t is already a bit abused by value NAND_ECC_SOFT_BCH.
This enum should store ECC mode only and putting algorithm details there
is a bad idea. It would result in too many values impossible to support
in a sane way.

To solve this problem let's add a new enum. We'll have to modify all
drivers to set it properly but once it's done it'll be possible to drop
NAND_ECC_SOFT_BCH. That will result in a cleaner design and more
possibilities like setting ECC algorithm for hardware ECC mode.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
[Linux commit: b0fcd8ab7b3c89b5da7fff5224d06ed73e7a33cc]
[Philippe Reynes: adapt code to u-boot]
Signed-off-by: Philippe Reynes <philippe.reynes@softathome.com>
2018-07-23 14:33:21 -04:00
Adam Ford
5d653afc17 Convert CONFIG_DA8XX_GPIO to Kconfig
This converts the following to Kconfig:
   CONFIG_DA8XX_GPIO

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-07-23 14:33:21 -04:00
Mario Six
78a88f7930 doc: Replace DocBook with sphinx-based docs
The Linux kernel moved to sphinx-based documentation and got rid of the
DocBook based documentation quite a while ago. Hence, the DocBook
documentation for U-Boot should be converted as well.

To achieve this, import the necessary files from Linux v4.17, and
convert the current DocBook documentation (three files altogether) to
sphinx/reStructuredText.

For now, all old DocBook documentation was merged into a single
handbook, tentatively named "U-Boot Hacker Manual".

For some source files, the documentation style was changed to comply
with kernel-doc; no functional changes were applied.

Signed-off-by: Mario Six <mario.six@gdsys.cc>
2018-07-23 14:33:21 -04:00
Adam Ford
66dae3bbca ARM: dts: Resync OMAP3 and omap36xx with Linux 4.18-RC4
There have been several minor changes to the OMAP3.dtsi, so this
patch re-syncs it with Linux.  An addition include/dt-binding was
also brought with it.

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-07-23 14:33:21 -04:00
Tom Rini
b740074ac4 m68k: m5253evbe: Remove this board
The m5253evbe board has been marked as orphan since June of 2014 and
should have been dropped a while ago.  Do so now.

Signed-off-by: Tom Rini <trini@konsulko.com>
2018-07-23 14:33:21 -04:00
Tom Rini
f0306a145b Merge branch 'master' of git://git.denx.de/u-boot-imx
trini: Update colibri-imx6ull to use Kconfig for mtdparts related
options.

Signed-off-by: Tom Rini <trini@konsulko.com>
2018-07-23 13:37:42 -04:00
Adam Ford
f97f167107 configs: imx6q_logic: Cleanup ramdiskaddr and fdtaddr
There are already definitions for ramdisk_addr_r and fdt_addr_r, so
having a duplicate copy called ramdiskaddr and fdtaddr is confusing.
This patch converts any references to ramdisk_addr_r and fdt_addr_r
and removes the duplicates.

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-07-23 11:05:54 +02:00
Adam Ford
bbbb50f9fd imx: i.mx6q: imx6q_logic: Migrate to SPL and enable SDP
Since the vast majority of i.MX6 boards are migrating to SPL,
this patch converts im6q_logic to SPL and enables the SDP for
loading SPL and u-boot.img over USB.  The Falcon mode only
supports NAND flash as of now due to limited space/RAM, but
all i.MX6D/Q SOM's from Logic PD have internal NAND from which
to boot.

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-07-23 11:03:20 +02:00
Otavio Salvador
4f96670104 pico-imx7d: Allow default fdtfile to be overridden by defconfig
This allow the addition of extra default configurations for each
baseboard, removing the boot menu when user boots for the first time.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Fabio Estevam
78d30a1bc0 pico-imx7d: Add Falcon mode support
Falcon mode boots the kernel directly from SPL, without loading
the full U-Boot.

As pico-imx7d does not have a GPIO for selecting Falcon versus
normal mode, enter in Falcon mode when the customer selects
the CONFIG_SPL_OS_BOOT option in menuconfig.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Otavio Salvador
22dda6bd8b pico-imx7d: Add bootmenu to choose the baseboard
Currently the baseboards do not offer a way to autodetect which one is
in use, so we ask the user if no value has been set.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Fabio Berton
1e64642694 pico-imx7d: Add support for update SPL using DFU
Add spl entry on dfu_alt_info to be able to update U-Boot with SPL
for pico imx7d board.

Signed-off-by: Fabio Berton <fabio.berton@ossystems.com.br>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Fabio Estevam
d5b7177f91 pico-imx7d: Add SPL support
Convert pico-imx7d to SPL support.

There are two variants of pico-imx7d SOMs:
- One with 512MB of RAM
- One with 1GB of RAM

The 512MB module contains two Hynix H5TC2G63GFR-PBA.
The 1GB module contains two Hynix H5TC4G63GFR-PBA.

The RAM size is determined in runtime by reading GPIO1_12.

While at it, also add USB Serial Download mode support as it
is very helpful for loading SPL and u-boot.img via imx_usb_loader.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Fabio Estevam
3fbbfed7a8 pico-imx7d: Add fastboot support
fastboot tool is a convenient way to flash the eMMC, so
add support for it.

Examples of usages:

On the pico-imx7d U-Boot prompt:

=> fastboot 0

On the Linux PC connected via USB:

1. Retrieving the U-Boot version

$ sudo fastboot getvar bootloader-version -i 0x0525
bootloader-version: U-Boot 2018.07-rc1-03888-gde846f9
finished. total time: 0.000s

2. Resetting the board

$ sudo fastboot reboot -i 0x0525

(this causes the pico-imx7d to reboot)

Signed-off-by: Fabio Estevam <festevam@gmail.com>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Otavio Salvador
0676b6948d pico-imx7d: Add default DFU targets
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Otavio Salvador
4242de43bb pico-imx7d: Add GPT partitioning support
This allow the use of:

> run setup_emmc

inside of the U-Boot prompt to do the partitioning of the disk.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Otavio Salvador
7985987dc4 pico-imx7d: Fix common distro configuration behavior
This sets DISTRO_CONFIG and BOOTCOMMAND, as well as add a `finduuid`
environment helper to allow it to properly work with Yocto Project and
other distributions using extlinux autogenerated configuration files.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Fabio Estevam
7bbce215d8 pico-imx7d: Convert to distro config
Instead of keeping a custom environment, use a more generic approach
by switching to disto config.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2018-07-23 10:59:48 +02:00
Jon Nettleton
5531460895 mx6cuboxi: Move the default environment for all devices
Previously we had stored the environment right after the
u-boot.img on the disk.  I never liked this because with dtbs
being included and such the image could grow in size.  Instead
we move the environment to be negatively offset from the 1MB
mark.  Almost all our images start at 4MB's, and most standard
images start at 1MB, and all our storage devices are a minimum
1MB.  Therefore we can store env there for all classes of devices
and have plenty of space in case u-boot.img needs to grow.

Signed-off-by: Jon Nettleton <jon@solid-run.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>
2018-07-23 10:56:06 +02:00
Jon Nettleton
824705d53c mx6cuboxi: Add emmc device tree suffix
Mainline and now the SolidRun 4.9 nxp based tree use the new
reorganization of device-tree files that separate out the emmc
into its own dtb.  u-boot will now look for -emmc in the device
tree name if one is detected.

Signed-off-by: Jon Nettleton <jon@solid-run.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
2018-07-23 10:17:04 +02:00
Baruch Siach
c4abe2863a mx6cuboxi: drop CONFIG_SYS_FSL_USDHC_NUM
This macro is not used.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
2018-07-23 10:17:04 +02:00
Jon Nettleton
6c09eba507 mmc: break out get_op_cond code to its own function
This code is useful for testing the existance of devices that
do not have card detect capabilities.  This breaks out the core
functionality and leaves the actual init logic and error reporting
in mmc_start_init().

Signed-off-by: Jon Nettleton <jon@solid-run.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Reviewed-by: Stefano Babic <sbabic@denx.de>
2018-07-23 10:17:04 +02:00
Baruch Siach
31d9500498 mmc: drop mention of IN_PROGRESS status
The IN_PROGRESS macro has been removed in commit bd47c13583 (mmc: Fix
splitting device initialization). Remove it from the mmc_start_init()
function description.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
2018-07-23 10:17:04 +02:00
Stefan Agner
31b1e17f44 board: toradex: add Colibri iMX6ULL support
Add support for the Colibri iMX6ULL module which comes with
on-board raw NAND.

Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
2018-07-23 10:12:00 +02:00
Adam Ford
9c5b00973b Convert CONFIG_MTD_PARTITIONS et al to Kconfig
This converts the following to Kconfig:
   CONFIG_MTD_PARTITIONS
   CONFIG_MTD_DEVICE

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-07-22 19:20:17 -04:00
Adam Ford
8d0d6bc121 configs: Convert CONFIG_USE_NAND to CONFIG_NAND
The DA850-EVM and OMAPL138_LCDK both use checks for CONFIG_USE_NAND.
This patch changes these checks to CONFIG_NAND which is already defined
in Kconfig.  Since the OMAPL138_LCDK already had CONFIG_NAND defined in its
defconfig, it can be deleted from configs/omapl138_lcdk.h.

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-07-21 22:26:59 -04:00
Adam Ford
eba7f1ff6c Convert CONFIG_NAND_DAVINCI to Kconfig
This converts the following to Kconfig:
   CONFIG_NAND_DAVINCI

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-07-21 22:26:56 -04:00
Adam Ford
e7db856bf9 Convert CONFIG_NAND_ATMEL to Kconfig
This converts the following to Kconfig:
   CONFIG_NAND_ATMEL

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-07-21 22:26:28 -04:00
Adam Ford
d294335e5d Convert CONFIG_NAND_LPC32XX_SLC to Kconfig
This converts the following to Kconfig:
   CONFIG_NAND_LPC32XX_SLC

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-07-21 22:26:25 -04:00
Klaus Goger
a2a5053a15 rockchip: utilize CONFIG_DEFAULT_FDT_FILE
Currently the fdtfile environment variable is set to
CONFIG_DEFAULT_DEVICE_TREE which is іnternally used as U-Boot devicetree
source. The OS can use a different filename and Kconfig gives us the
ability to select a default devicetree via CONFIG_DEFAULT_FDT_FILE.
This also gives user configuring U-Boot via menuconfig the behaviour
someone would expect.

Signed-off-by: Klaus Goger <klaus.goger@theobroma-systems.com>
Tested-By: Vagrant Cascadian <vagrant@debian.org>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2018-07-21 01:56:59 +02:00
Jakob Unterwurzacher
abb8fad097 rockchip: board: lion-rk3368: increase phy autonegotiation timeout
The first dhcp command consistently fails with a timeout when
the lion-rk3368 board is connected to a Zyxel GS1100-24E
Gigabit Ethernet switch:

  ethernet@ff290000 Waiting for PHY auto negotiation to complete......... TIMEOUT !

Increasing PHY_ANEG_TIMEOUT from the default 4000 to 8000 makes the
first dhcp command work reliably.

Signed-off-by: Jakob Unterwurzacher <jakob.unterwurzacher@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2018-07-21 01:55:26 +02:00
Philipp Tomsich
de5dd4c4e3 spl: record boot_device into spl_image and call spl_perform_fixups
On some boards, we want to give the board/architecture-specific code a
chance to look at where the next image has been loaded from and
perform fixups before starting the next image.  This is of particular
importance, when we probe multiple devices for bootable payloads and
boot the first one found.

This change adds the following:
 - we record the boot_device used into the spl_image structure
 - we provide an extension-point for boards/architectures that can
   perform late fixups depending on a fully populated spl_image
   structure (i.e. we'll know the final boot_device and have info
   on the image type and operating system to be booted).

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Tested-by: Klaus Goger <klaus.goger@theobroma-systems.com>
2018-07-21 01:55:26 +02:00
Patrick Delaunay
d090cbab64 misc: stm32: Add STM32MP1 support
Following next kernel rcc bindings, we must use a MFD
RCC driver which is able to bind both clock and reset
drivers.

We can reuse and adapt RCC MFD driver already available
for MCU SoCs (F4/F7/H7).

Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
2018-07-20 15:55:05 -04:00
Patrick Delaunay
a674313c2c dts: import stm32mp1 device tree from linux kernel
This patch rebase the stm32mp1 device tree source from
linux kernel v4.18-rc1.

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
2018-07-20 15:55:05 -04:00
Alex Kiernan
57aa4d2066 env: Include bootdelay in environment if negative
The test for (CONFIG_BOOTDELAY >= 0) has been in U-Boot since the
beginning, but the meaning of it has changed over time. Allow the
default to be set for any value, including -ve ones. This allows
(for example) CONFIG_ENV_IS_NOWHERE to have values for bootdelay in
its compiled in environment.

The only thing this changes is where the default for bootdelay can be
fetched from; before this change you get a compiled in default, after
you'll pull it from the default value in the environment, but both values
will be the same. Also if there's a value set in the environment then
that will take precedence (as before).

Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
2018-07-20 15:37:44 -04:00
Heinrich Schuchardt
992c1db455 drivers: rtc: resolve year 2038 problem in rtc_to_tm
Our implementation of rtc_to_tm() cannot handle dates of more than
0x7fffffff seconds after 1970-01-01.

Adopt the Linux kernel implementation.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2018-07-19 17:03:36 -04:00
Hannes Schmelzer
fbc7c7decf board/BuR/brppt1: convert brppt1 boards to driver model
- add a devicetree for each variant (mmc, spi, nand)
- drop unneeded code from board and bur/common
- drop unneeded stuff from config header files
- minor adaptions to be compliant with driver model (requesting gpio,..)
- harmonize the commandset over all brppt1 targets

Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at>
2018-07-19 17:03:35 -04:00
Hannes Schmelzer
73e9db22ab board/BuR/brppt1: implement more flexible boot process
With this commit we do:

- set the bootdelay in all brppt1 defconfigs to 0, this makes
development easier, since we can break into serial console.

- move CONFIG_BOOTCOMMAND from header file to defconfig

- introduce b_mode variable for selecting the final boot-target.
This b_mode represents the boot-switch, which can found on most b&r
targets. On the brppt1 this boot-switch is derived from some gpio and
the bootcounter within the RTC block, making it so possible to force
a boot-target (as example for repair-case).

- refactor the environment for booting new flexible way
primary we want to get some bootscr.img within the mass-storage,
this script then loads everything needed for the boot.
For legacy reason we implement the t30lgcy#x boot targets, booting the
already delivered linux-images.

- make space for the cfgscr within mtdparts on brppt1_nand

Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at>
2018-07-19 17:03:35 -04:00
Hannes Schmelzer
1d46986601 board/BuR/brppt1: drop dead code (CONFIG_SPL_OS_BOOT)
The falcon mode was never used on this board, there is also no plan to
use it. So drop this dead code.

Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at>
2018-07-19 17:03:34 -04:00
Hannes Schmelzer
9596367970 board/BuR/brppt1: drop LCD-support
On this linux target long time ago the OS is using DRM driver for
handling video output, the pre initialization of u-boot and the display
summary screen is obsolete. With this patch we drop the LCD-support from
thisd board.

Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at>
2018-07-19 17:03:33 -04:00
Hannes Schmelzer
e31fb4db36 board/BuR: drop devicetree loading and lcd setup for linux-targets
This patch  drops the lcd-screen setup, the summary screen and getting
mac-addresses based on a previous loaded device-tree for linux targets.
Selecting those linux target is simple, since we have only the brppt1.

In detail we do:
- drop the common lcd-setup code which relys on a fdt_blob
- drop the common dtb loading mechanism
- drop the now obsolete CONFIG_USE_FDT from board header and whitelist.

Signed-off-by: Hannes Schmelzer <oe5hpm@oevsv.at>
2018-07-19 17:03:33 -04:00
Ramon Fried
7b384eccc7 dm: SMEM (Shared memory) uclass
This is a uclass for Shared memory manager drivers.

A Shared Memory Manager driver implements an interface for allocating
and accessing items in the memory area shared among all of the
processors.

Signed-off-by: Ramon Fried <ramon.fried@gmail.com>

Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2018-07-19 16:31:37 -04:00
Heinrich Schuchardt
b19886b946 ARM: qemu-arm: enable RTC
QEMU provides an emulated ARM AMBA PrimeCell PL031 RTC.

The patch sets the base address in the board include file according to the
definition in hw/arm/virt.c of the QEMU source. It defines the Kconfig
option for the existing driver, and enables the RTC driver in
qemu_arm64_defconfig and qemu_arm_defconfig as well as the date command.

We need an RTC to provide the GetTime() runtime service in the UEFI
subsystem.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Tuomas Tynkkynen <tuomas.tynkkynen@iki.fi>
Tested-by: Tuomas Tynkkynen <tuomas.tynkkynen@iki.fi>
Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
2018-07-19 16:31:37 -04:00
Christophe Kerello
844f9bf1ee power: regulator: stpmu1: add power off delay
This patch adds a delay when regulators are disabled.
This delay is set to 5 ms to cover all use cases.
The worst use case actually seen is during a SD card power cycle.

Signed-off-by: Christophe Kerello <christophe.kerello@st.com>
Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
2018-07-19 16:31:36 -04:00
Thomas McKahan
eee45b4f54 boards: amlogic: Add FriendlyElec NanoPi K2 board support
This adds platform code for the FriendlyElec NanoPi K2 board based on a
Meson GXBB (S905) SoC with the Meson GXBB configuration.

This initial submission only supports:
- UART
- MMC/SDCard
- Ethernet
- Reset Controller
- Clock controller

Cc: Yuefei Tan <yftan@friendlyarm.com>
Signed-off-by: Thomas McKahan <tonymckahan@gmail.com>
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
2018-07-19 16:17:58 -04:00
Yaniv Levinsky
c5d548a9f8 env: common: accept flags on reset to default env
The function set_default_env() sets the hashtable flags for import_r().
Formally set_default_env() doesn't accept flags from its callers. In
practice the caller can (un)set the H_INTERACTIVE flag, but it has to be
done using the first character of the function's string argument. Other
flags like H_FORCE can't be set by the caller.

Change the function to accept flags argument. The benefits are:
1. The caller will have to explicitly set the H_INTERACTIVE flag,
   instead of un-setting it using a special char in a string.
2. Add the ability to propagate flags from the caller to himport(),
   especially the H_FORCE flag from do_env_default() in nvedit.c that
   currently gets ignored for "env default -a -f" commands.
3. Flags and messages will not be coupled together. A caller will be
   able to set flags without passing a string and vice versa.

Please note:
The propagation of H_FORCE from do_env_default() does not introduce any
functional changes, because currently himport_r() is set to destroy the
old environment regardless if H_FORCE flag is set or not. More changes
are needed to utilize the propagation of H_FORCE.

Signed-off-by: Yaniv Levinsky <yaniv.levinsky@compulab.co.il>
Acked-by: Igor Grinberg <grinberg@compulab.co.il>
2018-07-19 16:17:58 -04:00
Yaniv Levinsky
477f8116d5 cmd: nvedit: propagate envflag to set_default_vars
The env_flag in do_env_default() doesn't get propagated and therefore
gets ignored by himport_r(). This breaks to ability to "forcibly" reset
variables to their default values using the environment command.

Scenario example of the problem:
	# setenv kernel uImage
	# setenv .flags kernel:so
	# env default -f kernel
	## Error: Can't overwrite "kernel"
	himport_r: can't insert "kernel=zImage" into hash table

Change the call path so it will pass the flag correctly.

Signed-off-by: Yaniv Levinsky <yaniv.levinsky@compulab.co.il>
Acked-by: Igor Grinberg <grinberg@compulab.co.il>
2018-07-19 16:17:58 -04:00
Ramon Fried
8d54579072 test: Add ut_assertnull macro
Add ut_assertnull macro to include/test/ut.h
For testing of functions that returns NULL on errors.

Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2018-07-19 16:17:58 -04:00
Michal Simek
a133b3ac32 arm64: zynqmp: Setup ENV_SIZE via Kconfig for mini targets
Mini targets are using different ENV_SIZE then standard one that's why
defconfigs should be updated to simplify config files.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:56 +02:00
Siva Durga Prasad Paladugu
14ed50a4bf arm64: zynqmp: Add QSPI flash mini u-boot configuration
Add configuration files/dtses for mini u-boot configuration
which runs on smaller footprint of internal memory. This
configuration has only required qspi flash support and it
uses DCC as serial.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:56 +02:00
Michal Simek
bb8920ed77 arm: zynq: Setup ENV_SIZE via Kconfig
Simplify zynq_cse config by setting up ENV_SIZE via Kconfig.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:56 +02:00
Vipul Kumar
2a30809cae env: Added support to save env to spi through Kconfig
This patch added support to enable CONFIG_ENV_SIZE, CONFIG_ENV_OFFSET
and CONFIG_ENV_SECT_SIZE through Kconfig for Zynq and Zynqmp.

Signed-off-by: Vipul Kumar <vipul.kumar@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:56 +02:00
Siva Durga Prasad Paladugu
e4655aa240 arm: zynq: Dont define SDRAM_BASE and SDRAM_SIZE in .h
Remove the SDRAM_BASE and SDRAM_SIZE as it can now get these
details from DT.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2018-07-19 10:49:56 +02:00
Siva Durga Prasad Paladugu
12308b128f lib: fdtdec: Rename routine fdtdec_setup_memory_size()
This patch renames the routine fdtdec_setup_memory_size()
to fdtdec_setup_mem_size_base() as it now fills the
mem base as well along with size.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2018-07-19 10:49:56 +02:00
Michal Simek
f4da871a7f microblaze: Remove XILINX_SPI_FLASH_BASEADDR logic
XILINX_SPI_FLASH_BASEADDR logic has been converted to DM that's why
there is no reason to depend on this address anymore.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:56 +02:00
Michal Simek
4a69366967 microblaze: Convert generic platform to DM gpio
Converting GPIO to DM requires to do changes in reset subsystem
that's why support for Microblaze soft reset via sysreset and GPIO
sysreset support was added.
These two patches enables enabling GPIO DM.
Microblaze soft reset is bind at last reset method.

GPIO reset is handled via sysreset with adding this fragment to DT.

gpio-restart {
	compatible = "gpio-restart";
	gpios = <&reset_gpio 0 0 0>;
	/* 3rd cell ACTIVE_HIGH = 0, ACTIVE_LOW = 1 */
};

hard-reset-gpio property is not documented and also handled.
Conversion is required.

Unfortunately do_reset is required for SPL that's why use only soft
microblaze reset for now.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:55 +02:00
Shreenidhi Shedi
88811bb5a1 microblaze: Delete Xilinx watchdog related macros
These macros are not required anymore. These will be taken from
configuration file.

Signed-off-by: Shreenidhi Shedi <yesshedi@gmail.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:55 +02:00
Shreenidhi Shedi
35912528a8 microblaze: Cosmetic changes in Microblaze related files
Signed-off-by: Shreenidhi Shedi <yesshedi@gmail.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:55 +02:00
Michal Simek
3c3dee373a arm64: zcu100: Enable USB host ether and ASIX via defconfig
There is no reason to keep these configs in platform config file.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:54 +02:00
Siva Durga Prasad Paladugu
37e3a36a54 xilinx: zynq: Add support to secure images
This patch basically adds two new commands for loadig secure
images.
1. zynq rsa adds support to load secure image which can be both
   authenticated or encrypted or both authenticated and encrypted
   image in xilinx bootimage(BOOT.bin) format.
2. zynq aes command adds support to decrypt and load encrypted
   image back to DDR as per destination address. The image has
   to be encrypted using xilinx bootgen tool and to get only the
   encrypted image from tool use -split option while invoking
   bootgen.

Signed-off-by: Siva Durga Prasad Paladugu <siva.durga.paladugu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2018-07-19 10:49:54 +02:00
Michal Simek
5da7b8cb08 hush: Remove default CONFIG_SYS_PROMPT_HUSH_PS2 setting from board files
There is no reason to define default option for this macro which is
already done in common/cli_hush.c.

  86 #ifndef CONFIG_SYS_PROMPT_HUSH_PS2
  87 #define CONFIG_SYS_PROMPT_HUSH_PS2      "> "
  88 #endif

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: York Sun <york.sun@nxp.com>
2018-07-19 10:49:53 +02:00
Michal Simek
27eb7bce39 common: command: Handle USAGE failure separately
command_ret_t enum contains 3 return values but only two are handled
now. Extend cmd_process_error() and handle CMD_RET_USAGE separately.

These commands are affected by this change.
cmd/demo.c
cmd/efi.c
cmd/gpio.c
cmd/qfw.c
cmd/x86/fsp.c
test/dm/cmd_dm.c

And scripts shouldn't be affected because return value is not 0. But
every command implementation can choose what it is correct to pass.
I would expect that RET_USAGE is called when parameters are not
correctly passed (have incorrect value, missing parameters)
and RET_FAILURE when correct parameters are passed but command fails.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Simon Glass <sjg@chromum.org>
2018-07-19 10:49:53 +02:00