oweals/u-boot.git
5 years agoPrepare v2019.04-rc2 v2019.04-rc2
Tom Rini [Tue, 19 Feb 2019 02:36:39 +0000 (21:36 -0500)]
Prepare v2019.04-rc2

Signed-off-by: Tom Rini <trini@konsulko.com>
5 years agoconfigs: Enable CONFIG_BLK in am57xx_evm and am57xx_hs_evm
Jean-Jacques Hiblot [Fri, 8 Feb 2019 09:55:06 +0000 (10:55 +0100)]
configs: Enable CONFIG_BLK in am57xx_evm and am57xx_hs_evm

Enable CONFIG_DM_SCSI and CONFIG_BLK.

Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com>
5 years agoconfigs: k2g_evm: Enable CONFIG_BLK
Jean-Jacques Hiblot [Fri, 8 Feb 2019 09:55:05 +0000 (10:55 +0100)]
configs: k2g_evm: Enable CONFIG_BLK

CONFIG_BLK can be safely enabled as DM_MMC and DM_USB are already enabled.

Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com>
Tested-by: Vignesh R <vigneshr@ti.com>
5 years agoefi_loader: Swap roles with Heinrich
Alexander Graf [Thu, 14 Feb 2019 13:35:17 +0000 (14:35 +0100)]
efi_loader: Swap roles with Heinrich

Heinrich is going to take over maintainership of the efi_loader tree
going forward.

To ensure that I will still receive review mails at least, add me as
reviewer with a stable email address.

Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Tom Rini <trini@konsulko.com>
5 years agorpi: Make Matthias maintainer
Alexander Graf [Thu, 14 Feb 2019 13:37:59 +0000 (14:37 +0100)]
rpi: Make Matthias maintainer

Matthias Brugger agreed to take over maintainership from me for the
Raspberry Pi tree. Add him to the MAINTAINERS file instead.

Signed-off-by: Alexander Graf <agraf@suse.de>
Reviewed-by: Tom Rini <trini@konsulko.com>
5 years agoboard/BuR/brppt1: fix ethernet support on brppt1 boards
Hannes Schmelzer [Fri, 15 Feb 2019 10:15:05 +0000 (11:15 +0100)]
board/BuR/brppt1: fix ethernet support on brppt1 boards

The commit 1bac199e8c87 ("configs: Resync with savedefconfig")
did remove ethernet driver from following boards defconfig:

- brppt1_mmc
- brppt1_nand
- brppt1_spi

With this commit we add ethernet and responsible phy support again.

Signed-off-by: Hannes Schmelzer <hannes.schmelzer@br-automation.com>
5 years agoMerge tag 'efi-2019-04-rc2' of https://github.com/xypron2/u-boot
Tom Rini [Mon, 18 Feb 2019 20:48:01 +0000 (15:48 -0500)]
Merge tag 'efi-2019-04-rc2' of https://github.com/xypron2/u-boot

The patches fix multiple errors. Mentionable are:
- EFI unit tests (bootefi selftest) can run on i386.
- `make tests` executes the Unicode unit tests.

The LoadImage patch is preparing for further rework to be delivered
in v2019.07.

5 years agoMerge tag 'video-for-2019.04-rc2' of git://git.denx.de/u-boot-video
Tom Rini [Sat, 16 Feb 2019 23:10:53 +0000 (18:10 -0500)]
Merge tag 'video-for-2019.04-rc2' of git://git.denx.de/u-boot-video

- sunxi display DDC probe fallback
- support 24bpp BMP files on 16bpp displays

