Commit Graph

42992 Commits

Author SHA1 Message Date
xypron.glpk@gmx.de
f59a3b21f6 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>
2017-05-05 16:45:57 -04:00
xypron.glpk@gmx.de
d27e35f256 relocate-rela: add missing va_end()
va_start must always be matched by va_end.

The problem was indicated by cppcheck.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2017-05-05 16:45:57 -04:00
xypron.glpk@gmx.de
05d887b461 lib: circbuf: avoid possible null pointer dereference
We should not first dereference p and afterwards assert that is
was not NULL. Instead do the assert first.

The problem was indicated by cppcheck.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2017-05-05 16:45:57 -04:00
xypron.glpk@gmx.de
1275a44e2f arm64: mvebu: incorrect check of fdt address cells
In dram_init_banksize there seems to be a typo concerning
a plausibility check of the fdt.
Testing sc > 2 twice does not make any sense.

The problem was indicated by cppcheck.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2017-05-05 16:45:56 -04:00
xypron.glpk@gmx.de
cc93834dee meson: gxbb: increase CONFIG_SYS_BOOTM_LEN
A feature rich Linux kernel needs more than 8 MiB.
Hence enlarge CONFIG_SYS_BOOTM_LEN to 64 MiB for the GXBB systems.
As all known GXBB systems have at least 512 MiB of RAM this poses no problem.

Cc: Andreas Färber <afaerber@suse.de>
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2017-05-05 16:45:52 -04:00
Tom Rini
27a198768e Merge branch 'master' of git://git.denx.de/u-boot-spi 2017-05-05 16:45:30 -04:00
Suniel Mahesh
2f54205829 drivers: spi: Remove duplicate .probe method
.probe method has been assigned twice when declaring
a driver with U_BOOT_DRIVER(). Removed one of them.
Here is the last commit which had the duplicate entry:
"spi: omap3: Convert to driver model"
(sha1: 77b8d04854)

Signed-off-by: Suniel Mahesh <suniel.spartan@gmail.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>
2017-05-03 11:52:16 +05:30
Moritz Fischer
ac6991fb5f zynq: spi: Honour the activation / deactivation delay
This is not currently implemented. Add support for this so that the
Chrome OS EC can be used reliably.

Signed-off-by: Moritz Fischer <moritz.fischer@ettus.com>
Acked-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Jagan Teki <jagan@openedev.com>
2017-05-03 11:03:04 +05:30
Wenyou Yang
61a77ce1d5 spi: atmel: check GPIO validity before using cs_gpios
Before using the cs_gpio, check if the GPIO is valid or not.

Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>
2017-05-03 10:58:54 +05:30
Tom Rini
a63d800196 Prepare v2017.05-rc3
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-05-01 19:54:41 -04:00
xypron.glpk@gmx.de
7880dcf04c odroid-c2: README: MMC is supported
Mention eMMC and microSD as supported devices.

They have been enabled with patch
d0c5c8d529
odroid-c2: enable new Meson GX MMC driver in board defconfig
which was accepted for u-boot-mmc.git.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2017-05-01 12:58:35 -04:00
xypron.glpk@gmx.de
d03857485e meson: gxbb: change ramdisk_addr_r
0x10000000 is the start of a 2 MiB area used by the
ARM Trusted Firmware (BL31).

See
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git/tree/arch/arm64/boot/dts/amlogic/meson-gx.dtsi?id=refs/tags/v4.10.10

So we should not load the ramdisk here.

The legacy Ubuntu image for the Odroid C2 comes with the
following line in boot.ini:
setenv initrd_loadaddr "0x13000000"

See
http://odroid.in/ubuntu_16.04lts/ubuntu64-16.04-minimal-odroid-c2-20160815.img.xz
http://deb.odroid.in/c2/pool/main/u/u-boot/u-boot_20170226-752a100-8_arm64.deb

So let's use the same address.

With the patch booting Linux with booti succeeds on an Odroid C2,
without the patch Linux hangs.

Cc: Andreas Färber <afaerber@suse.de>
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
Tested-by: Vagrant Cascadian <vagrant@debian.org>
2017-05-01 12:38:17 -04:00
xypron.glpk@gmx.de
1f677e4266 meson: gxbb: enable MMC as boot target
To enable automatic booting from SD card or eMMC the MMC
devices 0, 1, and 2 are added to the BOOT_TARGET_DEVICES.

Booting from SD card, eMMC, and DHCP are tried in sequence.
A missing or failing device is gracefully handled.

Cc: Andreas Färber <afaerber@suse.de>
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Tested-by: Vagrant Cascadian <vagrant@debian.org>
Reviewed-by: Andreas Färber <afaerber@suse.de>
Tested-by: Andreas Färber <afaerber@suse.de>
2017-05-01 11:49:48 -04:00
Tom Rini
2681e78a5e configs: Re-sync
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-05-01 11:44:12 -04:00
Tom Rini
57ba664ebf scripts/config_whitelist.txt: Re-sync
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-05-01 11:44:03 -04:00
Fabio Estevam
f73be5f1de warp7: MAINTAINERS: Add warp7_secure_defconfig entry
Add warp7_secure_defconfig entry to avoid the following warning:

