platform/kernel/u-boot.git
6 years agoARC: AXS10x: DTS: Remove unused interrupt properties
Eugeniy Paltsev [Tue, 23 Jan 2018 14:03:15 +0000 (17:03 +0300)]
ARC: AXS10x: DTS: Remove unused interrupt properties

Some device tree nodes (like ethernet, ohci, ehci) in axs10x_mb.dtsi
were copied from linux device tree, so they have interrupts properties.
As we don't use interrupts in uboot we don't have interrupt controller
node in AXS10x device tree. In result we get warnings when we compile
such device tree.

So remove unused interrupts properties to get rid of this warnings.

Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
6 years agoMerge git://git.denx.de/u-boot-marvell
Tom Rini [Fri, 30 Mar 2018 22:18:22 +0000 (18:18 -0400)]
Merge git://git.denx.de/u-boot-marvell

6 years agoMerge git://git.denx.de/u-boot-x86
Tom Rini [Fri, 30 Mar 2018 22:17:23 +0000 (18:17 -0400)]
Merge git://git.denx.de/u-boot-x86

6 years agoMerge git://git.denx.de/u-boot-riscv
Tom Rini [Fri, 30 Mar 2018 22:16:56 +0000 (18:16 -0400)]
Merge git://git.denx.de/u-boot-riscv

6 years agoarm64: a37xx: defconfigs: enable PCI_CMD and E1000 driver
Ken Ma [Mon, 26 Mar 2018 07:57:32 +0000 (15:57 +0800)]
arm64: a37xx: defconfigs: enable PCI_CMD and E1000 driver

Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: dts: enable pcie port
Wilson Ding [Mon, 26 Mar 2018 07:57:31 +0000 (15:57 +0800)]
arm64: a37xx: dts: enable pcie port

This patch enabled PCIe port on both devel-board
and espressobin board.

Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Wilson Ding <dingwei@marvell.com>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: defconfigs: enable aardvark pcie driver
Wilson Ding [Mon, 26 Mar 2018 07:57:30 +0000 (15:57 +0800)]
arm64: a37xx: defconfigs: enable aardvark pcie driver

Signed-off-by: Wilson Ding <dingwei@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: pci: add support for aardvark pcie driver
Wilson Ding [Mon, 26 Mar 2018 07:57:29 +0000 (15:57 +0800)]
arm64: a37xx: pci: add support for aardvark pcie driver

This patch introduced the Aardvark PCIe driver based
driver model.
The PCIe driver is supposed to work in Root Complex
mode. It only supports X1 lane width.

Signed-off-by: Wilson Ding <dingwei@marvell.com>
Reviewed-on: http://vgitil04.il.marvell.com:8080/38725
Reviewed-by: Victor Gu <xigu@marvell.com>
Reviewed-by: Hua Jing <jinghua@marvell.com>
Tested-by: Hua Jing <jinghua@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: populate pcie memory region
Wilson Ding [Mon, 26 Mar 2018 07:57:28 +0000 (15:57 +0800)]
arm64: a37xx: populate pcie memory region

This patch added a new region of 32MiB AT 0xe800.0000
to Armada37x0's memory map. This region is supposed to
be mapped in MMU in order to enable the access to the
PCI I/O or MEM resources.

Signed-off-by: Wilson Ding <dingwei@marvell.com>
Reviewed-on: http://vgitil04.il.marvell.com:8080/38724
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Reviewed-by: Victor Gu <xigu@marvell.com>
Signed-off-by: Ken Ma <make@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: remove old pinctrl implementation
Ken Ma [Mon, 26 Mar 2018 07:56:07 +0000 (15:56 +0800)]
arm64: a37xx: remove old pinctrl implementation

Since the new pinctrl/gpio driver is used, so this patch removes
the old board specific pin control settings.

Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoRevert "arm64: a37xx: dts: Add pin control nodes to DT"
Ken Ma [Mon, 26 Mar 2018 07:56:06 +0000 (15:56 +0800)]
Revert "arm64: a37xx: dts: Add pin control nodes to DT"

The commit "arm64: mvebu: Add pinctrl nodes for Armada 3700" has
added new pinctrl nodes.
This reverts commit f7cab0f95b05ec6a66fe4796b9ad44406d0cc864.

Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agodoc: a37xx: Introduce pinctrl device tree binding
Ken Ma [Mon, 26 Mar 2018 07:56:05 +0000 (15:56 +0800)]
doc: a37xx: Introduce pinctrl device tree binding

Reviewed-on: http://vgitil04.il.marvell.com:8080/43289
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Reviewed-by: Kostya Porotchkin <kostap@marvell.com>
Reviewed-by: Igal Liberman <igall@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: dts: Correct mpp definitions
Ken Ma [Mon, 26 Mar 2018 07:56:04 +0000 (15:56 +0800)]
arm64: a37xx: dts: Correct mpp definitions

This patch corrects below mpp definitions for armada 3720 DB board
and ESPRESSOBin board:
- "smi" pins group is added and "smi" function is set for eth0;
- Now pcie pins are used as gpio to implement PCIe function in
  hardware, so "pcie" group function is changed to "gpio".

Reviewed-on: http://vgitil04.il.marvell.com:8080/43287
Reviewed-by: Hua Jing <jinghua@marvell.com>
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: pinctrl: Correct mpp definitions
Ken Ma [Mon, 26 Mar 2018 07:56:03 +0000 (15:56 +0800)]
arm64: a37xx: pinctrl: Correct mpp definitions