5 years agoMerge branch 'master' of git://git.denx.de/u-boot-sh
Tom Rini [Sat, 16 Feb 2019 22:05:51 +0000 (17:05 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-sh

- Various MMC fixes

5 years agommc: tmio: sdhi: Configure DT2FF register for HS400 mode
Marek Vasut [Thu, 14 Feb 2019 14:16:15 +0000 (15:16 +0100)]
mmc: tmio: sdhi: Configure DT2FF register for HS400 mode

The DT2FF register must be configured differently for HS400 mode
and for HS200/SDR104 mode. Configure the DT2FF register according
to the recommended datasheet settings for each mode.

Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
5 years agommc: tmio: Configure HOST_MODE WMODE according to bus width
Marek Vasut [Thu, 14 Feb 2019 14:16:24 +0000 (15:16 +0100)]
mmc: tmio: Configure HOST_MODE WMODE according to bus width

Set the HOST_MODE register WMODE bit according to the SDHI bus width,
that is 0 for 64bit bus and 1 for 16/32bit bus.

Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
5 years agommc: Downgrade SD/MMC from UHS/HS200/HS400 modes before boot
Marek Vasut [Tue, 29 Jan 2019 03:45:51 +0000 (04:45 +0100)]
mmc: Downgrade SD/MMC from UHS/HS200/HS400 modes before boot

Older kernel versions or systems which do not connect eMMC reset line
properly may not be able to handle situations where either the eMMC
is left in HS200/HS400 mode or SD card in UHS modes by the bootloader
and may misbehave. Downgrade the eMMC to HS/HS52 mode and/or SD card
to non-UHS mode before booting the kernel to allow such older kernels
to work with modern U-Boot.

Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Tom Rini <trini@konsulko.com>
5 years agoefi_loader: do not miss last relocation block
Heinrich Schuchardt [Sat, 16 Feb 2019 14:36:33 +0000 (15:36 +0100)]
efi_loader: do not miss last relocation block

If the last block in the relocation table contains only a single
relocation, the current coding ignores it.

Fix the determination of the end of the relocation table.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_loader: documentation of image loader
Heinrich Schuchardt [Sat, 16 Feb 2019 14:22:13 +0000 (15:22 +0100)]
efi_loader: documentation of image loader

- Add missing function descriptions.
- Update existing function descriptions to match Sphinx style.
- Add lib/efi_loader/efi_image_loader.c to the input files for Sphinx
  generated documentation.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_loader: clean up bootefi_test_prepare()
Heinrich Schuchardt [Sat, 12 Jan 2019 13:42:40 +0000 (14:42 +0100)]
efi_loader: clean up bootefi_test_prepare()

Free resources upon failure.

Correct the function description.

As there is no need for any special address in the dummy memory device
path passed via the EFI_LOADED_IMAGE_PROTOCOL simply use 0 as address.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_loader: fix EFI entry counting
Heinrich Schuchardt [Sat, 9 Feb 2019 13:10:39 +0000 (14:10 +0100)]
efi_loader: fix EFI entry counting

`bootefi selftest` fails on qemu-x86_defconfig if efi_selftest() is not
invoked using EFI_CALL().

Likewise we call the entry point of EFI payloads with
EFI_CALL(efi_start_image()).

entry_count indicates if we are in U-Boot (1) or in EFI payload code (0).
As we start in U-Boot code the initial value has to be 1.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_loader: use efi_start_image() for bootefi
Heinrich Schuchardt [Wed, 26 Dec 2018 12:28:09 +0000 (13:28 +0100)]
efi_loader: use efi_start_image() for bootefi

Remove the duplicate code in efi_do_enter() and use efi_start_image() to
start the image invoked by the bootefi command.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_loader: set entry point in efi_load_pe()
Heinrich Schuchardt [Wed, 26 Dec 2018 11:49:09 +0000 (12:49 +0100)]
efi_loader: set entry point in efi_load_pe()

Up to now efi_load_pe() returns the entry point or NULL in case of an
error. This does not allow to return correct error codes from LoadImage().

Let efi_load_pe() return a status code and fill in the entry point in the
corresponding field of the image object.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_loader: LoadImage: always allocate new pages
Heinrich Schuchardt [Mon, 24 Dec 2018 08:19:07 +0000 (09:19 +0100)]
efi_loader: LoadImage: always allocate new pages

If we want to properly unload images in Exit() the memory should always be
allocated in the same way. As we allocate memory when reading from file we
should do the same when the original image is in memory.

A further patch will be needed to free the memory when Exit() is called.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_loader: error handling in efi_setup_loaded_image()
Heinrich Schuchardt [Wed, 6 Feb 2019 18:41:29 +0000 (19:41 +0100)]
efi_loader: error handling in efi_setup_loaded_image()

In case of an error we should set the returned pointers to NULL. This
ensures that an illegal free does not occur even if the caller calls
free() for the handles.

If protocols cannot be installed, release all resources.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agotest: adjust names of Unicode test functions
Heinrich Schuchardt [Fri, 15 Feb 2019 22:12:50 +0000 (23:12 +0100)]
test: adjust names of Unicode test functions

In test/py/conftest.py the assumption is made that for if a test is called
with `ut unicode` the test function name starts with 'unicode_test_'. As
the Unicode tests did not follow this naming scheme they were not executed
by `make tests`.

Rename the Unicode test functions.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agolib/vsprintf: print '?' for illegal Unicode sequence
Heinrich Schuchardt [Fri, 15 Feb 2019 21:20:53 +0000 (22:20 +0100)]
lib/vsprintf: print '?' for illegal Unicode sequence

Commit 0e66c10a7d80 ("lib: vsprintf: avoid overflow printing UTF16
strings") broke the Unicode unit tests: an illegal UTF16 code point
should be printed as '?'.

Fixes: 0e66c10a7d80 ("lib: vsprintf: avoid overflow printing UTF16 strings")
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_selftest: LoadImage from file device path
Heinrich Schuchardt [Wed, 9 Jan 2019 18:04:14 +0000 (19:04 +0100)]
efi_selftest: LoadImage from file device path

Provide a unit test that calls LoadImage() with a file device path and
executes the application via StartImage().

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_loader: comments for efi_file_from_path()
Heinrich Schuchardt [Mon, 4 Feb 2019 20:24:35 +0000 (21:24 +0100)]
efi_loader: comments for efi_file_from_path()

Add more comments for efi_file_from_path().

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_loader: efi_dp_split_file_path() error handling
Heinrich Schuchardt [Mon, 4 Feb 2019 11:49:43 +0000 (12:49 +0100)]
efi_loader: efi_dp_split_file_path() error handling

If the path passed to efi_dp_split_file_path() does not contain a
reference to a file it returns EFI_OUT_OF_RESOURCES. This does not properly
indicate the kind of the problem that occurred. Return
EFI_INVALID_PARAMETER instead.

Update function description.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
5 years agoefi_selftest: fix memory allocation in HII tests
Heinrich Schuchardt [Tue, 12 Feb 2019 20:38:02 +0000 (21:38 +0100)]
efi_selftest: fix memory allocation in HII tests

In efi_selftest we are in EFI land. We cannot call U-Boot library
functions malloc() and free() but should use the boot time services
instead.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Alexander Graf <agraf@suse.de>
5 years agoefi_selftest: do not use efi_free_pool()
Heinrich Schuchardt [Tue, 12 Feb 2019 20:50:45 +0000 (21:50 +0100)]
efi_selftest: do not use efi_free_pool()

In efi_selftest we are in EFI land. We should not use U-Boot library
functions but boot time services for memory management.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Alexander Graf <agraf@suse.de>
5 years agoMerge tag 'u-boot-imx-2019-02-16' of git://git.denx.de/u-boot-imx
Tom Rini [Sat, 16 Feb 2019 13:31:05 +0000 (08:31 -0500)]
Merge tag 'u-boot-imx-2019-02-16' of git://git.denx.de/u-boot-imx

u-boot-imx-2019-02-16
---------------------

- vhybrid: add calibration
- gw_ventana: fixes
- Improve documentation for Secure Boot (HABv4)
- Fix Marvell Switch
- MX6 Sabre, switch to DM
- Fixes for NAND

5 years agoMerge tag 'xilinx-for-v2019.04-rc2' of git://git.denx.de/u-boot-microblaze
Tom Rini [Sat, 16 Feb 2019 02:21:28 +0000 (21:21 -0500)]
Merge tag 'xilinx-for-v2019.04-rc2' of git://git.denx.de/u-boot-microblaze

Xilinx changes for v2019.04-rc2

xilinx:
- Start to use distro boot commands first
- Setup fdtfile on ZynqMP
- Move mac addr eeprom read to common location
- Convert to OF_SEPARATE
- Switch all board to DM_I2C
- Some DT syncs

i2c:
- Remove !DM_I2C zynq driver

versal:
- Enable some more features
- Add mini configurations

5 years agoMerge tag '2019.01-next' of https://github.com/mbgg/u-boot
Tom Rini [Sat, 16 Feb 2019 01:10:15 +0000 (20:10 -0500)]
Merge tag '2019.01-next' of https://github.com/mbgg/u-boot

- add compute module 3+
- fix 64 bit warning in bmp command

5 years agoimx: cpu.c: give access to reset cause in spl
Max Krummenacher [Fri, 1 Feb 2019 15:04:51 +0000 (16:04 +0100)]
imx: cpu.c: give access to reset cause in spl

This makes get_imx_reset_cause() accessible in SPL, but keeps the SRSR
register content intact so that U-Boot proper can evaluated the
reset_cause again should this be needed.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
5 years agoimx: serial_mxc: disable ri and dcd irq in dte mode
Max Krummenacher [Fri, 1 Feb 2019 15:04:50 +0000 (16:04 +0100)]
imx: serial_mxc: disable ri and dcd irq in dte mode

If the UART is used in DTE mode the RI and DCD bits in UCR3 become
irq enable bits. Both are set to enabled after reset and both likely
are pending.

Disable the bits to prevent an interrupt storm when Linux enables
the UART interrupts.

Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
5 years agoARM: dts: i.MX6Q, i.MX6QDL: fix address/size-cells warnings
Marcel Ziswiler [Fri, 1 Feb 2019 15:04:49 +0000 (16:04 +0100)]
ARM: dts: i.MX6Q, i.MX6QDL: fix address/size-cells warnings

This fixes the following warnings:

arch/arm/dts/imx6-apalis.dtb: Warning (avoid_unnecessary_addr_size):
 /clocks: unnecessary #address-cells/#size-cells without "ranges" or
 child "reg" property
arch/arm/dts/imx6-apalis.dtb: Warning (avoid_unnecessary_addr_size):
 /soc/aips-bus@02100000/mipi@021e0000: unnecessary #address-cells/
 #size-cells without "ranges" or child "reg" property
arch/arm/dts/imx6-apalis.dtb: Warning (avoid_unnecessary_addr_size):
 /soc/ipu@02400000/port@2: unnecessary #address-cells/#size-cells
 without "ranges" or child "reg" property
arch/arm/dts/imx6-apalis.dtb: Warning (avoid_unnecessary_addr_size):
 /soc/ipu@02400000/port@3: unnecessary #address-cells/#size-cells
 without "ranges" or child "reg" property
arch/arm/dts/imx6-apalis.dtb: Warning (avoid_unnecessary_addr_size):
 /soc/ipu@02800000/port@2: unnecessary #address-cells/#size-cells
 without "ranges" or child "reg" property
arch/arm/dts/imx6-apalis.dtb: Warning (avoid_unnecessary_addr_size):
 /soc/ipu@02800000/port@3: unnecessary #address-cells/#size-cells
 without "ranges" or child "reg" property

Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
5 years agoimx: ventana: fix usage of dt paths with leading 0s (Linux 4.15+)
Tim Harvey [Mon, 4 Feb 2019 21:11:00 +0000 (13:11 -0800)]
imx: ventana: fix usage of dt paths with leading 0s (Linux 4.15+)

device-tree paths should never be used that reference node addresses
making an assumption about leading zeros. They should not be there per
the device-tree specification however they have been there until Linux
4.15 when they were removed via kernel commit
8dccafaa281aa1d240a58bbcdff338aec114a021.

This fixes various issues which will occur when using Linux 4.15+
that are being fixed up on a per model per PCB revision basis such as:
 - enabling MMC UHS-I on board revisions that support it
 - enabling PWM based on hwconfig
 - fixing PCIe reset on GW552x
 - removing cpu external watchdog reset on boards that do not support it
 - populate PCI dt nodes based on PCI scan in order to fix GW16082
   interrupt mapping and inject MAC address for PCI based GbE

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: gw5904/gw5909: disable RS485
Tim Harvey [Mon, 4 Feb 2019 21:10:59 +0000 (13:10 -0800)]
imx: ventana: gw5904/gw5909: disable RS485

The GW5904/GW5909 have a SP33E multi-protocol serial transceiver which we
want to configure to RS232 by default (by de-asserting RS485_EN)

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: add support for GW5901/GW5902
Tim Harvey [Mon, 4 Feb 2019 21:10:58 +0000 (13:10 -0800)]
imx: ventana: add support for GW5901/GW5902

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: add support for GW5909
Tim Harvey [Mon, 4 Feb 2019 21:10:57 +0000 (13:10 -0800)]
imx: ventana: add support for GW5909

The GW5909 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW5904 but with half the DRAM loaded
and an additional RS232 transceiver off UART2.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: add support for GW5908
Tim Harvey [Mon, 4 Feb 2019 21:10:56 +0000 (13:10 -0800)]
imx: ventana: add support for GW5908

The GW5908 is a small single board computer based on the i.MX6DL SoC
with the same peripheral set as the GW530x but with 1GiB density DRAM
(64bit 512MiB).

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: add support for GW5907
Tim Harvey [Mon, 4 Feb 2019 21:10:55 +0000 (13:10 -0800)]
imx: ventana: add support for GW5907

The GW5907 is a small single board computer based on the i.MX6DL SoC
with the following peripheral set:
 - DDR3 memory (512MB default)
 - 1x GigE (i.MX6 FEC)
 - Gateworks System Controller

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: add support for GW5906
Tim Harvey [Mon, 4 Feb 2019 21:10:54 +0000 (13:10 -0800)]
imx: ventana: add support for GW5906

The GW5906 is a GW552x with mechanical and power supply connector
differences.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: add i2c detect for all LVDS displays
Tim Harvey [Mon, 4 Feb 2019 21:10:53 +0000 (13:10 -0800)]
imx: ventana: add i2c detect for all LVDS displays

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: skip nand init for nandless boards
Tim Harvey [Mon, 4 Feb 2019 21:10:52 +0000 (13:10 -0800)]
imx: ventana: skip nand init for nandless boards

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: add support for Z101WX01 LVDS display
Tim Harvey [Mon, 4 Feb 2019 21:10:51 +0000 (13:10 -0800)]
imx: ventana: add support for Z101WX01 LVDS display

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: add support for GW5905
Tim Harvey [Mon, 4 Feb 2019 21:10:50 +0000 (13:10 -0800)]
imx: ventana: add support for GW5905

The GW5905 is single-board tablet computer based on the i.MX6 SoC with the
following peripheral set:
 - eMMC flash (boot device)
 - microSD expansion
 - LVDS display connector for off-board 3D+1C with PWM backlight
   and I2C based touch controller
 - MIPI camera connector supporting the TRULY CM8487-B500SA-E (OV5640)
 - ublox EMMY-W1 WiFi/Bluetooth/NFC module (SDIO/UART)
 - ublox ZOE-M8Q GPS
 - LSM9DS1 9-DOF IMU
 - 1x 1-lane miniPCIe socket with USB 2.0
 - Gateworks System Controller
 - Audio jack with TLV320AIC Audio Codec, Speaker AMP
   and TSA227E Headphone detect
 - MAX8607 3-mode LED camera flash
 - DECT ULE module
 - FUSB302 USB-C PD and ISL9238 Battery charger

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: remove setup of I2C3 from SPL
Tim Harvey [Mon, 4 Feb 2019 21:10:49 +0000 (13:10 -0800)]
imx: ventana: remove setup of I2C3 from SPL

Do not setup I2C3 in the SPL for Ventana as some devices on that bus
(aic3x codecs) can hang the bus causing i2c_setup to spin endlessly until
they are put into reset. Removing the setup of I2C3 from the SPL allows
the board-specific GPIO to be configured to take care of putting codecs
in reset prior to U-Boot setting up I2C3.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: do not iomux UART1
Tim Harvey [Mon, 4 Feb 2019 21:10:48 +0000 (13:10 -0800)]
imx: ventana: do not iomux UART1

The only UART that is garunteed on Ventana boards is UART2 (serial-console).

Remove UART1 pinmux as that it is not consistent across all Ventana boards
and U-Boot doesn't need it.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoimx: ventana: mv88e61xx change LED configuration
Tim Harvey [Mon, 4 Feb 2019 21:10:47 +0000 (13:10 -0800)]
imx: ventana: mv88e61xx change LED configuration

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
5 years agoconfigs: mx6sabresd: Reduce SPL size by disabling DOS, EXT and EFI support
Abel Vesa [Fri, 1 Feb 2019 16:40:25 +0000 (16:40 +0000)]
configs: mx6sabresd: Reduce SPL size by disabling DOS, EXT and EFI support

With DM and FIT enabled in SPL, there is an sram overflow. By disabling
CONFIG_SPL_DOS_PARTITION, CONFIG_SPL_EXT_SUPPORT and
CONFIG_SPL_EFI_PARTITION, we get to keep the 'one binary to fit all'
for imx6[q|qp|dl] on sabresd since the final SPL image is now under 64KB.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agoboard: mx6sabresd: Remove the enet reset gpio handling
Abel Vesa [Fri, 1 Feb 2019 16:40:24 +0000 (16:40 +0000)]
board: mx6sabresd: Remove the enet reset gpio handling

Rely on the phy-reset-gpios which is set in imx6qdl-sabresd dtsi
and get rid of the enet reset gpio handling from the board file.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agoboard: mx6sabresd: Remove non-DM code
Abel Vesa [Fri, 1 Feb 2019 16:40:23 +0000 (16:40 +0000)]
board: mx6sabresd: Remove non-DM code

Since the mx6sabreauto has DM support, remove the unused non-DM code
from mx6sabresd board file.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agoconfigs: mx6sabresd: Add DM_SPI_FLASH necessary configs
Abel Vesa [Fri, 1 Feb 2019 16:40:22 +0000 (16:40 +0000)]
configs: mx6sabresd: Add DM_SPI_FLASH necessary configs

Enable all neceassary configs to support DM_SPI_FLASH on mx6sabresd.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agoboard: mx6sabreauto: Remove the non-DM code
Abel Vesa [Fri, 1 Feb 2019 16:40:22 +0000 (16:40 +0000)]
board: mx6sabreauto: Remove the non-DM code

Since the mx6sabreauto has DM support, remove the unused non-DM code
from mx6sabreauto board file.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agoconfigs: mx6sabreauto: Add DM_SPI_FLASH necessary configs
Abel Vesa [Fri, 1 Feb 2019 16:40:20 +0000 (16:40 +0000)]
configs: mx6sabreauto: Add DM_SPI_FLASH necessary configs

Enable all neceassary configs to support DM_SPI_FLASH on mx6sabreauto.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agomx6sabreauto: Add DM_GPIO support
Abel Vesa [Fri, 1 Feb 2019 16:40:19 +0000 (16:40 +0000)]
mx6sabreauto: Add DM_GPIO support

Add the DM_GPIO related config for mx6sabreauto.
Also add the gpio request calls.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agomx6sabresd: Add DM_GPIO support
Abel Vesa [Fri, 1 Feb 2019 16:40:19 +0000 (16:40 +0000)]
mx6sabresd: Add DM_GPIO support

Add the DM_GPIO related config for mx6sabresd.
Also add the gpio request calls.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agoconfigs: mx6sabresd: Add SPL FIT and DM support
Abel Vesa [Fri, 1 Feb 2019 16:40:18 +0000 (16:40 +0000)]
configs: mx6sabresd: Add SPL FIT and DM support

Enable all the necessary configs for SPL DM and FIT support for
mx6sabresd.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agoconfigs: mx6sabreauto: Add SPL FIT and DM support
Abel Vesa [Fri, 1 Feb 2019 16:40:17 +0000 (16:40 +0000)]
configs: mx6sabreauto: Add SPL FIT and DM support

Enable all the necessary configs for SPL DM and FIT support for
mx6sabreauto.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agoarm: dts: Update all the dts[i] files for imx6[q|qp|dl] sabre[auto|sd]
Abel Vesa [Fri, 1 Feb 2019 16:40:16 +0000 (16:40 +0000)]
arm: dts: Update all the dts[i] files for imx6[q|qp|dl] sabre[auto|sd]

Update all the dts[i] files for imx6[q|qp|dl] sabre[auto|sd] to the ones
from kernel v4.20 (commit 8fe28cb58bcb2).

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Acked-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
Reviewed-by: Lukasz Majewski <lukma@denx.de>
5 years agoarm: dts: Add all the imx6[q|qp|dl] sabre[auto|sd] u-boot dts[i] files
Abel Vesa [Fri, 1 Feb 2019 16:40:14 +0000 (16:40 +0000)]
arm: dts: Add all the imx6[q|qp|dl] sabre[auto|sd] u-boot dts[i] files

This allows us to keep the basic dts[i] files up-to-date with
the ones in kernel, but at the same time allowing the u-boot
to add its own properties to the existing nodes.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
Reviewed-by: Lukasz Majewski <lukma@denx.de>
5 years agoboard: mx6sabreauto: Add board_fit_config_name_match to support FIT in SPL
Abel Vesa [Fri, 1 Feb 2019 16:40:13 +0000 (16:40 +0000)]
board: mx6sabreauto: Add board_fit_config_name_match to support FIT in SPL

This matches one of the following three boards (or fails):
 - imx6q-sabreauto
 - imx6qp-sabreauto
 - imx6dl-sabreauto

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
Reviewed-by: Lukasz Majewski <lukma@denx.de>
5 years agoboard: mx6sabresd: Add board_fit_config_name_match to support FIT in SPL
Abel Vesa [Fri, 1 Feb 2019 16:40:12 +0000 (16:40 +0000)]
board: mx6sabresd: Add board_fit_config_name_match to support FIT in SPL

This matches one of the following three boards (or fails):
 - imx6q-sabresd
 - imx6qp-sabresd
 - imx6dl-sabresd

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
Reviewed-by: Lukasz Majewski <lukma@denx.de>
5 years agommc: fsl_esdhc: Fix DM_REGULATOR ifdefs for SPL builds
Abel Vesa [Fri, 1 Feb 2019 16:40:11 +0000 (16:40 +0000)]
mmc: fsl_esdhc: Fix DM_REGULATOR ifdefs for SPL builds

Since the fsl_esdhc will also be used by SPL, make the
preprocessor switches more generic to allow any kind of build.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
Reviewed-by: Lukasz Majewski <lukma@denx.de>
5 years agoconfigs: imx6sabreauto: Add DM_USB support
Abel Vesa [Fri, 1 Feb 2019 16:40:10 +0000 (16:40 +0000)]
configs: imx6sabreauto: Add DM_USB support

Add the DM support for USB. For that, DM_REGULATOR is needed.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agoconfigs: imx6sabreauto: Add DM_MMC support
Abel Vesa [Fri, 1 Feb 2019 16:40:09 +0000 (16:40 +0000)]
configs: imx6sabreauto: Add DM_MMC support

Add DM_MMC config to imx6sabreauto defconfig.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
5 years agousb: ehci-mx6: Make regulator DM_REGULATOR dependent
Abel Vesa [Fri, 1 Feb 2019 16:40:08 +0000 (16:40 +0000)]
usb: ehci-mx6: Make regulator DM_REGULATOR dependent

Do the regulator related work only if the build has the DM_REGULATOR.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
Reviewed-by: Lukasz Majewski <lukma@denx.de>
5 years agousb: Rename SPL_USB_SUPPORT to SPL_USB_STORAGE
Abel Vesa [Fri, 1 Feb 2019 16:40:07 +0000 (16:40 +0000)]
usb: Rename SPL_USB_SUPPORT to SPL_USB_STORAGE

Since there is the SPL_USB_HOST_SUPPORT for enabling USB support in SPL,
makes more sense to rename the SPL_USB_SUPPORT as SPL_USB_STORAGE.
Everything that is not part of the usb storage support in SPL is now
build under SPL_USB_HOST_SUPPORT.

Signed-off-by: Abel Vesa <abel.vesa@nxp.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Fabio Estevam <festevam@gmail.com>
Reviewed-by: Lukasz Majewski <lukma@denx.de>
5 years agovideo: bmp: Add support for 24bpp BMP files on 16bpp displays
Stefan Roese [Wed, 30 Jan 2019 07:54:12 +0000 (08:54 +0100)]
video: bmp: Add support for 24bpp BMP files on 16bpp displays

This patch adds support to load 24bpp BMP files on 16bpp displays. This
will be used by the theadorable board. The "old" bmp command did support
this operartion mode and to not break compatibility with the move to
DM_VIDEO, we need to add this support to the "new" bmp code.

Signed-off-by: Stefan Roese <sr@denx.de>
Reviewed-by: Anatolij Gustschin <agust@denx.de>
Acked-by: Anatolij Gustschin <agust@denx.de>
5 years agosunxi: display: Implement fallback to ddc probe when hpd fails
Priit Laes [Wed, 19 Dec 2018 13:06:09 +0000 (15:06 +0200)]
sunxi: display: Implement fallback to ddc probe when hpd fails

There are HDMI displays where hpd pin is not connected, thus
we cannot get it to work unless we specifically set the resolution.

Rework the display probing, so hotplug detect failure causes
fallback to probing ddc for EDID data.

Signed-off-by: Priit Laes <priit.laes@paf.com>
5 years agosunxi: display: Move DDC PLL setup to HDMI init
Priit Laes [Wed, 19 Dec 2018 13:06:08 +0000 (15:06 +0200)]
sunxi: display: Move DDC PLL setup to HDMI init

Move PLL initialization code to single place so
we won't call it every time we query for EDID data.

Signed-off-by: Priit Laes <priit.laes@paf.com>
5 years agoarm64: zynqmp: Create fdtfile from compatible string
Michal Simek [Thu, 14 Feb 2019 12:14:30 +0000 (13:14 +0100)]
arm64: zynqmp: Create fdtfile from compatible string

distro boot expects that fdtfile name is setup for alternative DTB.
Create this file based on the first platform compatible string.
This should ensure that one rootfs can store multiple DTBs for different
boards.
Reflect structure which is used in Linux kernel. It means dtbs are
strored in xilinx folder.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Alexander Graf <agraf@suse.de>
5 years agoarm64: zynqmp: Change the spi-rx-bus-width property to x1
Venkatesh Yadav Abbarapu [Wed, 14 Nov 2018 11:50:18 +0000 (17:20 +0530)]
arm64: zynqmp: Change the spi-rx-bus-width property to x1

As per the zc1275 design x1 mode is enabled so changing the
spi-rx-bus-width property to x1.

Signed-off-by: Venkatesh Yadav Abbarapu <venkatesh.abbarapu@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
5 years agoarm64: zynqmp: Fix i2c boot warning
Shubhrajyoti Datta [Mon, 3 Sep 2018 10:16:46 +0000 (15:46 +0530)]
arm64: zynqmp: Fix i2c boot warning

Fix the below warning as the core looks for the compatible
string.

[    5.198919] i2c i2c-18: of_i2c: modalias failure on
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@19
[    5.207454] i2c i2c-18: Failed to create I2C device for
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@19
[    5.216394] i2c i2c-18: of_i2c: modalias failure on
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@30
[    5.224986] i2c i2c-18: Failed to create I2C device for
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@30
[    5.233927] i2c i2c-18: of_i2c: modalias failure on
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@35
[    5.242527] i2c i2c-18: Failed to create I2C device for
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@35
[    5.263880] i2c i2c-18: of_i2c: modalias failure on
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@36
[    5.272477] i2c i2c-18: Failed to create I2C device for
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@36
[    5.281415] i2c i2c-18: of_i2c: modalias failure on
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@51
[    5.290008] i2c i2c-18: Failed to create I2C device for
/amba/i2c@ff030000/i2c-mux@75/i2c@3/dev@51

Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
5 years agoarm64: zynqmp: Remove autodetected devices without description
Michal Simek [Wed, 13 Feb 2019 14:39:04 +0000 (15:39 +0100)]
arm64: zynqmp: Remove autodetected devices without description

It will never reach mainline that's why remove it.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
5 years agoarm64: dts: Fix various entry-method properties to reflect documentation
Amit Kucheria [Thu, 23 Aug 2018 08:53:29 +0000 (14:23 +0530)]
arm64: dts: Fix various entry-method properties to reflect documentation

The idle-states binding documentation[1] mentions that the
'entry-method' property is required on 64-bit platforms and must be
set to "psci".

Linux commit a13f18f59d26 ("Documentation: arm: Fix typo in the idle-states
bindings examples") attempted to fix this earlier but clearly more is
needed.

Linux docs:
Documentation/devicetree/bindings/arm/idle-states.txt (see
idle-states node)

Signed-off-by: Amit Kucheria <amit.kucheria@linaro.org>
Acked-by: Sudeep Holla <sudeep.holla@arm.com>
Acked-by: Li Yang <leoyang.li@nxp.com>
Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
5 years agoxilinx: dts: Remove additional empty lines
Michal Simek [Wed, 13 Feb 2019 15:39:51 +0000 (16:39 +0100)]
xilinx: dts: Remove additional empty lines

Trivial fix.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
5 years agoarm64: zynqmp: Add reset-on-timeout for all boards and modify default timeout value
Mounika Grace Akula [Tue, 9 Oct 2018 15:22:50 +0000 (20:52 +0530)]
arm64: zynqmp: Add reset-on-timeout for all boards and modify default timeout value

This patch adds reset-on-timeout to FPD WDT which will trigger an
interrupt to PMU when watchdog expiry happens and PMU takes the
necessary action. If this property is not enabled, reason will not be
known when watchdog expiry happens.
This patch also modifies the default timeout to 60 seconds. Reason is
that if u-boot enables WDT, it will set the timeout to 10 seconds and
this is not enough to boot till Linux and start the WDT application in
Linux. 60 seconds is the maximum safest value to boot till Linux and
start the WDT application.

Users need to change this timeout value to fit their needs.

Signed-off-by: Mounika Grace Akula <mounika.grace.akula@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
5 years agoARM: dts: zynq: correct and improve the model property of dt files
Luis Araneda [Thu, 12 Jul 2018 04:10:20 +0000 (00:10 -0400)]
ARM: dts: zynq: correct and improve the model property of dt files

Replace the current value of the model property by a more accurate
description of each board (which includes the manufacturer), as some
of the boards had the same value ("Xilinx Zynq")

Signed-off-by: Luis Araneda <luaraneda@gmail.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
5 years agoARM: dts: zynq: Set correct manufacturer for ZedBoard and MicroZed boards
Luis Araneda [Thu, 12 Jul 2018 04:10:19 +0000 (00:10 -0400)]
ARM: dts: zynq: Set correct manufacturer for ZedBoard and MicroZed boards

Both boards are made by Avnet, Inc. So add an additional
value to the compatible property

Signed-off-by: Luis Araneda <luaraneda@gmail.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
5 years agoARM: dts: Use mmc@ instead sdhci@
Michal Simek [Wed, 26 Sep 2018 11:36:16 +0000 (13:36 +0200)]
ARM: dts: Use mmc@ instead sdhci@

mmc name is recommended based on devicetree specification.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
5 years agonet: mv88e61xx: fix autonegotiation on ports
Tim Harvey [Mon, 4 Feb 2019 20:56:52 +0000 (12:56 -0800)]
net: mv88e61xx: fix autonegotiation on ports

phy_reset should be called before autoneg is setup

The only boards using MV88E61XX_SWITCH are:
 - alliedtelesis/SBx81LIFKW
 - alliedtelesis/SBx81LIFXCAT
 - gateworks/gw_ventana

Cc: Chris Packham <chris.packham@alliedtelesis.co.nz>
Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
5 years agodoc: imx: habv4: Remove secure_boot.txt guide
Breno Matheus Lima [Wed, 23 Jan 2019 19:30:16 +0000 (19:30 +0000)]
doc: imx: habv4: Remove secure_boot.txt guide

The secure_boot.txt guide was replaced by mx6_mx7_secure_boot.txt and
mx6_mx7_spl_secure_boot.txt documents.

Both documents covers all steps needed for SPL and non-SPL tagets,
so remove secure_boot.txt file to avoid duplicated content.

Signed-off-by: Breno Lima <breno.lima@nxp.com>
5 years agorpi: add Compute Module 3+
Jonathan Gray [Wed, 30 Jan 2019 22:24:44 +0000 (09:24 +1100)]
rpi: add Compute Module 3+

Add Raspberry Pi Compute Module 3+ to list of models, the revision code
is 0x10 according to the list on raspberrypi.org.

v2: Use the same dtb name as CM3 as CM3+ is a drop in replacement
    for CM3.

Signed-off-by: Jonathan Gray <jsg@jsg.id.au>
Reviewed-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Matthias Brugger <mbrugger@suse.com>
5 years agocmd: bmp: Make integer-to-pointer cast platform, independent
Adam Heinrich [Mon, 31 Dec 2018 11:11:08 +0000 (12:11 +0100)]
cmd: bmp: Make integer-to-pointer cast platform, independent

This patch fixes the int-to-pointer-cast warning on aarch64.

Signed-off-by: Adam Heinrich <adam@adamh.cz>
Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Matthias Brugger <mbrugger@suse.com>
5 years agodoc: imx: habv4: Move encrypted boot guide
Breno Matheus Lima [Wed, 23 Jan 2019 19:30:11 +0000 (19:30 +0000)]
doc: imx: habv4: Move encrypted boot guide

All guides are currently located at doc/imx/habv4/guides/ directory.

Move encrypted_boot.txt document to guides directory.

Signed-off-by: Breno Lima <breno.lima@nxp.com>
5 years agodoc: imx: habv4: Add Secure Boot guide for i.MX6 and i.MX7 SPL targets
Breno Matheus Lima [Wed, 23 Jan 2019 19:30:06 +0000 (19:30 +0000)]
doc: imx: habv4: Add Secure Boot guide for i.MX6 and i.MX7 SPL targets

The current U-Boot implementation includes SPL targets for
some NXP development boards:

- mx6sabreauto_defconfig
- mx6sabresd_defconfig
- mx6ul_14x14_evk_defconfig
- mx6ul_9x9_evk_defconfig

Add additional steps needed to completly secure the
bootloader image.

Signed-off-by: Breno Lima <breno.lima@nxp.com>
5 years agodoc: imx: habv4: Add Secure Boot guide for i.MX6 and i.MX7 non-SPL targets
Breno Matheus Lima [Wed, 23 Jan 2019 19:29:59 +0000 (19:29 +0000)]
doc: imx: habv4: Add Secure Boot guide for i.MX6 and i.MX7 non-SPL targets

Add HABv4 documentation for non-SPL targets covering the
following topics:

- How to sign an securely boot an u-boot-dtb.imx image.
- How to extend the root of trust for additional boot images.
- Add 3 CSF examples.
- Add IVT generation script example.

Reviewed-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Utkarsh Gupta <utkarsh.gupta@nxp.com>
Signed-off-by: Breno Lima <breno.lima@nxp.com>
5 years agodoc: imx: habv4: Add HABv4 introduction
Breno Matheus Lima [Wed, 23 Jan 2019 19:29:53 +0000 (19:29 +0000)]
doc: imx: habv4: Add HABv4 introduction

The HABv4 is supported in i.MX50, i.MX53, i.MX6, i.MX7,
series and i.MX 8M, i.MX8MM devices.

Add an introductory document containing the following topics:

- HABv4 Introduction
- HABv4 Secure Boot
- HABv4 Encrypted Boot
- HAB PKI tree generation
- HAB Fast Authentication PKI tree generation
- SRK Table and SRK Hash generation

Reviewed-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Utkarsh Gupta <utkarsh.gupta@nxp.com>
Signed-off-by: Breno Lima <breno.lima@nxp.com>
5 years agodoc: imx: habv4: Remove extra hab directory for a cleaner documentation structure
Breno Matheus Lima [Wed, 23 Jan 2019 19:29:46 +0000 (19:29 +0000)]
doc: imx: habv4: Remove extra hab directory for a cleaner documentation structure

There is no need to have an extra hab directory under doc/imx/.

Habv4 and AHAB documentation can be added directly in doc/imx/ for a
cleaner documentation structure.

Signed-off-by: Breno Lima <breno.lima@nxp.com>
5 years agoARM: dts: imx6ul-lite*: add DTS files for liteSOM and liteboard
Marcin Niestroj [Sat, 19 Jan 2019 16:06:45 +0000 (17:06 +0100)]
ARM: dts: imx6ul-lite*: add DTS files for liteSOM and liteboard

Import liteSOM and liteboard dts files from Linux v4.20. They will
be used after transition to driver model and device-tree based boot.

Signed-off-by: Marcin Niestroj <m.niestroj@grinn-global.com>
5 years agoMTD: nand: mxs_nand: Allow driver to auto setup ECC in SPL
Adam Ford [Thu, 17 Jan 2019 13:16:39 +0000 (07:16 -0600)]
MTD: nand: mxs_nand: Allow driver to auto setup ECC in SPL

The initialization of the NAND in SPL hard-coded ecc.bytes,
ecc.size, and ecc.strength which may work for some NAND parts,
but it not appropriate for others.  With the pending patch
"mxs_nand: Fix BCH read timeout error on boards requiring ECC"
the driver can auto configure the ECC when these entries are
blank.  This patch has been tested in NAND flash with oob 64
and oob 128.

Signed-off-by: Adam Ford <aford173@gmail.com>
Tested-by: Jörg Krause <joerg.krause@embedded.rocks>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Tested-by: Tim Harvey <tharvey@gateworks.com>
5 years agonet: dm: fec: Fix regulator enable when using DM_REGULATOR
Adam Ford [Tue, 15 Jan 2019 17:26:48 +0000 (11:26 -0600)]
net: dm: fec: Fix regulator enable when using DM_REGULATOR

When DM_REGULATOR is enabled, the driver attempts to call
regulator_autoset() which expects the regulators to be on at boot
and/or always on and fails if they are not true.
For a more generic approach, this patch just calls
regulator_set_enable() which shouldn't have such restrictions.

Fixes: ad8c43cbcafb ("net: dm: fec: Support the phy-supply
binding")

Signed-off-by: Adam Ford <aford173@gmail.com>
Tested-by: Martin Fuzzey <martin.fuzzey@flowbird.group>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
5 years agoARM: imx6q_logic: Correct phy fixup for broken ethernet
Adam Ford [Sat, 12 Jan 2019 23:32:00 +0000 (17:32 -0600)]
ARM: imx6q_logic: Correct phy fixup for broken ethernet

The Ethernet has been broken for some time.  This patch unifies
this board with a few others that use a similar approach to
enabling phy.  This fixes ar8031 Ethernet controller so it works.

Signed-off-by: Adam Ford <aford173@gmail.com>
5 years agoARM: imx6q_logic: Enable SPL Booting from NAND
Adam Ford [Sat, 12 Jan 2019 23:24:52 +0000 (17:24 -0600)]
ARM: imx6q_logic: Enable SPL Booting from NAND

This patch fixes a few values that were incorrect, and this
now lets SPL boot from NAND.

Signed-off-by: Adam Ford <aford173@gmail.com>
5 years agoMTD: NAND: mxs_nand_init_dma: Make mxs_nand_init_dma static
Adam Ford [Sat, 12 Jan 2019 12:25:48 +0000 (06:25 -0600)]
MTD: NAND: mxs_nand_init_dma: Make mxs_nand_init_dma static

mxs_nand_init_dma is only referenced from mxs_nand.c.  It's not
referenced in any headers or outside code, so this patch
defines it as static.

Signed-off-by: Adam Ford <aford173@gmail.com>
5 years agoMTD: mxs_nand: Fix BCH read timeout error on boards requiring ECC
Adam Ford [Thu, 3 Jan 2019 02:36:52 +0000 (20:36 -0600)]
MTD: mxs_nand: Fix BCH read timeout error on boards requiring ECC

The LogicPD board uses a Micron Flash with ECC.  To boot this from
SPL, the ECC needs to be correctly configured or the BCH engine
times out.

Signed-off-by: Adam Ford <aford173@gmail.com>
Acked-by: Stefan Agner <stefan.agner@toradex.com>
Tested-by: Jörg Krause <joerg.krause@embedded.rocks>
Acked-by: Tim Harvey <tharvey@gateworks.com>
Tested-by: Tim Harvey <tharvey@gateworks.com>
5 years agoddr: vybrid: Add calibration code to memory controler's (DDRMC) setup code
Lukasz Majewski [Wed, 5 Dec 2018 16:04:03 +0000 (17:04 +0100)]
ddr: vybrid: Add calibration code to memory controler's (DDRMC) setup code

This patch extends the vf610 DDR memory controller code to support SW
leveling.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
Reviewed-by: Stefan Agner <stefan.agner@toradex.com>
5 years agoddr: vybrid: Provide code to perform on-boot calibration
Lukasz Majewski [Wed, 5 Dec 2018 16:04:02 +0000 (17:04 +0100)]
ddr: vybrid: Provide code to perform on-boot calibration

This patch provides the code to calibrate the DDR's
DQS to DQ signals (RDLVL).

It is based on:
VFxxx Controller Reference Manual, Rev. 0, 10/2016, page 1600
10.1.6.16.4.1 "Software Read Leveling in MC Evaluation Mode"

and NXP's community thread:
"Vybrid: About DDR leveling feature on DDRMC."
https://community.nxp.com/thread/395323

Signed-off-by: Lukasz Majewski <lukma@denx.de>
5 years agoddr: vybrid: Add DDRMC calibration related registers (DQS to DQ)
Lukasz Majewski [Wed, 5 Dec 2018 16:04:01 +0000 (17:04 +0100)]
ddr: vybrid: Add DDRMC calibration related registers (DQS to DQ)

This commit provides extra defines needed for DDR memory controller
calibration (read leveling performing).

Signed-off-by: Lukasz Majewski <lukma@denx.de>
Reviewed-by: Stefan Agner <stefan.agner@toradex.com>
5 years agoMerge branch 'master' of git://git.denx.de/u-boot-sunxi
Tom Rini [Fri, 15 Feb 2019 01:14:51 +0000 (20:14 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-sunxi

- MMC CD pin fix on Orangepi Zero plus
- SPI boot for  Olinuxino Lime2-eMMC boards
- Change in dram frequnecy for tbs_a711

5 years agoarm64: zynqmp: Remove board config files
Michal Simek [Wed, 13 Feb 2019 12:33:32 +0000 (13:33 +0100)]
arm64: zynqmp: Remove board config files

All options have been moved to Kconfig and there is no need to have
board header files. Mini configurations require them that's why they are
still there.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>