Commit Graph

42100 Commits

Author SHA1 Message Date
Mario Six 1f6c8a5733 tools: kwbimage: Fix unchecked return value and fd leak
The return value of fstat was not checked in kwbimage, and in the case
of an error, the already open file was not closed. Fix both errors.

Reported-by: Coverity (CID: 155971)
Reported-by: Coverity (CID: 155969)
Signed-off-by: Mario Six <mario.six@gdsys.cc>
Signed-off-by: Stefan Roese <sr@denx.de>
2017-02-17 10:15:21 +01:00
Tom Rini 85d0bea153 Prepare v2017.03-rc2
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-02-13 11:47:45 -05:00
Tom Rini a8d052b500 Xilinx fixes for v2017.03
- defconfig alignment
 - Topic.nl board updates
 - Minor microblaze comment fix
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iEYEABECAAYFAlihweUACgkQykllyylKDCFTZACfScfvrJoK1NO89R89JE6iH6iX
 7y4AnA5wwTrqrOL+GOFPgco+mhCJj6Bo
 =w3BL
 -----END PGP SIGNATURE-----

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

Xilinx fixes for v2017.03

- defconfig alignment
- Topic.nl board updates
- Minor microblaze comment fix
2017-02-13 09:35:40 -05:00
Masahiro Yamada c77c7db58e i2c: sandbox: remove code snippet from Kconfig help
With the Kconfig re-sync with Linux 4.10, characters such as
'}', ';' in Kconfig help message cause warnings:

$ make defconfig
*** Default configuration is based on 'sandbox_defconfig'
drivers/i2c/Kconfig:132:warning: ignoring unsupported character '}'
drivers/i2c/Kconfig:132:warning: ignoring unsupported character ';'

Drop the Device Tree fragment from the help.

Acked-by: Heiko Schocher <hs@denx.de>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2017-02-13 07:18:25 -05:00
Masahiro Yamada bf7ab1e70f kconfig: re-sync with Linux 4.10
Re-sync all files under the scripts/kconfig directory with
Linux 4.10.

Some parts include U-Boot own modification.  I made sure to not
revert the following commits:

 5b8031ccb4 ("Add more SPDX-License-Identifier tags")
 192bc6948b ("Fix GCC format-security errors and convert sprintfs.")
 da58dec866 ("Various Makefiles: Add SPDX-License-Identifier tags")
 20c20826ef ("Kconfig: Enable usage of escape char '\' in string values")

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2017-02-12 14:31:25 -05:00
Masahiro Yamada 554c73c025 flash: compile common/flash.c iif CONFIG_MTD_NO_FLASH is enabled
The whole of common/flash.c is guarded by #if defined() ... #endif.
Move the conditional to common/Makefile.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2017-02-12 14:30:31 -05:00
Masahiro Yamada e856bdcfb4 flash: complete CONFIG_SYS_NO_FLASH move with renaming
We repeated partial moves for CONFIG_SYS_NO_FLASH, but this is
not completed. Finish this work by the tool.

During this move, let's rename it to CONFIG_MTD_NOR_FLASH.
Actually, we have more instances of "#ifndef CONFIG_SYS_NO_FLASH"
than those of "#ifdef CONFIG_SYS_NO_FLASH".  Flipping the logic will
make the code more readable.  Besides, negative meaning symbols do
not fit in obj-$(CONFIG_...) style Makefiles.

This commit was created as follows:

[1] Edit "default n" to "default y" in the config entry in
    common/Kconfig.

[2] Run "tools/moveconfig.py -y -r HEAD SYS_NO_FLASH"

[3] Rename the instances in defconfigs by the following:
  find . -path './configs/*_defconfig' | xargs sed -i \
  -e '/CONFIG_SYS_NO_FLASH=y/d' \
  -e 's/# CONFIG_SYS_NO_FLASH is not set/CONFIG_MTD_NOR_FLASH=y/'

[4] Change the conditionals by the following:
  find . -name '*.[ch]' | xargs sed -i \
  -e 's/ifndef CONFIG_SYS_NO_FLASH/ifdef CONFIG_MTD_NOR_FLASH/' \
  -e 's/ifdef CONFIG_SYS_NO_FLASH/ifndef CONFIG_MTD_NOR_FLASH/' \
  -e 's/!defined(CONFIG_SYS_NO_FLASH)/defined(CONFIG_MTD_NOR_FLASH)/' \
  -e 's/defined(CONFIG_SYS_NO_FLASH)/!defined(CONFIG_MTD_NOR_FLASH)/'