This patch corrects below mpp definitions:
 - The sdio_sb group is composed of 6 pins and not 5;
 - The rgmii group contains pins mpp2[17:6] and not mpp2[19:6];
 - Pin of group "pmic0" is mpp1[6] but not mpp1[16];
 - Pin of group "pmic1" is mpp1[7] but not mpp1[17];
 - A new group "smi" is added in A0 with 2 pins - mpp2[19:18], its
   bitmask is bit4;
 - Group "pcie1" has 3 pins in A0 - mpp2[5:3], its bit mask is
   bit5 | bit9 | bit10 but not bit4;
 - Group "ptp" has 3 pins in A0 as Z1, but its bitmask is changed to
   bit11 | bit12 | bit13.

Reviewed-on: http://vgitil04.il.marvell.com:8080/43288
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Reviewed-by: Hua Jing <jinghua@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: pinctrl: Fix gpio pin offset in register
Ken Ma [Mon, 26 Mar 2018 07:56:02 +0000 (15:56 +0800)]
arm64: a37xx: pinctrl: Fix gpio pin offset in register

For armada_37xx_update_reg(), the parameter offset should be pointer so
that it can be updated, otherwise offset will keep old value, and then
when offset is larger than or equal to 32 the mask calculated by
"BIT(offset)" will be 0 in gpio chip hook functions, it's an error,
this patch set offset parameter of armada_37xx_update_reg() as pointer.

Reviewed-on: http://vgitil04.il.marvell.com:8080/43287
Reviewed-by: Hua Jing <jinghua@marvell.com>
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: pinctrl: Fix the pin 23 on south bridge
Ken Ma [Mon, 26 Mar 2018 07:56:01 +0000 (15:56 +0800)]
arm64: a37xx: pinctrl: Fix the pin 23 on south bridge

Pin 23 on South bridge does not belong to the rgmii group. It belongs to
a separate group which can have 3 functions.

Due to this the fix also have to update the way the functions are
managed. Until now each groups used NB_FUNCS(which was 2) functions. For
the mpp23, 3 functions are available but it is the only group which needs
it, so on the loop involving NB_FUNCS an extra test was added to handle
only the functions added.

The bug was visible when the gpio regulator used the gpio 23, the whole
rgmii group was setup to gpio which broke the Ethernet support on the
Armada 3720 DB board. Thanks to this patch, the UHS SD cards (which need
the vqmmc) _and_ the Ethernet work again.

Reviewed-on: http://vgitil04.il.marvell.com:8080/43284
Reviewed-by: Hua Jing <jinghua@marvell.com>
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: dts: Fix the number of GPIO on south bridge
Ken Ma [Mon, 26 Mar 2018 07:56:00 +0000 (15:56 +0800)]
arm64: a37xx: dts: Fix the number of GPIO on south bridge

The number of pins in South Bridge is 30 and not 29. There is a fix for
the driver for the pinctrl, but a fix is also need at device tree level
for the GPIO.

Reviewed-on: http://vgitil04.il.marvell.com:8080/43286
Reviewed-by: Hua Jing <jinghua@marvell.com>
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: pinctrl: Fix number of pin in south bridge
Ken Ma [Mon, 26 Mar 2018 07:55:59 +0000 (15:55 +0800)]
arm64: a37xx: pinctrl: Fix number of pin in south bridge

On the south bridge we have pin from 0 to 29, so it gives 30 pins (and
not 29).

Reviewed-on: http://vgitil04.il.marvell.com:8080/43285
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Reviewed-by: Hua Jing <jinghua@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: dts: Add additional pinctrl definition
Ken Ma [Mon, 26 Mar 2018 07:55:58 +0000 (15:55 +0800)]
arm64: a37xx: dts: Add additional pinctrl definition

Add mmc pins, pcie pins and sdio pins definition and do these pins'
configuration for DB board and espressobin board;
Add uart2 pins configuration for DB board.

Reviewed-on: http://vgitil04.il.marvell.com:8080/40914
Reviewed-by: Wilson Ding <dingwei@marvell.com>
Tested-by: Wilson Ding <dingwei@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: dts: Add pinctrl configuration for ESPRESSOBin board
Ken Ma [Mon, 26 Mar 2018 07:55:57 +0000 (15:55 +0800)]
arm64: a37xx: dts: Add pinctrl configuration for ESPRESSOBin board

Reviewed-on: http://vgitil04.il.marvell.com:8080/40913
Reviewed-by: Wilson Ding <dingwei@marvell.com>
Tested-by: Wilson Ding <dingwei@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: defconfig: Enable PINCTRL and GPIO support for ESPRESSOBin board
Ken Ma [Mon, 26 Mar 2018 07:55:56 +0000 (15:55 +0800)]
arm64: a37xx: defconfig: Enable PINCTRL and GPIO support for ESPRESSOBin board

This patch enable the PINCTRL and GPIO support, including the GPIO
command on the Armada 3720 espressobin board.

Reviewed-on: http://vgitil04.il.marvell.com:8080/40746
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Reviewed-by: Wilson Ding <dingwei@marvell.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: a37xx: dts: add gpio head file including
Ken Ma [Mon, 26 Mar 2018 07:55:55 +0000 (15:55 +0800)]
arm64: a37xx: dts: add gpio head file including

Cc: Simon Glass <sjg@chromium.org>
Cc: Stefan Roese <sr@denx.de>
Signed-off-by: Ken Ma <make@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoarm64: mvebu: a8k: Add distro boot support
Mark Kettenis [Sat, 17 Mar 2018 08:34:27 +0000 (09:34 +0100)]
arm64: mvebu: a8k: Add distro boot support

The various load address values are taken from the a37xx configuration
and match the dowstream 'u-boot-2017.03-armada-17.10' release where
appropriate.

Signed-off-by: Mark Kettenis <kettenis@openbsd.org>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agokwbimage: Fix out of bounds access
Alexander Graf [Thu, 15 Mar 2018 10:14:19 +0000 (11:14 +0100)]
kwbimage: Fix out of bounds access

