Bin Meng [Tue, 22 Aug 2017 15:15:18 +0000 (08:15 -0700)]
sandbox: Add a dummy invalidate_dcache_range() function
This adds invalidate_dcache_range() so that some drivers can build
without error on sandbox.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:17 +0000 (08:15 -0700)]
nvme: Adjust the 'nvme' command to use blk_common_cmd()
Instead of having separate code in the 'nvme' command, adjust it to use
the common function.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:16 +0000 (08:15 -0700)]
nvme: Get rid of the global variable nvme_info
At present the NVMe uclass driver uses a global variable nvme_info
to store global information like namespace id, and NVMe controller
driver's priv struct has a blk_dev_start that is used to calculate
the namespace id based on the global information from nvme_info.
This is not a good design in the DM world and can be replaced with
the following changes:
- Encode the namespace id in the NVMe block device name during
the NVMe uclass post probe
- Extract the namespace id from the device name during the NVMe
block device probe
- Let BLK uclass calculate the devnum for us by passing -1 to
blk_create_devicef() as the devnum
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:15 +0000 (08:15 -0700)]
nvme: Use blk_create_devicef() API
The codes in nvme_uclass_post_probe() can be replaced to call the
blk_create_devicef() API directly.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:14 +0000 (08:15 -0700)]
nvme: Apply cache operations on the DMA buffers
So far cache operations are only applied on the submission queue and
completion queue, but they are missing in other places like identify
and block read/write routines.
In order to correctly operate on the caches, the DMA buffer passed
to identify routine must be allocated properly on the stack with the
existing macro ALLOC_CACHE_ALIGN_BUFFER().
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:13 +0000 (08:15 -0700)]
nvme: Consolidate block read and write routines
The NVMe block read and write routines are almost the same except
the command opcode. Let's consolidate them to avoid duplication.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:12 +0000 (08:15 -0700)]
nvme: Use macros to access NVMe queues
NVMe driver only uses two queues. The first one is allocated to do
admin stuff, while the second one is for IO stuff. So far the driver
uses magic number (0/1) to access them. Change to use macros.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:11 +0000 (08:15 -0700)]
nvme: Respect timeout when en/disabling the controller
So far the driver unconditionally delays 10ms when en/disabling the
controller and still return 0 if 10ms times out. In fact, spec defines
a timeout value in the CAP register that is the worst case time that
host software shall wait for the controller to become ready.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:10 +0000 (08:15 -0700)]
nvme: Cache controller's capabilities
Capabilities register is RO and accessed at various places in the
driver. Let's cache it in the controller driver's priv struct.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:09 +0000 (08:15 -0700)]
nvme: Fix endianness assignment to prp2 in nvme_identify()
So far this is not causing any issue due to NVMe and x86 are using
the same endianness, but for correctness, it should be fixed.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:08 +0000 (08:15 -0700)]
nvme: Fix ndev->queues allocation
ndev->queues is a pointer to pointer, but the allocation wrongly
requests sizeof(struct nvme_queue). Fix it.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:07 +0000 (08:15 -0700)]
nvme: Fix getting PCI vendor id of the NVMe block device
The codes currently try to read PCI vendor id of the NVMe block
device by dm_pci_read_config16() with its parameter set as its
root complex controller (ndev->pdev) instead of itself. This is
seriously wrong. We can read the vendor id by passing the correct
udevice parameter to the dm_pci_read_config16() API, however there
is a shortcut by reading the cached vendor id from the PCI device's
struct pci_child_platdata.
While we are here fixing this bug, apparently the quirk stuff handle
codes in nvme_get_info_from_identify() never takes effect since its
logic has never been true at all. Remove these codes completely.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Tue, 22 Aug 2017 15:15:06 +0000 (08:15 -0700)]
nvme: Remove useless defines
These are leftover when the driver was ported from Linux and are not
used by the U-Boot driver.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Tom Rini [Mon, 28 Aug 2017 11:16:32 +0000 (07:16 -0400)]
configs: Resync with savedefconfig
Rsync all defconfig files using moveconfig.py
Signed-off-by: Tom Rini <trini@konsulko.com>
Tom Rini [Sun, 27 Aug 2017 15:50:16 +0000 (11:50 -0400)]
sh: Fix linking of ms7722se
While it is true that we no longer have 'ppcenv' and similar sections,
including env/embedded.o at all results in the text/etc sections being
available for the rest of the link. This in turn is required for the
setup used on ms7722se. This also, likely, needs further fine-tuning.
Fixes:
f40ad66fa066 ("arch/sh: don't bring common/env_embedded.o into the link")
Signed-off-by: Tom Rini <trini@konsulko.com>
Tom Rini [Sun, 27 Aug 2017 01:17:05 +0000 (21:17 -0400)]
cmd/spl.c: Include <libfdt.h> for fdt_totalsize
In order to be able to reliably use fdt_totalsize, we must have
<libfdt.h> included.
Fixes:
767cb74a0028 ("cmd: spl: provide address and size of prepared FDT ...")
Signed-off-by: Tom Rini <trini@konsulko.com>
Tom Rini [Sat, 26 Aug 2017 20:59:24 +0000 (16:59 -0400)]
mtdparts: Fix uninitialized scalar usage
When reworking this code to fix other issues found by Coverity, I forgot
to ensure tmp_ep was always cleared before use.
Reported-by: Coverity (CID: 166612)
Fixes:
bc028345acc4 ("mtdparts: Fix final outstanding issue reported by Coverity")
Signed-off-by: Tom Rini <trini@konsulko.com>
Tom Rini [Sat, 26 Aug 2017 19:10:49 +0000 (15:10 -0400)]
Merge git://git.denx.de/u-boot-sh
Tom Rini [Sat, 26 Aug 2017 19:10:46 +0000 (15:10 -0400)]
Merge branch 'rmobile' of git://git.denx.de/u-boot-sh
Tom Rini [Sat, 26 Aug 2017 19:10:40 +0000 (15:10 -0400)]
Merge git://git.denx.de/u-boot-x86
Tom Rini [Sat, 26 Aug 2017 19:10:38 +0000 (15:10 -0400)]
Merge git://git.denx.de/u-boot-i2c
Tom Rini [Sat, 26 Aug 2017 19:10:35 +0000 (15:10 -0400)]
Merge git://www.denx.de/git/u-boot-cfi-flash
Stefan Agner [Wed, 23 Aug 2017 16:46:17 +0000 (09:46 -0700)]
disk: part: align buffer so it can be used with DMA enabled drivers
When using ISO partitions with a DMA enabled block device driver
reading the ISO partition leads to unaligned DMA operations:
CACHE: Misaligned operation at range [
bffb7da8,
bffb85a8]
Align the buffer to make sure we pass a buffer which works for
DMA operations.
Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Stephen Boyd [Wed, 23 Aug 2017 01:59:31 +0000 (10:59 +0900)]
scripts: objdiff: Ignore debug info when comparing
If the kernel is configured to be built with debug symbols, or
has bug tables, comparing files may not work if line numbers
change. This makes comparing object files with these options
harder to do. Let's strip out the debug info and drop the
__bug_table here so that we don't see false positives. There may
be other things to drop later, and it may be architecture
specific, but this works for me with my ARM64 build.
[ Import Linux commit:
65ba6fa439e7c3cbf97de9dce9e7a3390ae2638c ]
Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org>
Reviewed-by: Jason Cooper <jason@lakedaemon.net>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Masahiro Yamada [Tue, 22 Aug 2017 06:19:20 +0000 (15:19 +0900)]
doc: verified-boot: fix typos
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Tom Rini [Mon, 21 Aug 2017 02:30:15 +0000 (22:30 -0400)]
fs: ext4: Fix journal overrun issue reported by Coverity
While &p_jdb[fs->blksz] is a valid expression (it points *one* char
sized element past the end of the array, e.g. &p_jdb[fs->blksz + 1] is
invalid (according to the C standard (C99/C11)).
Changing this to tag = (struct ext3_journal_block_tag *)(p_jdb + ofs);
Cc: Stefan Brüns <stefan.bruens@rwth-aachen.de>
Suggested-by: Stefan Brüns <stefan.bruens@rwth-aachen.de>
Reported-by: Coverity (CID: 165117, 165110)
Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Stefan Brüns <stefan.bruens@rwth-aachen.de>
Tom Rini [Mon, 21 Aug 2017 00:05:40 +0000 (20:05 -0400)]
mtdparts: Fix final outstanding issue reported by Coverity
As part of fixing the previously reported issues, it was missed that in
the case of mtdparts_init() we need to make sure that tmp_ep is long
enough to contain PARTITION_MAXLEN and a NULL termination. Then, to be
sure the buffer is NULL terminated, zero the entire buffer rather than
just ensuring the first character is NULL.
Cc: Lothar Waßmann <LW@KARO-electronics.de>
Cc: Maxime Ripard <maxime.ripard@free-electrons.com>
Reported-by: Coverity (CID: 166329)
Signed-off-by: Tom Rini <trini@konsulko.com>
Vikas Manocha [Sun, 20 Aug 2017 18:05:37 +0000 (11:05 -0700)]
spl: stm32: make falcon mode activation configurable
With this change, it will be possible to de-select falcon mode & spl
will only boot U-Boot.
Signed-off-by: Vikas Manocha <vikas.manocha@st.com>
Suggested-by: Bo Shen <voice.shen@gmail.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Anatolij Gustschin [Thu, 17 Aug 2017 19:01:48 +0000 (21:01 +0200)]
cmd: spl: provide address and size of prepared FDT in environment
Writing prepared FDT to persistent storage should be possible in
scripts. Create environment variables containing address and size
of the updated FDT. Scripts can use these variables after running
'spl export fdt ...' command to write the new blob to persistent
storage.
Signed-off-by: Anatolij Gustschin <agust@denx.de>
Pau Pajuelo [Thu, 17 Aug 2017 01:09:14 +0000 (03:09 +0200)]
igep00x0: merge igep0020 and igep0030 defconfigs to igep00x0_defconfig
Update igep00x0 code with the following features:
- Add board and revision detection for the boards:
- IGEP0020-RF
- IGEP0020-RC
- IGEP0030-RG
- IGEP0030-RE
- Merge IGEP0020 and IGEP0030 mux tables
- Add suport to use GPIO_126, GPIO_127 and GPIO_129
- board_name and board_rev environment variables display board and
revision informations
- Move dtb name selection from code to boot script
Signed-off-by: Pau Pajuelo <ppajuel@gmail.com>
Signed-off-by: Ladislav Michl <ladis@linux-mips.org>
Tested-by: Pau Pajuelo <ppajuel@gmail.com>
Ladislav Michl [Thu, 17 Aug 2017 01:06:45 +0000 (03:06 +0200)]
igep00x0: move SPL routines into separate file
Avoid cluttering board file with CONFIG_SPL_BUILD ifdefs
by moving SPL related functions into separate file.
Signed-off-by: Ladislav Michl <ladis@linux-mips.org>
Tested-by: Pau Pajuelo <ppajuel@gmail.com>
Acked-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Semen Protsenko [Wed, 16 Aug 2017 12:55:50 +0000 (15:55 +0300)]
arm: dra7xx: Define Android boot arguments
Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>
Semen Protsenko [Wed, 16 Aug 2017 12:55:49 +0000 (15:55 +0300)]
arm: am57xx: Define Android boot arguments
Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>
Semen Protsenko [Wed, 16 Aug 2017 12:55:48 +0000 (15:55 +0300)]
arm: omap: Define command for booting Android from eMMC
If SD card is present -- try to boot from it first. If no -- try to boot
Android from eMMC.
Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>
Ruchika Gupta [Wed, 16 Aug 2017 10:28:10 +0000 (15:58 +0530)]
ARMv8/sec_firmware : Update chosen/kaslr-seed with random number
kASLR support in kernel requires a random number to be passed via
chosen/kaslr-seed propert. sec_firmware generates this random seed
which can then be passed in the device tree node.
sec_firmware reserves JR3 for it's own usage. Node for JR3 is
removed from device-tree.
Signed-off-by: Ruchika Gupta <ruchika.gupta@nxp.com>
Thomas Petazzoni [Tue, 15 Aug 2017 20:52:45 +0000 (22:52 +0200)]
arch/arm/cpu/arm926ejs/spear/cpu.c: guard do_switch_ecc() with CONFIG_NAND_FSMC
do_switch_ecc() calls fsmc_nand_switch_ecc(), which is a direct
function call into drivers/mtd/nand/fsmc_nand.c. However, this
function is not guarded by CONFIG_NAND_FSMC, which results to a build
failure if CONFIG_NAND_FSMC is disabled.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Thomas Petazzoni [Tue, 15 Aug 2017 20:52:44 +0000 (22:52 +0200)]
board/spear/common: move code to arch/arm/cpu/arm926ejs/spear/
The code in board/spear/common/ is not board-specific but
SoC-specific. Therefore, boards from other vendors than "spear" may
want to re-use this code, which is currently difficult with the code
being placed in board/spear/common/.
Since this code really is SoC-specific, this commit moves it to
arch/arm/cpu/arm926ejs/spear/, with the rest of the SPEAr related
code.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Wenyou.Yang@microchip.com [Tue, 15 Aug 2017 09:40:27 +0000 (17:40 +0800)]
board: atmel: Use the new PIT timer driver
Use the Atmel PIT timer driver which supports the driver model
and device tree.
Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
Wenyou.Yang@microchip.com [Tue, 15 Aug 2017 09:40:26 +0000 (17:40 +0800)]
driver: timer: Add the Atmel PIT timer driver
Add the new Atmel PIT timer driver, which supports the driver model
and device tree.
Signed-off-by: Wenyou Yang <wenyou.yang@microchip.com>
Tom Rini [Mon, 14 Aug 2017 02:44:37 +0000 (22:44 -0400)]
powerpc: Rework interrupt_init_cpu()
The function interrupt_init_cpu() is given an int return type but does
not return anything but 0. Rework this to be a void function.
Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Mario Six <mario.six@gdsys.cc>
Reno Farnesi [Sun, 13 Aug 2017 19:16:17 +0000 (15:16 -0400)]
fs: fat: fix fatwrite overflow calculation
The overflow calculation was incorrect. Adding the start block of the
partition is not needed because the sectors are already relative to the
beginning of the partition. If you attempted to write a file smaller
than cur_part_info.start blocks on a full partition the old calculation
fails to catch the overflow. This would cause an infinite loop in the
determine_fatent function.
Old, incorrect calculation:
ending sector of new file = start sector + file size (in sectors)
last sector = partition start + total sectors on the partition
Adding the partition start block number is not needed because sectors
are already relative to the start of the partition.
New calculation:
ending sector of new file = start sector + file size (in sectors)
last sector = total sectors on the partition
Signed-off-by: Reno Farnesi <nfarnesi4@gmail.com>
Suniel Mahesh [Sat, 12 Aug 2017 07:56:38 +0000 (13:26 +0530)]
arm: dts: am33xx: sync DTS with Linux 4.13-rc4
This re-syncs AM33xx DTS file with current file from
Linux v4.13-rc4 to ensure a consistent configuration. Upstream
Linux removed the redundant Interrupt-parent property from mmc,
mac, lcdc and tscadc sub nodes.
Signed-off-by: Suniel Mahesh <sunil.m@techveda.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
Jagan Teki [Fri, 25 Aug 2017 14:46:00 +0000 (20:16 +0530)]
ram: kconfig: s/SPL/TPL/ in TPL_RAM help text
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Simon Glass [Fri, 25 Aug 2017 01:45:31 +0000 (19:45 -0600)]
rpi: Enable USB keyboard support
This is currently disabled, so USB keyboards are not detected in U-Boot.
Enable this option to fix that.
Signed-off-by: Simon Glass <sjg@chromium.org>
Tested-by: Jonathan Gray <jsg@jsg.id.au>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Tested-by: Paul Barker <pbarker@toganlabs.com>
Thomas Petazzoni [Fri, 28 Jul 2017 21:46:36 +0000 (23:46 +0200)]
arch/sh: don't bring common/env_embedded.o into the link
The linker script for SuperH brings the .ppcenv and .ppcenvr section
of common/env_embedded.o into the .text section. However, the .ppcenv
section is only ever filled in by env_embedded.o when
CONFIG_SYS_USE_PPCENV is defined, but no platforms in mainline U-Boot
use this.
In addition, common/env_embedded.o is not always built (when you use
CONFIG_ENV_IS_NOWHERE for example), which causes the following build
failure:
Fixes:
LD u-boot
/home/thomas/sh4aeb-linux-musl/bin/sh4aeb-linux-ld.bfd: cannot find common/env_embedded.o
We fix this by no longer adding the .ppcenv and .ppcenvr sections from
common/env_embedded.o into the .text section.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Thomas Petazzoni [Fri, 28 Jul 2017 21:14:28 +0000 (23:14 +0200)]
arch/sh: allow building in big-endian mode
The SuperH architecture allows to be run in either little or big
endian mode. Some SuperH SoCs get the little vs. big endian decision
through mode pins sampled at reset, so if big endian has been choosen
by HW designers, it cannot be easily changed.
Therefore, it makes sense to allow building U-Boot for SuperH in big
endian mode. To allow this, the only change needed is to adjust the
OUTPUT_FORMAT() in the linker script.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Marek Vasut [Sun, 20 Aug 2017 15:13:50 +0000 (17:13 +0200)]
ARM: rmobile: Enable MMC and USB DM on ULCB
Enable the MMC and USB DM on the board since it's the modern method
and now supported by the drivers.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:49 +0000 (17:13 +0200)]
ARM: rmobile: Enable MMC and USB DM on Salvator-X
Enable the MMC and USB DM on the board since it's the modern method
and now supported by the drivers.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:48 +0000 (17:13 +0200)]
ARM: rmobile: Remove SH SDHI probing from ULCB board
Drop the SH SDHI bit from the board since SD now probes from DT instead.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:47 +0000 (17:13 +0200)]
ARM: rmobile: Remove SH SDHI probing from Salvator-X board
Drop the SH SDHI bit from the board since SD now probes from DT instead.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:46 +0000 (17:13 +0200)]
ARM: rmobile: Remove Serial SH probing from ULCB board
Drop the Serial SH bit from the board since UART now probes from DT instead.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:45 +0000 (17:13 +0200)]
ARM: rmobile: Remove Serial SH probing from Salvator-X board
Drop the Serial SH bit from the board since UART now probes from DT instead.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:44 +0000 (17:13 +0200)]
ARM: rmobile: Remove RAVB probing from ULCB board
Drop the RAVB bit from the board since RAVB now probes from DT instead.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:43 +0000 (17:13 +0200)]
ARM: rmobile: Remove RAVB probing from Salvator-X board
Drop the RAVB bit from the board since RAVB now probes from DT instead.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:42 +0000 (17:13 +0200)]
ARM: rmobile: Enable HUSH parser
The HUSH parser was disabled somewhere along the way, reenable it.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Alexandru Gagniuc <alex.g@adaptrum.com>
Cc: Joe Hershberger <joe.hershberger@ni.com>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:41 +0000 (17:13 +0200)]
ARM: rmobile: Enable KSZ90X1 PHY on Salvator-X
Commit
da3b9e7fd6a1 (Move PHY_MICREL and PHY_MICREL_KSZ90X1 to Kconfig)
broke ethernet support on R8A779x Salvator-X boards by disabling the
KSZ90x1 PHY in Kconfig. Reenable it.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Alexandru Gagniuc <alex.g@adaptrum.com>
Cc: Joe Hershberger <joe.hershberger@ni.com>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:40 +0000 (17:13 +0200)]
ARM: rmobile: Add u-boot, dm-pre-reloc to clock nodes on Gen3
We need the clock available very early, add the u-boot,dm-pre-reloc
DT property on those nodes, so they come up very in the process.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Marek Vasut [Sun, 20 Aug 2017 15:13:39 +0000 (17:13 +0200)]
clk: rmobile: Split R8A7795 and R8A7796 core clock tables
The R8A7795 and R8A7796 tables use different constants to identify
clock in DT, so split the tables and use the correct constants on
R8A7795. This fixes UART clock misconfiguration on R8A7795.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Signed-off-by: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Bin Meng [Sun, 20 Aug 2017 11:33:46 +0000 (04:33 -0700)]
x86: tangier: kconfig: Guard tangier-specific options
These options should not be exposed to other platforms.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Bin Meng [Sun, 20 Aug 2017 11:32:51 +0000 (04:32 -0700)]
x86: bayleybay: Adjust VGA rom address
Adjust VGA rom address to 0xfffb0000 so that u-boot.rom image can be
built again.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Thu, 17 Aug 2017 08:10:43 +0000 (01:10 -0700)]
x86: baytrail: Fix turbo enable
CPU_INTEL_TURBO_NOT_PACKAGE_SCOPED must be turned on for Baytrail.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Thu, 17 Aug 2017 08:10:42 +0000 (01:10 -0700)]
x86: Convert CPU_INTEL_TURBO_NOT_PACKAGE_SCOPED to Kconfig
This converts CPU_INTEL_TURBO_NOT_PACKAGE_SCOPED to a Kconfig option.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Stefan Roese [Wed, 16 Aug 2017 15:37:18 +0000 (17:37 +0200)]
x86: dfi-bt700: Select SERIAL_RX_BUFFER via Kconfig
To support more input characters (longer stings pasted into the U-Boot
prompt) without dropping, lets selects the recently added UART RX
buffer for these boards.
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Stefan Roese [Wed, 16 Aug 2017 15:37:17 +0000 (17:37 +0200)]
x86: conga-qeval20-qa3-e3845: Select SERIAL_RX_BUFFER via Kconfig
To support more input characters (longer stings pasted into the U-Boot
prompt) without dropping, lets selects the recently added UART RX
buffer for these boards.
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Stefan Roese [Wed, 16 Aug 2017 15:37:16 +0000 (17:37 +0200)]
serial: serial-uclass: Add generic serial RX buffer support
Pasting longer lines into the U-Boot console prompt sometimes leads to
characters missing. One problem here is the small 16-byte FIFO of the
legacy NS16550 UART, e.g. on x86 platforms.
This patch now introduces a Kconfig option to enable RX buffer support
for all DM based serial drivers. With this option enabled, I was
able paste really long lines into the U-Boot console, without any
characters missing.
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Bin Meng <bmeng.cn@gmail.com>
Cc: Tom Rini <trini@konsulko.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Tested-by: Bin Meng <bmeng.cn@gmail.com>
Stefan Roese [Wed, 16 Aug 2017 15:37:15 +0000 (17:37 +0200)]
Revert "serial: ns16550: Add RX interrupt buffer support"
This reverts commit
6822cf3ec7c8768b8727573b8f4b2cb3d870b881.
As Bin Meng has tested and pointed out, we don't need the RX interrupt
for the RX buffer support at all. Just reading all available characters
into a buffer is sufficient to solve the problem with the dropped
characters upon long lines pasted into the U-Boot prompt. Since this
RX buffer support can be implemented in a generic way, without any
device specifica (e.g. for the ns16550), I'll post a new patch with
a new serial RX buffer support for DM, which all DM based serial
drivers can use.
Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Cc: Bin Meng <bmeng.cn@gmail.com>
Cc: Tom Rini <trini@konsulko.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Wed, 16 Aug 2017 14:35:36 +0000 (07:35 -0700)]
vbe: Drop vbe_get_video_info()
With DM video, this is not used any more. Drop it.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Bin Meng [Wed, 16 Aug 2017 12:46:49 +0000 (05:46 -0700)]
x86: kconfig: Imply CMD_PCI
Let's imply the 'pci' command to access the de facto interconnect
bus in an x86 system.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Bin Meng [Wed, 16 Aug 2017 05:38:31 +0000 (22:38 -0700)]
x86: fsp: Configure SPI opcode registers before SPI is locked down
Some Intel FSP (like Braswell) does SPI lock-down during the call
to fsp_notify(INIT_PHASE_BOOT). But before SPI lock-down is done,
it's bootloader's responsibility to configure the SPI controller's
opcode registers properly otherwise SPI controller driver doesn't
know how to communicate with the SPI flash device.
This introduces a Kconfig option CONFIG_FSP_LOCKDOWN_SPI for such
FSPs. When it is on, U-Boot will configure the SPI opcode registers
before the lock-down.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Bin Meng [Wed, 16 Aug 2017 05:38:30 +0000 (22:38 -0700)]
x86: ich-spi: Move opcode registers configuration to another routine
At present the ICH SPI opcode registers configuration is done in the
ich_spi_remove() routine, a little bit weird but that's how current.
Linux MTD driver works. This changes to move the opcode registers
configuration to a separate routine ich_spi_config_opcode() which
might be called by U-Boot itself as well.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Bin Meng [Wed, 16 Aug 2017 05:38:29 +0000 (22:38 -0700)]
x86: ich-spi: Don't read cached lock status
At present the ICH SPI controller driver reads the controller lock
status from its register in the probe routine and saves the lock
status to a member of priv. Later the driver uses the cached status
from priv to judge whether the controller setting is locked and do
different setup.
But such logic is only valid when there is only the SPI controller
driver that touches the SPI hardware. In fact the lock status change
can be trigged outside the driver, eg: during the fsp_notify() call
when Intel FSP is used.
This changes the driver to read the lock status every time when an
SPI transfer is initiated instead of reading the cached one.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Bin Meng [Wed, 16 Aug 2017 05:38:28 +0000 (22:38 -0700)]
x86: ich-spi: Remove unnecessary assignment in ich_init_controller()
There is no need to do another assignment to ich7_spi.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Bin Meng [Wed, 16 Aug 2017 05:38:27 +0000 (22:38 -0700)]
x86: ich-spi: Remove spi_write_protect_region()
This routine is not called anywhere.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Peng Fan [Mon, 14 Aug 2017 10:00:05 +0000 (18:00 +0800)]
i2c: muxes: add i2c gpio multiplexer driver
Add an i2c mux driver providing access to i2c bus segments using a
hardware MUX sitting on a master bus and controlled through gpio pins.
E.G. something like:
---------- ---------- Bus segment 1 - - - - -
| | SCL/SDA | |-------------- | |
| |------------| |
| | | | Bus segment 2 | |
| Linux | GPIO 1..N | MUX |--------------- Devices
| |------------| | | |
| | | | Bus segment M
| | | |---------------| |
---------- ---------- - - - - -
SCL/SDA of the master I2C bus is multiplexed to bus segment 1..M
according to the settings of the GPIO pins 1..N.
Note commit log from kernel
commit
92ed1a76("i2c: Add generic I2C multiplexer using GPIO API")
Signed-off-by: Peng Fan <peng.fan@nxp.com>
Tested-by: Peng Fan <peng.fan@nxp.com> (i.MX6QP-Sabreauto)
Cc: Heiko Schocher <hs@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Simon Glass <sjg@chromium.org>
Patrice Chotard [Wed, 9 Aug 2017 12:45:27 +0000 (14:45 +0200)]
i2c: add i2c driver for stm32
Add i2c driver which can be used on both STM32F7 and STM32H7.
This I2C block supports the following features:
_ Slave and master modes
_ Multimaster capability
_ Standard-mode (up to 100 kHz)
_ Fast-mode (up to 400 kHz)
_ Fast-mode Plus (up to 1 MHz)
_ 7-bit and 10-bit addressing mode
_ Multiple 7-bit slave addresses (2 addresses, 1 with configurable mask)
_ All 7-bit addresses acknowledge mode
_ General call
_ Programmable setup and hold times
_ Easy to use event management
_ Optional clock stretching
_ Software reset
Signed-off-by: Christophe Kerello <christophe.kerello@st.com>
Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Tom Rini [Tue, 22 Aug 2017 12:20:02 +0000 (08:20 -0400)]
fastboot: Ensure we treat CONFIG_FASTBOOT_BUF_ADDR as long
Otherwise:
drivers/usb/gadget/f_fastboot.c:564:32: warning: format "%lx" expects
argument of type "long unsigned int", but argument 3 has type "unsigned
int" [-Wformat=]
Signed-off-by: Tom Rini <trini@konsulko.com>
Marek Vasut [Sun, 20 Aug 2017 15:20:00 +0000 (17:20 +0200)]
mtd: cfi: staticize functions
Staticize a few functions and variables which are no longer exposed.
Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Tom Rini [Mon, 21 Aug 2017 11:17:15 +0000 (07:17 -0400)]
Merge git://www.denx.de/git/u-boot-marvell
Tom Rini [Mon, 21 Aug 2017 11:16:56 +0000 (07:16 -0400)]
Merge git://git.denx.de/u-boot-usb
Tom Rini [Mon, 21 Aug 2017 11:16:16 +0000 (07:16 -0400)]
Merge git://git.denx.de/u-boot-uniphier
- Fix unmet direct dependencies warning
- Remove old sLD3 SoC support
- Update reset data
- Add dr_mode DT property to avoid warning
Chris Packham [Thu, 17 Aug 2017 10:27:03 +0000 (22:27 +1200)]
ARM: mvebu: set correct mem_size for db-
88f6820-amc
The db-
88f6820-amc has four chips with 2Gb density giving a total of 1GB
DRAM. Update the board_topology_map to reflect the correct
configuration.
Signed-off-by: Chris Packham <judge.packham@gmail.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
Lukasz Majewski [Thu, 17 Aug 2017 21:10:49 +0000 (23:10 +0200)]
doc: license: Add license header to the README.dfutftp file
Signed-off-by: Lukasz Majewski <lukma@denx.de>
Tom Rini [Tue, 15 Aug 2017 01:00:44 +0000 (21:00 -0400)]
fb_mmc.c: Correct blk_dread() return value checks
The function blk_dread will return -ENOSYS on failure or on success the
number of blocks read, which must be the number asked to read (otherwise
it failed somewhere). Correct this check.
Cc: Lukasz Majewski <lukma@denx.de>
Signed-off-by: Tom Rini <trini@konsulko.com>
Tom Rini [Sat, 10 Jun 2017 13:15:37 +0000 (09:15 -0400)]
common/fb_mmc.c: Fix warnings about casts
When building the flash zImage code on aarch64 we see warnings about
pointer size casts. Use uintptr_t instead to correct these.
Cc: Sam Protsenko <semen.protsenko@linaro.org>
Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-By: Sam Protsenko <semen.protsenko@linaro.org>
John Keeping [Mon, 19 Sep 2016 09:59:40 +0000 (10:59 +0100)]
fastboot: avoid printing invalid data
There is no guarantee that commands are null-terminated in the USB
request buffer, so limit the length of data that is printed.
Signed-off-by: John Keeping <john@metanate.com>
Tested-by: Steve Rae <steve.rae@raedomain.com>
Peter Chubb [Thu, 8 Sep 2016 20:51:57 +0000 (20:51 +0000)]
Fix fastboot boot address
Fastboot loads an image at CONFIG_FASTBOOT_BUF_ADDR, but currently
tells do_bootm() to look for an image at $loadaddr. This breaks if
CONFIG_FASTBOOT_BUF_ADDR is different from the current user-set
loadaddr.
Instead, tell do_bootm() to pick up the image where it was laoded.
Signed-off-by: Peter Chubb <peter.chubb@data61.csiro.au>
Reviewed-by: Tom Rini <trini@konsulko.com>
Acked-by: Steve Rae <steve.rae@raedomain.com>
Bin Meng [Wed, 9 Aug 2017 07:21:54 +0000 (00:21 -0700)]
usb: ehci: Convert CONFIG_USB_EHCI_PCI to Kconfig
This converts CONFIG_USB_EHCI_PCI to a Kconfig option, and updates
all boards that use it.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Simon Glass [Sun, 20 Aug 2017 10:45:15 +0000 (04:45 -0600)]
env: Replace all open-coded gd->env_valid values with ENV_ flags
Some of these were missed in the conversion.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 20 Aug 2017 10:45:14 +0000 (04:45 -0600)]
env: Allow env_load() to detect errors
Now that we have errors available in the environment driver's load()
method, check the return valid.
Signed-off-by: Simon Glass <sjg@chromium.org>
Tom Rini [Sun, 20 Aug 2017 02:27:57 +0000 (22:27 -0400)]
env: Correct case of no sub-init function
With the change to the environment code to remove the common init stage
of pointing to the default environment and setting it as valid, combined
with the change to switch gd->env_valid from 0/1/2 to an enum we now
must set env_valid to one of the enum values rather than an int. And in
this case, not only was setting it to an int wrong, it was now the wrong
value. Finally, in the case of ENV_IS_NOWHERE we must still say that
our envionrment is invalid after init for things to continue to
function.
Fixes:
7938822a6b75 ("env: Drop common init() functions")
Tested-by: Marek Vasut <marek.vasut@gmail.com>
Reported-by: Marek Vasut <marek.vasut@gmail.com>
Reported-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Changes in v3:
- Actually include changes for env/nowhere.c
Masahiro Yamada [Sun, 13 Aug 2017 00:01:17 +0000 (09:01 +0900)]
ARM: dts: uniphier: add dr_mode property to dwc3 node
Since commit
576e3cc700c5 ("usb: host: xhci-dwc3: Add dual role mode
support from DT"), warning is displayed if dr_mode is not specified.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Masahiro Yamada [Sun, 13 Aug 2017 00:01:16 +0000 (09:01 +0900)]
reset: uniphier: refactor reset data and add NAND/eMMC reset lines
- Merge sys_reset data of LD4, Pro4, sLD8 and Pro5
- Merge sys_reset data of LD11 and LD20
- Use primitive UNIPHIER_RESETX() macro because bit assignments for
system reset will be changed for every SoC in the future
- Add NAND and eMMC resets
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Masahiro Yamada [Sun, 13 Aug 2017 00:01:15 +0000 (09:01 +0900)]
Revert "ARM: uniphier: fix ROM boot mode for PH1-sLD3"
This reverts commit
82d075e79fa509ffb8ecd8dd2dc216929d6e8289.
Commit
82d075e79fa5 ("ARM: uniphier: fix ROM boot mode for PH1-sLD3")
was a workaround for sLD3. Now the sLD3 SoC support has been removed.
Revert it to allow to simplify the init code.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Masahiro Yamada [Sun, 13 Aug 2017 00:01:14 +0000 (09:01 +0900)]
Revert "ARM: uniphier: move lowlevel debug init code after page table switch"
This reverts commit
bcc51c1512a3deb6a9fdd37362c6dde32ad3da23.
Commit
bcc51c1512a3 ("ARM: uniphier: move lowlevel debug init code
after page table switch") was intended to support lowlevel debug for
sLD3. Now the sLD3 SoC support has been removed.
Revert it to allow to enable lowlevel debug earlier.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Masahiro Yamada [Sun, 13 Aug 2017 00:01:13 +0000 (09:01 +0900)]
ARM: uniphier: remove sLD3 SoC support
This SoC is too old. It is difficult to maintain any longer.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Masahiro Yamada [Sun, 20 Aug 2017 13:59:36 +0000 (22:59 +0900)]
clk: uniphier: fix unmet direct dependencies warning
Since commit
f0776a551764 ("spl: dm: Kconfig: SPL_CLK depends on
SPL_DM"), the following warning is displayed:
$ make uniphier_v8_defconfig
warning: (ARCH_ZYNQ && ARCH_ZYNQMP && STM32F7 && CLK_UNIPHIER) selects
SPL_CLK which has unmet direct dependencies (CLK && SPL_DM)
While I am here, I am removing the prompt to make it user-unconfigurable
option so that "select CLK_UNIPHIER" can be omitted.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Anatolij Gustschin [Fri, 18 Aug 2017 15:58:51 +0000 (17:58 +0200)]
Fix 'notes' typos
s/notes/nodes
Signed-off-by: Anatolij Gustschin <agust@denx.de>
Andy Shevchenko [Fri, 18 Aug 2017 10:14:47 +0000 (13:14 +0300)]
env: Sort selection of default choices
It would be easier to catch out which platform is using which default.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Heiko Schocher [Wed, 16 Aug 2017 07:47:45 +0000 (09:47 +0200)]
arm, at91: fix taurus board
since commit:
b529993e0222 "spl: add hierarchical defaults for SPL_LDSCRIPT"
taurus board stopped working. Use the ldscript from
arch/arm/cpu/u-boot-spl.lds (as before this patch) fixed it.
Signed-off-by: Heiko Schocher <hs@denx.de>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Thomas Petazzoni [Tue, 15 Aug 2017 21:11:02 +0000 (23:11 +0200)]
common/board_f.c: remove CONFIG_SYS_GENERIC_GLOBAL_DATA
CONFIG_SYS_GENERIC_GLOBAL_DATA is no longer used by any board or
platform, so support for it can be dropped.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Reviewed-by: Vladimir Zapolskiy <vz@mleia.com>
Reviewed-by: Simon Glass <sjg@chromium.org>