[5] Modify the following manually
  - Rename the rest of instances
  - Remove the description from README
  - Create the new Kconfig entry in drivers/mtd/Kconfig
  - Remove the old Kconfig entry from common/Kconfig
  - Remove the garbage comments from include/configs/*.h

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2017-02-12 14:30:25 -05:00
Tom Rini a931e9975b Merge git://git.denx.de/u-boot-samsung 2017-02-11 10:38:40 -05:00
Tom Rini b16f6804b4 Merge git://git.denx.de/u-boot-rockchip 2017-02-11 10:38:21 -05:00
Michal Simek 1d82e2c15c microblaze: Fix endif macro command
Use correct name in endif comment.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2017-02-10 13:59:36 +01:00
Mike Looijmans 1520fe60d9 configs/topic_miami.h: Correct kernel_size in default environment
The kernel partition in QSPI is 0x440000 large, not 0x400000. Fix this
in the environment, otherwise the kernel will fail to boot if it occupies
more space.

Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2017-02-10 13:59:17 +01:00
Mike Looijmans c38e981707 topic_miami(plus) defconfig: Enable DFU RAM support
Allow sending firmware to RAM. Without this, the DFU support was not
of much use.

Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2017-02-10 13:59:17 +01:00
Mike Looijmans d018db40a3 topic_miami_defconfig: Remove NFS and NET support
On the miami board, ethernet is accessed via logic. To use it, one
would have to program logic first and then set up the rgmii conversion
block as well. Not likely to ever be used, so disable network support
by default to save some space.

Signed-off-by: Mike Looijmans <mike.looijmans@topic.nl>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2017-02-10 13:58:25 +01:00
Michal Simek 2e0583b67e xilinx: Align defconfig with current Kconfig order
Keep all defconfig sorted to ensure the smallest diff.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2017-02-10 13:57:35 +01:00
Simon Glass 5d3be0f81c exynos: Drop large alignment for SDRAM parameters
We don't ever search for these so there is no need for a 4KB alignment.
It just wastes space.

Drop this and use the standard 4-byte alignment.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
2017-02-10 18:51:51 +09:00
Tom Rini f1cc97764b Merge branch 'master' of git://git.denx.de/u-boot-video 2017-02-09 14:54:09 -05:00
Eddie Cai 6f27976455 rockchip: rename miniarm to tinker board
Miniarm is the internal project code. Now it is officially named Tinker board.
So rename it.

Signed-off-by: Eddie Cai <eddie.cai@rock-chips.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-09 12:10:59 -07:00
Romain Perier 1caec07e5c rockchip: Enable ETH address randomization for the firefly-rk3288
This commit enables ethernet MAC address randomization on the
firefly-rk3288. It removes the error at startup 'ethernet@ff290000
address not set'.

Signed-off-by: Romain Perier <romain.perier@collabora.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-09 12:10:59 -07:00
Jacob Chen 5235753d15 rockchip: firefly: configs: use spl back to brom
Keep it same with other boards otherwise i have to write special script for it..

Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-09 12:10:59 -07:00
Jacob Chen 3d1bf166bf rockchip: configs: move env offset to common header
To reduce redundant code.

Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-09 12:10:59 -07:00
Simon Glass f568ac219c rockchip: Correct MAINTAINER entry for chromebook_minnie
This is wrong at present, so genboardscfg.py gives the following warnings:

WARNING: no status info for 'chromebook_minnie'
WARNING: no maintainers for 'chromebook_minnie'

Fix it.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-02-09 12:10:59 -07:00
Jacob Chen a8830a1247 rockchip: dts: rk3288: correct sdram setting for miniarm
miniarm board use lpddr3

Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
Acked-by: Simon Glass <sjg@chromium.org>
Added 'rockchip:' prefix to subject:
Signed-off-by: Simon Glass <sjg@chromium.org>

Change-Id: I84c3679dab2dbd8d01c1ebfd22220946d07c03cd
2017-02-09 12:10:59 -07:00
Tom Rini 2a48b3a2c4 omap_hsmmc.c: Fix build warning on non-omap3
It was incorrect to always include "asm/arch-omap3/mux.h" constantly.
This introduced warnings on non-omap3 where certain values will conflict
between the various families.  Conditionally guard the inclusion in
order to correct the problem.

Fixes: 6aca17c9b7 ("drivers: mmc: omap_hsmmc: Fix IO Buffer on OMAP36xx")
Signed-off-by: Tom Rini <trini@konsulko.com>
2017-02-09 13:41:28 -05:00
Tom Rini e1a71f8b33 Merge branch 'master' of git://git.denx.de/u-boot-net 2017-02-09 11:56:35 -05:00
Tom Rini 6f57b19857 Merge branch 'master' of git://git.denx.de/u-boot-mmc 2017-02-09 11:56:19 -05:00
Tom Rini 0959649dc6 omap3_logic: Switch to simple malloco in SPL
To save more space, switch to simple malloc here.

Signed-off-by: Tom Rini <trini@konsulko.com>
2017-02-09 11:55:57 -05:00
Tom Rini e0dff9b860 qemu-x86_64_defconfig: Disable CONFIG_BOARD_EARLY_INIT_F
The qemu-x86* targets do not want to enable this.

Signed-off-by: Tom Rini <trini@konsulko.com>
2017-02-09 08:52:18 -05:00
Fiach Antaw a0269bb6e8 mmc: init mmc block devices on probe
MMC devices accessed exclusively via the driver model were not
being initialized before being exposed as block devices, causing
issues in scenarios where the MMC device is first accessed via the
uclass block interface.

Signed-off-by: Fiach Antaw <fiach.antaw@uqconnect.edu.au>
2017-02-09 20:37:06 +09:00
Adam Ford 6aca17c9b7 drivers: mmc: omap_hsmmc: Fix IO Buffer on OMAP36xx
On the OMAP36xx/37xx the CONTROL_WKUP_CTRL register has
a field (bit 6) named GPIO_IO_PWRDNZ.  If 0, the IO buffers which
are related to GPIO_126, 127 and 129 are disabled. Some boards may
need this for MMC. After the PBIAS is configured, this bit should
be set high to enable these GPIO pins.

Signed-off-by: Adam Ford <aford173@gmail.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2017-02-09 20:37:06 +09:00
Jaehoon Chung d14f1d511a mmc: ftsdc021_sdhci: remove the ftsdc021_sdhci.c
ftsdc021_sdhci.c is dead file.
There is no reason to maintain this host controller.
Removes the entire ftsdc021_sdhci.c.

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2017-02-09 20:37:05 +09:00
Jaehoon Chung 02ad33aa3a mmc: mmc-uclass: use the fixed devnum with alias node
If there are alias nodes as "mmc", use the devnum as alias index
number.
This patch is for fixing a problem of Exynos4 series.
Problem is the below thing.

Current legacy mode:
EXYNOS DWMMC: 0, SAMSUNG SDHCI: 1

After using DM:
SAMSUNG SDHCI: 0, EXYNOS DWMMC: 1

Dev index is swapped.
Then u-boot can't find the kernel image..because it is already set to 0 as mmcdev.
If change from legacy to DM, also needs to touch all exynos4 config file.
For using simply, just supporting the fixed devnum with alias node is better than it.

Usage:
alaise {
	....
	mmc0 = &sdhci2; /* eMMC */
	mmc1 = &sdhci1; /* SD */
	...
}

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-09 20:37:05 +09:00
Jaehoon Chung 22940af121 arm: dts: trats: add the pmic node for using DM
To use driver-model adds the pmic node for max8997.
This is used as kernel device-tree in Linux.

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-09 14:28:53 +09:00
Jaehoon Chung 1a5a05dade power: pmic: add the max8997 controller for DM
Add the max8997 controller for Driver model.
Exynos4210 is using max8997 pmic controller.
(pmic_max8997.c should be deprecated.)

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-09 14:28:37 +09:00
Tom Rini 576a085c1d Merge branch 'master' of git://git.denx.de/u-boot-socfpga 2017-02-08 22:04:32 -05:00
John Haechten a5fd13ad19 net: phy: MSCC Add Support for VSC8530-VSC8531-VSC8540-VSC8541
Signed-off-by: John Haechten <john.haechten@microsemi.com>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2017-02-08 16:32:58 -06:00
Tom Rini 21342d4aed Merge git://git.denx.de/u-boot-dm 2017-02-08 16:24:44 -05:00
Robert P. J. Day 7582ddce13 GPIO: Correct doc typo "confguration" -> "configuration"
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
2017-02-08 16:24:29 -05:00
Lars Poeschel 55c854c612 Remove unused symbol CONGIG_CMD_STORAGE from board configs
Albeit it's a typo, neither CONGIG_CMD_STORAGE nor CONFIG_CMD_STORAGE
are used anywhere, so remove the define from the board configs.