The kwbimage format is reading beyond its header structure if it
misdetects a Xilinx Zynq image and tries to read it. Fix it by
sanity checking that the header we want to read fits inside our
file size.

Signed-off-by: Alexander Graf <agraf@suse.de>
Tested-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agoconfigs: clearfog: enable random random MAC address
Baruch Siach [Mon, 19 Feb 2018 06:17:22 +0000 (08:17 +0200)]
configs: clearfog: enable random random MAC address

This makes the network devices usable when booting a blank board over
UART, with no pre-configured MAC address stored in the environment area.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Reviewed-by: Stefan Roese <sr@denx.de>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agodm: pcie: designware: add correct ATU handling
Igal Liberman [Wed, 14 Feb 2018 17:25:23 +0000 (19:25 +0200)]
dm: pcie: designware: add correct ATU handling

Currently, ATU (address translation unit) implementation doesn't
support translate addresses > 32 bits.

This patch allows to configure ATU correctly for different
memory accesses (memory, configuration and IO).
The same approach is used in Linux Kernel.

Signed-off-by: Igal Liberman <igall@marvell.com>
Signed-off-by: Stefan Roese <sr@denx.de>
6 years agox86: zImage: Pass working device tree data to the kernel
Ivan Gorinov [Tue, 27 Mar 2018 01:06:54 +0000 (18:06 -0700)]
x86: zImage: Pass working device tree data to the kernel

On x86 platforms, U-Boot does not pass Device Tree data to the kernel.
This prevents the kernel from using FDT loaded by U-Boot.

Read the working FDT address from the "fdtaddr" environment variable
and add a copy of the FDT data to the kernel setup_data list.