WARNING: no maintainers for 'warp7_secure'

Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
2017-05-01 09:19:52 -04:00
Tom Rini
26d61195f8 fdt: Move fdt_fixup_ethernet to a common place
With 3f66149d9f we no longer have a common call fdt_fixup_ethernet.
This was fine to do on PowerPC as they largely had calls already in
ft_cpu_fixup.  On ARM however we largely relied on this call.  Rather
than introduce a large number of changes to ft_cpu_fixup /
ft_board_fixup we recognize that this is a common enough call that we
should be doing it in a central location.  Do it early enough that we
can do any further updates in ft_cpu_fixup / ft_board_fixup.

Cc: Gerd Hoffmann <kraxel@redhat.com>
Cc: Chen-Yu Tsai <wens@csie.org>
Cc: Maxime Ripard <maxime.ripard@free-electrons.com>
Cc: Thomas Chou <thomas@wytron.com.tw> (maintainer:NIOS)
Cc: York Sun <york.sun@nxp.com> (maintainer:POWERPC MPC85XX)
Cc: Stefan Roese <sr@denx.de> (maintainer:POWERPC PPC4XX)
Cc: Simon Glass <sjg@chromium.org>
Cc: Joakim Tjernlund <Joakim.Tjernlund@infinera.com>
Fixes: 3f66149d9f ("Remove extra fdt_fixup_ethernet() call")
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Stefan Roese <sr@denx.de>
Acked-by: York Sun <york.sun@nxp.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-05-01 09:11:59 -04:00
Chris Packham
c9032ce168 cmd: add Kconfig option for 'date' command
Signed-off-by: Chris Packham <judge.packham@gmail.com>
[trini: default y if DM_RTC, re-sync]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-05-01 09:04:56 -04:00
Simon Glass
ae189ba1ac Drop the pdsp188x driver
This is not used in U-Boot.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 13:41:02 -04:00
Simon Glass
00aff7bbc3 powerpc: Drop configs/manroland
This is not used in U-Boot. Drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 13:41:02 -04:00
Simon Glass
93d66ee566 Convert CONFIG_CMD_DISPLAY to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_DISPLAY

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 13:41:01 -04:00
Simon Glass
3bd25cb512 Convert CONFIG_CMD_DIAG to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_DIAG

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: imply CMD_DIAG on some keymile configs]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 13:41:01 -04:00
Simon Glass
10c01337d3 Kconfig: Drop CONFIG_CMD_DFL
This option is not used in U-Boot. Drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 13:41:00 -04:00
Simon Glass
d569c95ec0 Convert CONFIG_CMD_DEKBLOB to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_DEKBLOB