Signed-off-by: Lars Poeschel <poeschel@lemonage.de>
Reviewed-by: Tom Rini <trini@konsulko.com>
2017-02-08 16:24:28 -05:00
Masahiro Yamada e9d33e7326 cmd: move CONFIG_CMD_UNZIP and CONFIG_CMD_ZIP to Kconfig
CONFIG_CMD_ZIP is not defined by any board.  I am moving
CONFIG_CMD_UNZIP to defconfig files except UniPhier SoC family.

I am the maintainer of UniPhier platform, so I know "select CMD_UNZIP"
is better for this platform.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Acked-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Stefan Roese <sr@denx.de>
Acked-by: Ryan Harkin <ryan.harkin@linaro.org>
Tested-by: Ryan Harkin <ryan.harkin@linaro.org>
2017-02-08 16:24:28 -05:00
Masahiro Yamada 1f4f5e52e5 arm64: fix comment in relocate_64.S
There are two typos in the comment "invalide i-cache is enabled".
We can fix it by
  invalide -> invalidate
  is       -> if

Or, if we want to match the comment to the code, we can say
"skip invalidating i-cache if disabled".

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-08 16:24:27 -05:00
Phil Edworthy 8ccdba8b8c keystone2: Rename local CONFIG_ symbol
CONFIG_SPL_STACK_SIZE is not a config option, so rename it.