Signed-off-by: Ivan Gorinov <ivan.gorinov@intel.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
[bmeng: add #include <linux/libfdt.h> to zimage.c to fix build error]
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
6 years agox86: mmc: Fix mapping of BAR memory
Bernhard Messerklinger [Thu, 15 Feb 2018 08:09:43 +0000 (09:09 +0100)]
x86: mmc: Fix mapping of BAR memory

Use dm_pci_map_bar function for BAR mapping. This has the advantage
of clearing BAR flags and and only accepting mapped memory.

Signed-off-by: Bernhard Messerklinger <bernhard.messerklinger@br-automation.com>
Reviewed-by: Hannes Schmelzer <hannes.schmelzer@br-automation.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
6 years agodm: pci: Avoid setting a PCI region that has 0 size
Bin Meng [Tue, 27 Mar 2018 07:46:06 +0000 (00:46 -0700)]
dm: pci: Avoid setting a PCI region that has 0 size

It makes no sense to set a PCI region that has 0 size.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
6 years agodm: pci: Check board information pointer in decode_regions()
Bin Meng [Tue, 27 Mar 2018 07:46:05 +0000 (00:46 -0700)]
dm: pci: Check board information pointer in decode_regions()

PCI enumeration may happen very early on an x86 board. The board
information pointer should have been checked in decode_regions()
as its space may not be allocated yet.

With this commit, Intel Galileo board boots again.

Fixes: 664758c ("pci: Fix decode regions for memory banks")
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
6 years agoefi_stub: Fix GDT_NOTSYS check
Alexander Graf [Mon, 4 Dec 2017 15:33:26 +0000 (16:33 +0100)]
efi_stub: Fix GDT_NOTSYS check

The get_codeseg32() wants to know if a passed in descriptor has
flag GDT_NOTSYS set (desc & GDT_NOTSYS), not whether desc and
GDT_NOTSYS are not != 0 (desk && GDT_NOTSYS).

This is an obvious typo. Fix it up.

Signed-off-by: Alexander Graf <agraf@suse.de>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
6 years agoriscv: ae250: Support DT provided by the board at runtime
Rick Chen [Thu, 29 Mar 2018 02:08:33 +0000 (10:08 +0800)]
riscv: ae250: Support DT provided by the board at runtime

Enable CONFIG_OF_BOAD to support delivery dtb to u-boot
at run time instead of embedded.

There are two methods to delivery dtb.
 1 Pass from loader:
   When u-boot boot from RAM, gdb or loader can pass dtb
   via a2 to u-boot dynamically. Of course gdb or loader
   shall be in charge of dtb delivery.

 2 Configure CONFIG_SYS_FDT_BASE:
   It can be configured as RAM or ROM base statically,
   no mater u-boot boot from RAM or ROM.
   If it was configured as ROM base, dtb can be burned
   into ROM(spi flash) by spi driver.

Meanwhile remove CONFIG_SKIP_LOWLEVEL_INIT which is
useless in nx25-ae250 configuration.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
Cc: Greentime Hu <green.hu@gmail.com>
6 years agoconfigs: Drop CONFIG_MMC_NDS32
Rick Chen [Tue, 20 Mar 2018 03:26:22 +0000 (11:26 +0800)]
configs: Drop CONFIG_MMC_NDS32

Remove CONFIG_MMC_NDS32 from the three config
(adp-ae3xx_defconfig, adp-ag101p_defconfig, nx25-ae250_defconfig).

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
Cc: Greentime Hu <green.hu@gmail.com>
6 years agommc: ftsdc010: Merge nds32_mmc to ftsdc010
Rick Chen [Tue, 20 Mar 2018 07:52:58 +0000 (15:52 +0800)]
mmc: ftsdc010: Merge nds32_mmc to ftsdc010

nsd32_mmc was created to support ftsdc010 dm.
It is not necessary to separate both, so merge it
to ftsdc010.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
Cc: Greentime Hu <green.hu@gmail.com>
6 years agommc: ftsdc010: Migrate CONFIG_FTSDC010_SDIO to Kconfig
Rick Chen [Tue, 20 Mar 2018 07:10:49 +0000 (15:10 +0800)]
mmc: ftsdc010: Migrate CONFIG_FTSDC010_SDIO to Kconfig

Convert CONFIG_FTSDC010_SDIO to Kconfig.
So CONFIG_FTSDC010_SDIO can also be
removed from config_whitelist.txt.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
Cc: Greentime Hu <green.hu@gmail.com>
6 years agoDrop CONFIG_FTSDC010_NUMBER
Rick Chen [Tue, 20 Mar 2018 07:03:40 +0000 (15:03 +0800)]
Drop CONFIG_FTSDC010_NUMBER

CONFIG_FTSDC010_NUMBER was not used anymore,
can be removed now.

So CONFIG_FTSDC010_NUMBER
can also be removed from config_whitelist.txt.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
Cc: Greentime Hu <green.hu@gmail.com>
6 years agoDrop CONFIG_FTSDC010_BASE
Rick Chen [Tue, 20 Mar 2018 06:06:38 +0000 (14:06 +0800)]
Drop CONFIG_FTSDC010_BASE

After drop non-dm code of ftsdc010, the sd register
base definition can be droppped now.

So CONFIG_FTSDC010_BASE and CONFIG_FTSDC010_BASE_LIST both
can be removed from config_whitelist.txt

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
Cc: Greentime Hu <green.hu@gmail.com>
6 years agoboard: Drop ftsdc010 non-dm code
Rick Chen [Tue, 20 Mar 2018 05:57:13 +0000 (13:57 +0800)]
board: Drop ftsdc010 non-dm code

Remove board_mmc_init() in adp-ag101p, adp-ae3xx
and nx25-ae250 boards.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
Cc: Greentime Hu <green.hu@gmail.com>
6 years agommc: ftsdc010: Drop non-dm code
Rick Chen [Tue, 20 Mar 2018 06:30:52 +0000 (14:30 +0800)]
mmc: ftsdc010: Drop non-dm code

Only three defconfig(adp-ag101p_defconfig,
adp-ae3xx_defconfig, nx25-ae250_defconfig)
set CONFIG_FTSDC010=y. And they all also
enable CONFIG_DM_MMC. So the non-dm code
of ftsdc010 can be dropped now.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
Cc: Greentime Hu <green.hu@gmail.com>
6 years agonds32: dts: AG101P support sd High-Speed mode
Rick Chen [Thu, 15 Mar 2018 02:47:07 +0000 (10:47 +0800)]
nds32: dts: AG101P support sd High-Speed mode

Enable High-Speed mode with cap-sd-highspeed in dts

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agoriscv: dts: AE250 support sd High-Speed mode
Rick Chen [Mon, 25 Dec 2017 09:05:39 +0000 (17:05 +0800)]
riscv: dts: AE250 support sd High-Speed mode

Enable High-Speed mode with cap-sd-highspeed in dts.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agommc: ftsdc010: Support High-Speed mode
Rick Chen [Mon, 25 Dec 2017 08:25:26 +0000 (16:25 +0800)]
mmc: ftsdc010: Support High-Speed mode

ftsdc010 dm driver has been disable High-Speed mode
as default to work around Andes AE3XX platform's problem,
because of it does not support High-Speed mode in
commit id 73cd56b2df213c629191139e5c6705e069b6214f.

But other platforms or SoCs maybe support this function.
So High-Speed mode can be enabled from dts with
cap-mmc-highspeed or cap-sd-highspeed property.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agodoc: ae250: Describe riscv-linux booting via u-boot
Rick Chen [Tue, 13 Mar 2018 07:24:03 +0000 (15:24 +0800)]
doc: ae250: Describe riscv-linux booting via u-boot

Simply record riscv-linux booting steps and messages
from bbl via u-boot on QEMU in README.ae250.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agotools: mkimage: Support RISC-V arch
Rick Chen [Tue, 13 Mar 2018 05:37:29 +0000 (13:37 +0800)]
tools: mkimage: Support RISC-V arch

Add riscv uimage arch to support riscv-linux booting.
It can Convert riscv-linux to image which can be
booted by bootm command.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agoriscv: bootm: Remove ATAGS
Rick Chen [Tue, 13 Mar 2018 06:59:41 +0000 (14:59 +0800)]
riscv: bootm: Remove ATAGS

ATAGS is not supported and will be replaced
by DT in riscv-linux. So can be removed now.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agoriscv: bootm: Support to boot riscv-linux
Rick Chen [Tue, 13 Mar 2018 06:48:33 +0000 (14:48 +0800)]
riscv: bootm: Support to boot riscv-linux

riscv-linux should use BBL (Berkeley bootloader) for
loading the Linux kernel.

U-Boot can play as FSBL(first stage bootloader)
to boot BBL and riscv-linux.

In BBL's init_first_hart(), it will pass dtb with a1.
So implement bootm to pass arguments to BBL correctly.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agoriscv: checkpatch: Fix static const char * array declarations
Rick Chen [Mon, 12 Feb 2018 03:24:43 +0000 (11:24 +0800)]
riscv: checkpatch: Fix static const char * array declarations

It is reported by checkpatch.pl
WARNING: static const char * array
should probably be static const char * const

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agoriscv: checkpatch: Fix missing a blank line after declarations
Rick Chen [Mon, 12 Feb 2018 03:21:28 +0000 (11:21 +0800)]
riscv: checkpatch: Fix missing a blank line after declarations

It is reported by checkpatch.pl
WARNING: Missing a blank line after declarations.

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agoriscv: checkpatch: Fix alignment should match open parenthesis
Rick Chen [Mon, 12 Feb 2018 03:17:47 +0000 (11:17 +0800)]
riscv: checkpatch: Fix alignment should match open parenthesis

It is reported by checkpatch.pl.
CHECK: Alignment should match open parenthesis

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agoriscv: checkpatch: Fix use of volatile
Rick Chen [Mon, 12 Feb 2018 03:10:04 +0000 (11:10 +0800)]
riscv: checkpatch: Fix use of volatile

It is reported by checkpatch.pl
WARNING: Use of volatile is usually wrong: see
Documentation/process/volatile-considered-harmful.rst

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agoriscv: checkpatch: Fix Macro argument reuse
Rick Chen [Mon, 12 Feb 2018 03:07:58 +0000 (11:07 +0800)]
riscv: checkpatch: Fix Macro argument reuse

It is CHECK reported by checkpatch.pl
CHECK: Macro argument reuse 'PTE' - possible side-effects?

Signed-off-by: Rick Chen <rick@andestech.com>
Signed-off-by: Rick Chen <rickchen36@gmail.com>
6 years agoMerge git://git.denx.de/u-boot-rockchip
Tom Rini [Thu, 29 Mar 2018 12:25:56 +0000 (08:25 -0400)]
Merge git://git.denx.de/u-boot-rockchip

6 years agorockchip: sdhci: support 8bit bus-width
Philipp Tomsich [Mon, 26 Mar 2018 17:59:10 +0000 (19:59 +0200)]
rockchip: sdhci: support 8bit bus-width

The Rockchip-specific SDHCI wrapper does not process the 'bus-width'
property in the SDHCI node. Consequently, the bus is always kept in
4bit mode, even if 8bit wide operation is available, supported and
requested in the DTS.

This change adds processing of the 'bus-width' property and sets the
host capability flag for an 8bit wide bus, if set to 8. As the logic
in sdhci.c does not support clearing the 4bit capability, we assume
that 4bit operation is always supported.

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agorockchip: mmc: update MAINTAINERS
Philipp Tomsich [Mon, 26 Mar 2018 17:59:09 +0000 (19:59 +0200)]
rockchip: mmc: update MAINTAINERS

The Rockchip-specific wrappers to the DW-MMC and the SDHCI driver
were not covered as part of what's maintained by the architecture
maintainers.  Add them here.

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agorockchip: defconfig: puma-rk3399: enable DMA for SDHCI controller
Philipp Tomsich [Mon, 26 Mar 2018 17:59:08 +0000 (19:59 +0200)]
rockchip: defconfig: puma-rk3399: enable DMA for SDHCI controller

For the RK3399-Q7, we have a fast eMMC connected in an 8 bit wide
configuration to the SDHCI controller (sdhci@fe330000).  Enable DMA
within the SDHCI driver to get the best performance out of it.

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agorockchip: rk3399: set fdtfile
Mark Kettenis [Sat, 17 Mar 2018 08:48:25 +0000 (09:48 +0100)]
rockchip: rk3399: set fdtfile

Signed-off-by: Mark Kettenis <kettenis@openbsd.org>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Tested-by: Klaus Goger <klaus.goger@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agorockchip: clk: rk3188: update dpll settings to make EMAC work
Alexander Kochetkov [Mon, 26 Feb 2018 11:27:38 +0000 (14:27 +0300)]
rockchip: clk: rk3188: update dpll settings to make EMAC work

The patch set dpll settings for 300MHz to values used by binary
blob[1]. With new values dpll still generate 300MHz clock, but
EMAC work. Probably with new values dpll generate more stable clock.

dpll on rk3188 provide clocks to DDR and EMAC. With current
dpll settings EMAC doesn't work on radxa rock. EMAC sends packets
to network, but it doesn't receive anything. ifconfig shows a lot
of framing errors.

[1] https://github.com/linux-rockchip/u-boot-rockchip/blob/u-boot-rk3288/
    tools/rk_tools/3188_LPDDR2_300MHz_DDR3_300MHz_20130830.bin

Signed-off-by: Alexander Kochetkov <al.kochet@gmail.com>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agovideo: rk3288_mipi: Combine NULL check into IS_ERR_OR_NULL()
Punit Agrawal [Mon, 19 Mar 2018 17:36:07 +0000 (17:36 +0000)]
video: rk3288_mipi: Combine NULL check into IS_ERR_OR_NULL()

Signed-off-by: Punit Agrawal <punit.agrawal@arm.com>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agovideo: rk3288_mipi: check in rk_mipi_ofdata_to_platdata
Heinrich Schuchardt [Sun, 18 Mar 2018 14:25:41 +0000 (15:25 +0100)]
video: rk3288_mipi: check in rk_mipi_ofdata_to_platdata

The error checking should also catch the case that no range has beeen
defined.
syscon_get_first_range() returns NULL if no range is defined.
cf. rk3399_mipi.c

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agovideo: rk3399_mipi: Combine NULL check into IS_ERR_OR_NULL()
Punit Agrawal [Mon, 19 Mar 2018 17:36:08 +0000 (17:36 +0000)]
video: rk3399_mipi: Combine NULL check into IS_ERR_OR_NULL()

Signed-off-by: Punit Agrawal <punit.agrawal@arm.com>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agovideo: rk3399_mipi: correct error checking
Heinrich Schuchardt [Sun, 18 Mar 2018 14:18:10 +0000 (15:18 +0100)]
video: rk3399_mipi: correct error checking

Pointers are never negative. Use macro IS_ERR() for checking.
cf. rk3288_mipi.c

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agousb: rockchip: remove duplicate assignement.
Heinrich Schuchardt [Sun, 18 Mar 2018 12:17:37 +0000 (13:17 +0100)]
usb: rockchip: remove duplicate assignement.

Assigning f_rkusb->reboot_flag twice doesn't make sense.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agodriver: ram: rockchip: rk3399: missing counter increment
Heinrich Schuchardt [Sun, 18 Mar 2018 11:10:55 +0000 (12:10 +0100)]
driver: ram: rockchip: rk3399: missing counter increment

If we want to check the duration we need to increment the counter.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agorockchip: pinctrl: rk3188: Move the iomux definitions into pinctrl-driver
Alexander Kochetkov [Mon, 26 Feb 2018 14:27:56 +0000 (17:27 +0300)]
rockchip: pinctrl: rk3188: Move the iomux definitions into pinctrl-driver

Clean the iomux definitions at grf_rk3188.h, and move them into
pinctrl-driver for resolving the compiling error of redefinition.

Signed-off-by: Alexander Kochetkov <al.kochet@gmail.com>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agorockchip: pinctrl: rk3036: Move the iomux definitions into pinctrl-driver
Alexander Kochetkov [Mon, 26 Feb 2018 14:27:55 +0000 (17:27 +0300)]
rockchip: pinctrl: rk3036: Move the iomux definitions into pinctrl-driver

Clean the iomux definitions at grf_rk3036.h, and move them into
pinctrl-driver for resolving the compiling error of redefinition.

Signed-off-by: Alexander Kochetkov <al.kochet@gmail.com>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agorockchip: pinctrl: rk3399: add support for I2C[123467]
Philipp Tomsich [Mon, 12 Mar 2018 13:56:42 +0000 (14:56 +0100)]
rockchip: pinctrl: rk3399: add support for I2C[123467]

This adds support for the (to date unsupported) I2C controllers 1~4
and 6~7 (i.e. now all controllers except I2C5, which is not accessible
on the RK3399-Q7, are supported by pinctrl).

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Tested-by: Klaus Goger <klaus.goger@theobroma-systems.com>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agorockchip: pinctrl: rk3399: fix GPIO2B1 and GPIO2B2 shift value
Philipp Tomsich [Mon, 12 Mar 2018 13:56:41 +0000 (14:56 +0100)]
rockchip: pinctrl: rk3399: fix GPIO2B1 and GPIO2B2 shift value

The shift values for GPIO2B1 and GPIO2B2 had in fact referred to
GPIO2B0 and GPIO2B1, respectively.  This substitutes the correct
values.

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Acked-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
6 years agoMerge git://git.denx.de/u-boot-ubi
Tom Rini [Sun, 25 Mar 2018 16:02:13 +0000 (12:02 -0400)]
Merge git://git.denx.de/u-boot-ubi

6 years agoMerge git://git.denx.de/u-boot-spi
Tom Rini [Sun, 25 Mar 2018 16:01:44 +0000 (12:01 -0400)]
Merge git://git.denx.de/u-boot-spi

6 years agoMerge git://git.denx.de/u-boot-i2c
Tom Rini [Sun, 25 Mar 2018 16:00:48 +0000 (12:00 -0400)]
Merge git://git.denx.de/u-boot-i2c

6 years agoMerge tag 'xilinx-for-v2018.05' of git://git.denx.de/u-boot-microblaze
Tom Rini [Sun, 25 Mar 2018 16:00:00 +0000 (12:00 -0400)]
Merge tag 'xilinx-for-v2018.05' of git://git.denx.de/u-boot-microblaze

Xilinx changes for v2018.05

- Fix mkimage recognition
- Update all my fragments

ZynqMP:
- Use clk driver
- Support loading elfs in el1
- Various DTS and defconfig changes
- Enable newer pmufw versions
- Support more clocks
- Remove ep108
- Secure image support
- Fix memtest setup

Zynq:
- Enabling watchdog driver
- Support more clocks
- defconfig changes

fpga:
- Simplify error path

net:
- GMII case update

6 years agoConvert CONFIG_UBI_SILENCE_MSG to Kconfig
Petr Vorel [Sat, 24 Mar 2018 00:49:24 +0000 (01:49 +0100)]
Convert CONFIG_UBI_SILENCE_MSG to Kconfig

Signed-off-by: Petr Vorel <petr.vorel@gmail.com>
6 years agoConvert CONFIG_UBIFS_SILENCE_MSG to Kconfig
Petr Vorel [Sat, 24 Mar 2018 00:49:23 +0000 (01:49 +0100)]
Convert CONFIG_UBIFS_SILENCE_MSG to Kconfig

Introduce another difference from upstream (kernel) source in
fs/ubifs/super.c: adding preprocessor condition as y variable in
mount_ubifs() depends on CONFIG_UBIFS_SILENCE_MSG:
fs/ubifs/super.c:1337:15: error: variable ?y? set but not used [-Werror=unused-but-set-variable]
  long long x, y;

Not setting CONFIG_UBIFS_SILENCE_MSG in am335x_igep003x_defconfig and
igep0032_defconfig. Although it was defined in their config headers, it
depends on CMD_UBIFS which is not set for them.

Signed-off-by: Petr Vorel <petr.vorel@gmail.com>
Cc: Joe Hershberger <joe.hershberger@ni.com>
Cc: Heiko Schocher <hs@denx.de>
6 years agoubifs: Reintroduce using CONFIG_UBIFS_SILENCE_MSG
Petr Vorel [Sat, 24 Mar 2018 00:49:22 +0000 (01:49 +0100)]
ubifs: Reintroduce using CONFIG_UBIFS_SILENCE_MSG

Use of CONFIG_UBIFS_SILENCE_MSG was added in
147162dac6 ("ubi: ubifs: Turn off verbose prints")

Then it was removed in
ff94bc40af ("mtd, ubi, ubifs: resync with Linux-3.14")

Cc: Joe Hershberger <joe.hershberger@ni.com>
Cc: Heiko Schocher <hs@denx.de>
Signed-off-by: Petr Vorel <petr.vorel@gmail.com>
6 years agoomap3: spi: Correct ti, pindir-d0-out-d1-in parsing
Sjoerd Simons [Thu, 22 Mar 2018 21:55:02 +0000 (22:55 +0100)]
omap3: spi: Correct ti, pindir-d0-out-d1-in parsing

The ti,pindir-d0-out-d1-in property is not expected to have a value
according to the device-tree binding, so treat it as a boolean not a
uint property.

Signed-off-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk>
Reviewed-by: Jagan Teki <jagan@openedev.com>
6 years agoMerge git://git.denx.de/u-boot-arc
Tom Rini [Fri, 23 Mar 2018 13:31:24 +0000 (09:31 -0400)]
Merge git://git.denx.de/u-boot-arc

Alexey:
 1. Significantly rework cache-related functionality.
    In particular that fixes coherency problems in some corner-cases,
    allows us to enable and disable caches in run-time and still
    have properly running system, finally support execution from
    real flash (before we used to run from DDR from the very beginning).

 2. Remove string routines implemented in assembly.
    That allows us to build and run U-Boot on wide range of ARC cores
    with different configurations. I.e. whatever tuning is used on GCC's
    command-line we'll get code for desired flavor of ARC.
    Otherwise for each and every corner-case we would need to add ifdefs
    in assembly code to accommodate missing instructions etc.

 3. Get use of GCC's garbage collector which helps to slim-down resulting image
    quite a bit.

 4. Also now we may disable U-Boot self-relocation for ARC if needed either
    by platform or for debugging purposes.

6 years agoARC: bootm: Refactor GO and PREP subcommands implementation
Eugeniy Paltsev [Fri, 23 Mar 2018 12:35:03 +0000 (15:35 +0300)]
ARC: bootm: Refactor GO and PREP subcommands implementation

Refactor GO and PREP subcommands implementation for a simpler
override in the boards platform code.

Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
6 years agoMAINTAINERS: Fix Zynq/ZynqMP and Microblaze fragments
Michal Simek [Tue, 13 Mar 2018 10:07:25 +0000 (11:07 +0100)]
MAINTAINERS: Fix Zynq/ZynqMP and Microblaze fragments

Fix my fragments to list all files in the repo.

Also fix path to for Xilinx Zynq SoC (mach-zynq)
It should be the part of
"ARM: zynq: move SoC sources to mach-zynq"
(sha1: 0107f2403669f764ab726d0d404e35bb9447bbcc)

And cover dts files in board MAINTAINERS files.

Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agotools: xilinx: Fix zynq/zynqmp image recognition
Michal Simek [Wed, 14 Mar 2018 10:02:24 +0000 (11:02 +0100)]
tools: xilinx: Fix zynq/zynqmp image recognition

There is an issue to recognize zynq or zynqmp image because header
checking is just the same. That's why zynqmp images are recognized as
zynq one.
Check unused fields which are initialized to zero in zynq format
(__reserved1 0x38 and __reserved2 0x44) which are initialized for
zynqmp. This should ensure that images are properly recognized by:
./tools/mkimage -l spl/boot.bin

Also show image type as ZynqMP instead of Zynq which is confusing.

Reported-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Tested-by: Alexander Graf <agraf@suse.de>
6 years agoarm64: zynqmp: Add support for verifying secure images
Siva Durga Prasad Paladugu [Wed, 28 Feb 2018 07:56:53 +0000 (13:26 +0530)]
arm64: zynqmp: Add support for verifying secure images

This patch adds new command "zynqmp" to handle zynqmp
specific commands like "zynqmp secure". This secure command is
used for verifying zynqmp specific secure images. The secure
image can either be authenticated or encrypted or both encrypted
and authenticated. The secure image is prepared using bootgen
and will be in xilinx specific BOOT.BIN format. The optional
key can be used for decryption of encrypted image if user
key was specified while creation BOOT.BIN.

Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm64: zynqmp: Remove ep108 board
Michal Simek [Fri, 2 Mar 2018 07:11:43 +0000 (08:11 +0100)]
arm64: zynqmp: Remove ep108 board

ZynqMP Emulation board is no longer tested and there is no reason to
keep maintaining it.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm64: zynqmp: Correct EG/EV part detection logic
Siva Durga Prasad Paladugu [Fri, 2 Mar 2018 10:50:10 +0000 (16:20 +0530)]
arm64: zynqmp: Correct EG/EV part detection logic

The vcu disable bit in efuse ipdisable register is valid only
if PL powered up so, consider PL powerup status for determing
EG/EV part. If PL is not powered up, ignore EG/EV part of string.
The PL powerup status will be filled by pmufw based on PL PROGB
status in the 9th bit of version field.

Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm64: zynqmp: Print the value of pl clocks and wdt clock using clk dump
Vipul Kumar [Wed, 7 Mar 2018 09:22:44 +0000 (14:52 +0530)]
arm64: zynqmp: Print the value of pl clocks and wdt clock using clk dump

This patch print pl clocks (pl0...pl3) and watchdog
clock using clk dump.

Signed-off-by: Vipul Kumar <vipulk@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm64: zynqmp: nand: Fixed NAND erase issue for size 1GiB or more
Vipul Kumar [Mon, 5 Mar 2018 09:54:59 +0000 (15:24 +0530)]
arm64: zynqmp: nand: Fixed NAND erase issue for size 1GiB or more

NAND erase was not happening for size 1GiB or more. Erase
command was executing successfully but in actual, it was not
erasing.
This patch fixed erase issue for 1 GiB or more size nand.

Signed-off-by: Vipul Kumar <vipulk@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm: zynq: Remove OF_EMBED configuration for zc770 xm011 x16
Michal Simek [Mon, 26 Feb 2018 14:19:36 +0000 (15:19 +0100)]
arm: zynq: Remove OF_EMBED configuration for zc770 xm011 x16

Use appended dtb which is default option for zynq boards.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm: zynq: Setup the same bootcommand as for zc770 xm011 x8
Michal Simek [Mon, 26 Feb 2018 14:16:53 +0000 (15:16 +0100)]
arm: zynq: Setup the same bootcommand as for zc770 xm011 x8

The same command should be used for x16 configuration.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm64: zynqmp: Changed scratch address used by the alternate memory test
Vipul Kumar [Thu, 15 Feb 2018 05:54:41 +0000 (11:24 +0530)]
arm64: zynqmp: Changed scratch address used by the alternate memory test

This patch changed CONFIG_SYS_MEMTEST_SCRATCH address to the
accessible DDR address used by alternate memory test.
Before this, 0xfffc0000 address was used, which is the OCM
address and not enabled in MMU table. So, whenever trying
to access 0xfffc0000 address, got Synchronous Abort exception.

After changing CONFIG_SYS_MEMTEST_SCRATCH address, alternate
memory test is working fine.

Signed-off-by: Vipul Kumar <vipulk@xilinx.com>
Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm: zynq: Enable cadence driver on zc706
Michal Simek [Wed, 21 Feb 2018 16:03:55 +0000 (17:03 +0100)]
arm: zynq: Enable cadence driver on zc706

Enable watchdog with reset-on-timeout feature.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm: zynq: Wire watchdog internals
Michal Simek [Wed, 21 Feb 2018 16:04:28 +0000 (17:04 +0100)]
arm: zynq: Wire watchdog internals

Watchdog is only enabled in full u-boot. Adoption for SPL should be also
done because that's the right place where watchdog should be enabled.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agowatchdog: Add Cadence watchdog driver
Shreenidhi Shedi [Wed, 21 Feb 2018 15:50:20 +0000 (16:50 +0100)]
watchdog: Add Cadence watchdog driver

This IP can be found on Zynq and ZynqMP devices.
The driver was tested with reset-on-timeout; feature.

Also adding WATCHDOG symbol to Kconfig because it is required.

Signed-off-by: Shreenidhi Shedi <imshedi@gmail.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoclk: zynq: Show watchdog clock rate properly
Michal Simek [Wed, 21 Feb 2018 14:06:20 +0000 (15:06 +0100)]
clk: zynq: Show watchdog clock rate properly

watchdog clock is also connected to cpu 1X clocksource.

Zynq> clk dump
...

Before:
      swdt          4294967290
After:
      swdt           111111110

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm64: zynqmp: Enable newer pmufw versions
Michal Simek [Thu, 8 Feb 2018 07:51:36 +0000 (08:51 +0100)]
arm64: zynqmp: Enable newer pmufw versions

As of now newer pmufw is keeping old interfaces. That's why permit
u-boot to run on newer version. Recommended version will be setup later.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agonet: zynq_gem: Dont run any phy detection logic for GMII case
Siva Durga Prasad Paladugu [Tue, 20 Feb 2018 06:26:19 +0000 (11:56 +0530)]
net: zynq_gem: Dont run any phy detection logic for GMII case

This patch bypasses phy detection logic for GMII interface
and just depend on phy address received from DT. This patch
is required as phy detection logic is different for some phys
like xilinx phy which can be connected over SGMII and GMII
interface.
This fixes the issue of ethernet failures when xilinx phy is
connected over GMII interface.

Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
6 years agoarm64: zynqmp: Add support to load an app at EL1
Nitin Jain [Fri, 16 Feb 2018 07:26:17 +0000 (12:56 +0530)]
arm64: zynqmp: Add support to load an app at EL1

This patch is adding support to switch to EL1 while loading an EL1
application with u-boot running at EL above EL1 in aarch64 mode.

Signed-off-by: Nitin Jain <nitinj@xilinx.com>
Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm: zynq: Enable debug uart on Zedboard
Siva Durga Prasad Paladugu [Wed, 24 Jan 2018 11:50:32 +0000 (17:20 +0530)]
arm: zynq: Enable debug uart on Zedboard

It helps with debugging.

Signed-off-by: Siva Durga Prasad Paladugu <sivadur@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm64: zynqmp: Enable ethernet driver for zc1751-dc5
Michal Simek [Wed, 31 Jan 2018 08:18:33 +0000 (09:18 +0100)]
arm64: zynqmp: Enable ethernet driver for zc1751-dc5

Enable missing driver on this board.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agofpga: Simplify error path in fpga_add
Michal Simek [Fri, 26 Jan 2018 12:17:04 +0000 (13:17 +0100)]
fpga: Simplify error path in fpga_add

Check !desc earlier to simplify code.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Simon Goldschmidt <sgoldschmidt@de.pepperl-fuchs.com>
Reviewed-by: Simon Goldschmidt <sgoldschmidt@de.pepperl-fuchs.com>
6 years agoxilinx: Sync defconfigs with latest Kconfig updates
Michal Simek [Fri, 23 Mar 2018 08:34:00 +0000 (09:34 +0100)]
xilinx: Sync defconfigs with latest Kconfig updates

Make defconfigs up2date with current location.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoarm64: zynqmp: Convert board to use zynqmp-clk driver
Michal Simek [Fri, 8 Dec 2017 13:50:42 +0000 (14:50 +0100)]
arm64: zynqmp: Convert board to use zynqmp-clk driver

Use zynqmp clock driver instead of fixed clocks.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
6 years agoi2c: lpi2c: remove superfluous assignments
Heinrich Schuchardt [Sun, 18 Mar 2018 10:14:56 +0000 (11:14 +0100)]
i2c: lpi2c: remove superfluous assignments

In

lpi2c_status_t result = A;
result = B;

the first assignment has no effect. Let's remove it.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>