Note: This option does not seem to actually be enabled by any board.

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: imply under SECURE_BOOT for mx5/6/7]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 13:41:00 -04:00
Simon Glass
279e7c491b Kconfig: Drop CONFIG_CMD_DEFAULTENV_VARS
This option does not exist in U-Boot. Drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 13:41:00 -04:00
Simon Glass
80e44cfe10 fs: Kconfig: Add a separate option for FS_CRAMFS
Rather than using CMD_CRAMFS for both the filesystem and its command, we
should have a separate option for each. This allows us to enable CRAMFS
support without the command, if desired, which reduces U-Boot's size
slightly.

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: imply FS_CRAMFS for keymile]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 13:40:59 -04:00
Simon Glass
9707274718 fs: Convert CONFIG_CMD_CRAMFS to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_CRAMFS

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: imply CMD_CRAMFS for keymile]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 13:40:59 -04:00
Simon Glass
d315628edb Convert CONFIG_CMD_CLK to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_CLK

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: imply CMD_CLK on ARCH_ZYNQ]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 13:40:58 -04:00
Simon Glass
3d0aeb9090 Drop CONFIG_CMD_CLEAR
This option is not used in U-Boot. Drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 13:40:58 -04:00
Simon Glass
854fcd5537 Convert CONFIG_CMD_CHIP_CONFIG to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_CHIP_CONFIG

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 13:40:57 -04:00
Simon Glass
deb9599915 fs: Kconfig: Add a separate config for FS_CBFS
Rather than using CMD_CBFS for both the filesystem and its command, we
should have a separate option for each. This allows us to enable CBFS
support without the command, if desired, which reduces U-Boot's size
slightly.

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: imply FS_CBFS on SYS_COREBOOT]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 13:40:57 -04:00
Simon Glass
d66a10fc00 fs: Convert CONFIG_CMD_CBFS to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_CBFS

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: imply CMD_CBFS on SYS_COREBOOT]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 13:40:56 -04:00
Simon Glass
983b103f1c Convert CONFIG_SYS_WHITE_ON_BLACK to Kconfig
This converts the following to Kconfig:
   CONFIG_SYS_WHITE_ON_BLACK

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Make this default y on various SoCs]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 13:40:13 -04:00
Simon Glass
4893e34b00 Convert CONFIG_CMD_BSP to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_BSP

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 10:30:10 -04:00
Simon Glass
0f7102588c Convert CONFIG_CMD_BMP to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_BMP

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Add depends on LCD || DM_VIDEO || VIDEO]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 10:30:08 -04:00
Simon Glass
218257b01a Convert CONFIG_CMD_BMODE to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_BMODE

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Make this default y and depend on mx5/6/7]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 10:30:06 -04:00
Simon Glass
c04b9b3440 Convert CONFIG_CMD_BLOB to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_BLOB

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Add imply CMD_BLOB under CHAIN_OF_TRUST]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 10:30:03 -04:00
Simon Glass
ac20a1b21c Convert CONFIG_CMD_BEDBUG to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_BEDBUG

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 10:30:02 -04:00
Simon Glass
ac60e46e7d Convert CONFIG_CMD_BAT to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_BAT

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 10:30:00 -04:00
Simon Glass
4848d89d1f ti816x_evm: Change CONFIG_CMD_ASKEN to CONFIG_CMD_ASKENV
This looks like a typo. Fix it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 10:29:58 -04:00
Simon Glass
b1a873df0a Convert CONFIG_CMD_AES et al to Kconfig
This converts the following to Kconfig:
   CONFIG_CMD_AES
   CONFIG_AES

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Add select AES to CMD_AES]
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 10:29:55 -04:00
Simon Glass
92572ecf80 power: Drop CONFIG_PMIC
This option is not used in U-Boot. Drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 10:29:54 -04:00
Simon Glass
0fd28b1f0e power: Drop CONFIG_I2C_PMIC
This is only used by one board and should not be a CONFIG option. Instead
it should use the driver model pmic framework. For now, just move the
setting into the only board that uses it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 10:29:53 -04:00
Simon Glass
bdf25a5e04 power: Convert CONFIG_PMIC_AS3722 to Kconfig
This converts the following to Kconfig:
   CONFIG_PMIC_AS3722

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 10:29:50 -04:00
Simon Glass
2838c07f47 power: Move as3722 pmic to pmic/ directory
Most of the PMICs are in the drivers/power/pmic/ directory. Move this one
there.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 10:29:49 -04:00
Simon Glass
56aceaf282 power: Rename CONFIG_AS3722_POWER to CONFIG_PMIC_AS3722
Before converting this to Kconfig, rename it to match the other PMICs.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-04-30 10:29:47 -04:00
Tom Rini
29ec685883 arm: Re-sync ARCH_MX5 / MX51 / MX53 CONFIG options
A few boards had not been fully re-synced with CONFIG_ARCH_MX5 / CONFIG_MX51 /
CONFIG_MX53 being in Kconfig.  Do so now.

Signed-off-by: Tom Rini <trini@konsulko.com>
2017-04-30 10:29:38 -04:00
Tom Rini
1e6776000e Xilinx fixes for v2017.05
- Fix usbotg on Miami board
 - Cleanup zc1751 defconfig
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iEYEABECAAYFAlkB14cACgkQykllyylKDCGmBwCdGDprha3mbfzUb6ZriITwz75A
 CZoAn3zZ1w/Z4qUwxw6MJ1k6GzrEqxQt
 =/HtJ
 -----END PGP SIGNATURE-----

Merge tag 'xilinx-fixes-for-v2017.05' of git://www.denx.de/git/u-boot-microblaze

Xilinx fixes for v2017.05

- Fix usbotg on Miami board
- Cleanup zc1751 defconfig
2017-04-27 16:49:19 -04:00
Lokesh Vutla
509b498a50 ext4: Fix comparision of unsigned expression with < 0
In file ext4fs.c funtion ext4fs_read_file() compares an
unsigned expression with < 0 like below

	lbaint_t blknr;
	blknr = read_allocated_block(&(node->inode), i);
	if (blknr < 0)
		return -1;

blknr is of type ulong/uint64_t. read_allocated_block() returns
long int. So comparing blknr with < 0 will always be false. Instead
declare blknr as long int.

Similarly ext4/dev.c does a similar comparison. Drop the redundant
comparison.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2017-04-27 16:49:09 -04:00
Lokesh Vutla
8a707bafe0 MAINTAINERS: Update for Keystone2 secure devices
Update Keystone2 secure device configs under
"TI SYSTEM SECURITY". Without this buildman keeps complaining
about the status of these boards.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Acked-by: Andrew F. Davis <afd@ti.com>
2017-04-27 16:49:08 -04:00