Signed-off-by: Phil Edworthy <phil.edworthy@renesas.com>
2017-02-08 16:24:27 -05:00
Keerthy 3064aa7009 regulator: palmas: Fix smps6 - smps9 indices
The array indices used currently are dispalaced by 1 for
SMPS6 through SMPS10 in the respective places of voltage and ctrl
arrays hence fix the same as to assign the right voltage and ctrl
registers.

Signed-off-by: Keerthy <j-keerthy@ti.com>
2017-02-08 16:24:27 -05:00
Masahiro Yamada 4985012b73 pwm: remove unneeded ifdef CONFIG_DM_PWM ... endif
Both CONFIG_PWM_TEGRA and CONFIG_PWM_EXYNOS depend on CONFIG_DM_PWM,
i.e. they are already guarded by Kconfig correctly.  Remove unneeded
ifdef CONFIG_DM_PWM ... endif.

While we are here, let's tidy up alignment and sort the lines
alphabetically in Makefile.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-08 16:24:26 -05:00
Jean-Jacques Hiblot 2e4e5ad4c8 common: env_sf: Use CONFIG_SF_DEFAULT_xxx as the default value for CONFIG_ENV_SPI_xxx
The default values for the configuration defines CONFIG_ENV_SPI_xxx are
arbitrary values. It makes more sense to set them to the values used by
the sf command.

Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2017-02-08 16:24:26 -05:00
Albert ARIBAUD \(3ADEV\) db74cbfc09 pcm052: fix DDR initialization sequence
The sequence erroneously launched the DDR controller
initialization before the pad muxing was done, causing
DRAM size computation to hang.

Configuring the pads first then launching DDR controller
initialization prevents the DRAM hanging.

Signed-off-by: Albert ARIBAUD (3ADEV) <albert.aribaud@3adev.fr>
2017-02-08 16:24:25 -05:00
Lokesh Vutla e9ced147bc drivers: net: cpsw: Fix reading of mac address for am43 SoCs
cpsw driver tries to get macid for am43xx SoCs using the compatible
ti,am4372. But not all variants of am43x uses this complatible like
epos evm uses ti,am438x. So use a generic compatible ti,am43 to get
macid for all am43 based platforms.

Tested-by: Aparna Balasubramanian <aparnab@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Reviewed-by: Joe Hershberger <joe.hershberger@ni.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2017-02-08 16:24:25 -05:00
Grygorii Strashko dbe7881de0 cmd: bootm: fix build when CONFIG_CMD_IMLS_NAND
Now when CONFIG_CMD_IMLS_NAND is enabled the u-boot build will fail,
because nand_read_skip_bad() function has been changed to accept more
parameters, hence fix it.

 CC      cmd/bootm.o
cmd/bootm.c: In function 'nand_imls_legacyimage':
cmd/bootm.c:390:8: error: too few arguments to function 'nand_read_skip_bad'
  ret = nand_read_skip_bad(mtd, off, &len, imgdata);
        ^
In file included from cmd/bootm.c:18:0:
include/nand.h:101:5: note: declared here
 int nand_read_skip_bad(struct mtd_info *mtd, loff_t offset, size_t *length,
     ^
 LD      drivers/block/built-in.o

Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-08 15:56:32 -05:00
Dan Murphy c10e0f5b38 checkpatch: Port spelling to checkpatch
Pick commit 66b47b4a9dad0 checkpatch: look for common misspellings
from the Linux kernel for spelling check from Kees Cook

In addition pulled in additional changes
commit ebfd7d6237531 checkpatch: add optional --codespell dictionary to find more typos
from the Linux kernel for codespell from Joe Perches

commit f1a63678554f8 checkpatch: remove local from codespell path
from the Linux kernel for dictionary path from Maxim Uvarov

Signed-off-by: Dan Murphy <dmurphy@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2017-02-08 15:56:31 -05:00
Emmanuel Vadot b569048357 api: Convert to Kconfig
Now that we have a Kconfig for the API, convert the two boards that
are using this to Kconfig and remove CONFIG_API from the whitelist.

Signed-off-by: Emmanuel Vadot <manu@bidouilliste.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-08 15:56:31 -05:00
Emmanuel Vadot 4db98d3d92 kconfig: Add API kconfig file
Add kconfig file to enable API support

Signed-off-by: Emmanuel Vadot <manu@bidouilliste.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2017-02-08 15:56:31 -05:00