oweals/u-boot.git
4 years agortc: s35392a: encode command correctly
Ian Ray [Tue, 14 Jan 2020 16:18:20 +0000 (16:18 +0000)]
rtc: s35392a: encode command correctly

The 3-bit "command", or register, is encoded within the device address.
Configure the device accordingly, and pass command in DM I2C read/write
calls correctly.

Signed-off-by: Ian Ray <ian.ray@ge.com>
Signed-off-by: Robert Beckett <bob.beckett@collabora.com>
4 years agocmd: sata: Add block unbind device function
Peng Ma [Wed, 4 Dec 2019 10:36:47 +0000 (10:36 +0000)]
cmd: sata: Add block unbind device function

If we didn't unbind the sata from block device, the same devices would
be added after sata remove,
This patch is to resolve this issue as below:

=> sata info
SATA#0:
(3.0 Gbps)
SATA#1:
(3.0 Gbps)
Device 0: Model: INTEL SSDSA2BW300G3D Firm: 4PC10362 Ser#: BTPR247005PY30
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 286168.1 MB = 279.4 GB (586072368 x 512)
Device 1: Model: INTEL SSDSA2BW300G3D Firm: 4PC10362 Ser#: BTPR247005VX30
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 286168.1 MB = 279.4 GB (586072368 x 512)
=> sata stop
=> sata info
SATA#0:
(3.0 Gbps)
SATA#1:
(3.0 Gbps)
Device 0: Model: INTEL SSDSA2BW300G3D Firm: 4PC10362 Ser#: BTPR247005PY300
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 286168.1 MB = 279.4 GB (586072368 x 512)
Device 1: Model: INTEL SSDSA2BW300G3D Firm: 4PC10362 Ser#: BTPR247005VX300
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 286168.1 MB = 279.4 GB (586072368 x 512)
Device 2: Model: INTEL SSDSA2BW300G3D Firm: 4PC10362 Ser#: BTPR247005PY300
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 286168.1 MB = 279.4 GB (586072368 x 512)
Device 3: Model: INTEL SSDSA2BW300G3D Firm: 4PC10362 Ser#: BTPR247005VX300
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 286168.1 MB = 279.4 GB (586072368 x 512)

Signed-off-by: Peng Ma <peng.ma@nxp.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
4 years agotbs2910: add custom CONFIG_OF_REMOVE_PROPS list to defconfig
Anatolij Gustschin [Sun, 12 Jan 2020 14:57:43 +0000 (15:57 +0100)]
tbs2910: add custom CONFIG_OF_REMOVE_PROPS list to defconfig

This shrinks the image size: all -3840.0 text -3840.0

Signed-off-by: Anatolij Gustschin <agust@denx.de>
Acked-by: Soeren Moch <smoch@web.de>
4 years agodts: add property removal option CONFIG_OF_REMOVE_PROPS
Anatolij Gustschin [Sun, 12 Jan 2020 14:57:42 +0000 (15:57 +0100)]
dts: add property removal option CONFIG_OF_REMOVE_PROPS

This can be used for device tree size reduction similar as
CONFIG_OF_SPL_REMOVE_PROPS option. Some boards must pass the
built-in DTB unchanged to the kernel, thus we may not cut it
down unconditionally. Therefore enable the property removal
list option only if CONFIG_OF_DTB_PROPS_REMOVE is selected.

Signed-off-by: Anatolij Gustschin <agust@denx.de>
4 years agoMerge tag 'u-boot-clk-26Jan2020' of https://gitlab.denx.de/u-boot/custodians/u-boot-clk
Tom Rini [Mon, 27 Jan 2020 12:19:26 +0000 (07:19 -0500)]
Merge tag 'u-boot-clk-26Jan2020' of https://gitlab.denx.de/u-boot/custodians/u-boot-clk

- Various clock fixes and enhancements

4 years agoclock_imx8mq: Make frac_pll_init() static
Pedro Jardim [Thu, 23 Jan 2020 13:21:53 +0000 (10:21 -0300)]
clock_imx8mq: Make frac_pll_init() static

Since frac_pll_init() is only used in this file, change it to 'static'.

This fixes the following sparse warning:

arch/arm/mach-imx/imx8m/clock_imx8mq.c:662:5: warning: no previous
prototype for ‘frac_pll_init’ [-Wmissing-prototypes]

Signed-off-by: Pedro Jardim <jardim.c.pedro@gmail.com>
4 years agoclock_imx8mq: Remove the function sscg_pll_init()
Pedro Jardim [Thu, 23 Jan 2020 13:21:05 +0000 (10:21 -0300)]
clock_imx8mq: Remove the function sscg_pll_init()

Function sscg_pll_init() is not used anywhere, so it can simply be deleted.
This was found because of the following sparse
warning:

arch/arm/mach-imx/imx8m/clock_imx8mq.c:702:5: warning: no previous prototype for ‘sscg_pll_init’ [-Wmissing-prototypes]
 int sscg_pll_init(u32 pll)
     ^~~~~~~~~~~~~

Signed-off-by: Pedro Jardim <jardim.c.pedro@gmail.com>
4 years agoclock_imx8mq: Make do_imx8m_showclocks() static
Pedro Jardim [Thu, 23 Jan 2020 13:20:51 +0000 (10:20 -0300)]
clock_imx8mq: Make do_imx8m_showclocks() static

Since do_imx8m_showclocks() is only used inside this file, make it 'static'.

This fixes the following sparse warning:

arch/arm/mach-imx/imx8m/clock_imx8mq.c:836:5: warning: no previous prototype
 for ‘do_imx8m_showclocks’ [-Wmissing-prototypes]
 int do_imx8m_showclocks(cmd_tbl_t *cmdtp, int flag, int argc,
     ^~~~~~~~~~~~~~~~~~~

Signed-off-by: Pedro Jardim <jardim.c.pedro@gmail.com>
4 years agoclock_imx8mq: Delete not used init_usb_clk()
Pedro Jardim [Thu, 23 Jan 2020 13:20:14 +0000 (10:20 -0300)]
clock_imx8mq: Delete not used init_usb_clk()

Function init_usb_clk() is not used anywhere, so it can simply be deleted.
This was detected by the following sparse warning:

arch/arm/mach-imx/imx8m/clock_imx8mq.c:377:6: warning: no previous prototype
 for ‘init_usb_clk’ [-Wmissing-prototypes]
 void init_usb_clk(void)
      ^~~~~~~~~~~~

Signed-off-by: Pedro Jardim <jardim.c.pedro@gmail.com>
4 years agoclk: imx: pllv3: fix potential 'divide by zero' in av_set_rate()
Giulio Benetti [Fri, 17 Jan 2020 12:06:42 +0000 (13:06 +0100)]
clk: imx: pllv3: fix potential 'divide by zero' in av_set_rate()

Guard 'parent_rate==0' to prevent 'divide by zero' issue in
clk_pplv3_av_set_rate(). If it is 0, let's return with -EINVAL.

Signed-off-by: Giulio Benetti <giulio.benetti@benettiengineering.com>
4 years agoclk: imx: pllv3: fix potential 'divide by zero' in av_get_rate()
Giulio Benetti [Fri, 17 Jan 2020 12:06:41 +0000 (13:06 +0100)]
clk: imx: pllv3: fix potential 'divide by zero' in av_get_rate()

Guard 'mfd==0' to prevent 'divide by zero' issue in
clk_pplv3_av_get_rate(). If it is 0, let's return with EIO since mfd
should never be 0 at all.

Signed-off-by: Giulio Benetti <giulio.benetti@benettiengineering.com>
4 years agoclk: imx: pllv3: fix potential 'divide by zero' in sys_get_rate()
Giulio Benetti [Fri, 17 Jan 2020 12:06:40 +0000 (13:06 +0100)]
clk: imx: pllv3: fix potential 'divide by zero' in sys_get_rate()

Guard 'parent_rate==0' to prevent 'divide by zero' issue in
clk_pplv3_sys_get_rate(). If it is 0, let's return with -EINVAL.

Signed-off-by: Giulio Benetti <giulio.benetti@benettiengineering.com>
4 years agocommon: fix regression on block cache init
Angelo Durgehello [Sun, 26 Jan 2020 18:31:22 +0000 (19:31 +0100)]
common: fix regression on block cache init

m68k needs block cache list initialized after relocation.
Other architectures must not be involved.

Fixing regression related to:

commit 1526bcce0f7285087621e16e6720636d01839da8
("common: add blkcache init")

Signed-off-by: Angelo Durgehello <angelo.dureghello@timesys.com>
4 years agoarm: mvebu: fix A38x breakage from commit bb872dd930cc
Joel Johnson [Sun, 26 Jan 2020 16:48:58 +0000 (09:48 -0700)]
arm: mvebu: fix A38x breakage from commit bb872dd930cc

This function parameter usage of load_addr was incorrectly caught in
the clarifying renames of commit bb872dd930cc, which results in boot
failures on Marvell A38x.

Signed-off-by: Joel Johnson <mrjoel@lixil.net>
Patch-to: Simon Glass <sjg@chromium.org>

4 years agoMerge branch 'master' of https://gitlab.denx.de/u-boot/custodians/u-boot-sunxi
Tom Rini [Sun, 26 Jan 2020 17:05:11 +0000 (12:05 -0500)]
Merge branch 'master' of https://gitlab.denx.de/u-boot/custodians/u-boot-sunxi

- Libre Computer ALL-H3-IT/ALL-H5-CC board (Chen-Yu Tsai)
- Allwinner R40 Ethernet, usb phy enablement (Andre Przywara)
- Sunxi auto load from 128KB MMC offset (Andre Przywara)
- Orange Pi Win Ethernet phy enablement (Jernej Skrabec)

4 years agoconfigs: Orange Pi Win: enable ethernet phy
Jernej Skrabec [Sun, 26 Jan 2020 12:38:34 +0000 (13:38 +0100)]
configs: Orange Pi Win: enable ethernet phy

Orange Pi Win has gigabit ethernet port, but default U-Boot
configuration for that board enabled ethernet driver but
didn't enable realtek phy.

Fix that.

Signed-off-by: Jernej Skrabec <jernej.skrabec@siol.net>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agosunxi: Automate loading from 128KB MMC offset
Andre Przywara [Fri, 10 Jan 2020 01:47:32 +0000 (01:47 +0000)]
sunxi: Automate loading from 128KB MMC offset

Since commit 067e0b9684d4 ("sunxi: Allow booting from 128KB SD/eMMC offset")
we support having the SPL loaded from either the traditional 8KB SD
card/eMMC offset, or from the alternative location at 128KB. However the
sector to find the U-Boot image was still hard-coded at compile time,
and had to be adjusted for one of the two choices.

Since we can actually override the function to return the sector offset,
we can just check the boot source byte there to select the proper offset
based on from where the SPL was loaded.

This allows the very same binary image to be loaded from either 128KB or
8KB, with the U-Boot proper image always being located just behind the SPL.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Acked-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agosunxi: SPL: Factor out sunxi_get_boot_source()
Andre Przywara [Fri, 10 Jan 2020 01:47:31 +0000 (01:47 +0000)]
sunxi: SPL: Factor out sunxi_get_boot_source()

The Boot ROM write some boot source ID (SD card, eMMC, SPI, ...) into
a certain location in SRAM, so the SPL can easily determine where to
load U-Boot proper from.
Factor out reading this value, as it will come in handy again shortly.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Acked-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agoclk: Fix error checking of dev_read_addr_ptr
Sean Anderson [Wed, 25 Dec 2019 04:57:47 +0000 (23:57 -0500)]
clk: Fix error checking of dev_read_addr_ptr

dev_read_addr_ptr returns NULL on error, not FDT_ADDR_T_NONE.

Signed-off-by: Sean Anderson <seanga2@gmail.com>
4 years agoclk: Include missing headers for linux/clk-provider.h
Sean Anderson [Wed, 25 Dec 2019 04:56:22 +0000 (23:56 -0500)]
clk: Include missing headers for linux/clk-provider.h

This header was missing a couple of include dependencies when included on its
own.

Signed-off-by: Sean Anderson <seanga2@gmail.com>
4 years agoclk: uclass: clk_get_by_name() must not be available if CONFIG_OF_PLATDATA is enabled
Giulio Benetti [Thu, 12 Dec 2019 22:53:19 +0000 (23:53 +0100)]
clk: uclass: clk_get_by_name() must not be available if CONFIG_OF_PLATDATA is enabled

clk_get_by_name() requires clk_get_by_id() that is not available if
CONFIG_OF_PLATDATA is defined, so move clk_get_by_name() into #else
condition of #if CONFIG_IS_ENABLED(OF_PLATDATA).

Signed-off-by: Giulio Benetti <giulio.benetti@benettiengineering.com>
4 years agoclk: show more error info when uclass_get_device_by_name
Peng Fan [Tue, 22 Oct 2019 03:31:08 +0000 (03:31 +0000)]
clk: show more error info when uclass_get_device_by_name

It will ease debug when uclass_get_device_by_name failed with
more error info printed out.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
4 years agoclk: mediatek: use unsigned type for returning the clk rate
Fabien Parent [Thu, 17 Oct 2019 19:02:05 +0000 (21:02 +0200)]
clk: mediatek: use unsigned type for returning the clk rate

mtk_clk_find_parent_rate is calling clk_get_rate to know the rate
of a parent clock. clk_get_rate returns a ulong, while
mtk_clk_find_parent_rate returns an int. This implicit cast creates
an issue for clock rates big enough to need the full 32 bits to
store its data. When that happen the clk rate will become incorrect
because of the implicit cast between ulong -> int -> ulong.

This commit change the return type of mtk_clk_find_parent_rate to
ulong.

Signed-off-by: Fabien Parent <fparent@baylibre.com>
4 years agoMerge https://gitlab.denx.de/u-boot/custodians/u-boot-fsl-qoriq
Tom Rini [Sat, 25 Jan 2020 17:20:51 +0000 (12:20 -0500)]
Merge https://gitlab.denx.de/u-boot/custodians/u-boot-fsl-qoriq

Updates and fixes for ls1028a, lx2160a, ls1012a, ls1021a, ls2080a,
ls1088a platforms:
- lx2-rev2 pcie support, enetc related updates, layerscape-pcie fixes

4 years agoMerge branch '2020-01-24-master-imports'
Tom Rini [Sat, 25 Jan 2020 17:04:59 +0000 (12:04 -0500)]
Merge branch '2020-01-24-master-imports'

- Enable fastboot on some MediaTek platforms
- DMA enchancements
- Assorted bugfixes

4 years agomtd: add prototypes for weak function
Patrick Delaunay [Fri, 24 Jan 2020 12:45:56 +0000 (13:45 +0100)]
mtd: add prototypes for weak function

This patch adds a prototype for the weak function
board_mtdparts_default().

It solves one warning when compiling with W=1 on stm32mp1 board:

board/st/stm32mp1/stm32mp1.c:
     warning: no previous prototype for 'board_mtdparts_default'
              [-Wmissing-prototypes]
     void board_mtdparts_default(const char **mtdids,
                                 const char **mtdparts)
          ^~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
4 years agocommon: blk: fix comment about blkcache_read return value
Eric Nelson [Wed, 22 Jan 2020 23:59:55 +0000 (16:59 -0700)]
common: blk: fix comment about blkcache_read return value

The blkcache_read() routine returns 1 (true) to indicate that a block was
found in the cache and returned, or 0 if not.

Signed-off-by: Eric Nelson <eric@nelint.com>
4 years agomeerkat96: fix typo in MAINTAINERS email address
Shawn Guo [Fri, 24 Jan 2020 04:59:42 +0000 (12:59 +0800)]
meerkat96: fix typo in MAINTAINERS email address

There is a typo in meerkat96 MAINTAINERS email address.  Fix it.

Reported-by: Carl Gelfand <carl@novtech.com>
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
4 years agogenboardscfg.py: drop python version comment
Baruch Siach [Wed, 22 Jan 2020 12:54:24 +0000 (14:54 +0200)]
genboardscfg.py: drop python version comment

genboardscfg.py requires python 3.x since commit 3bc14098d8fb
("genboardscfg.py: Convert to Python 3").

Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Acked-by: Masahiro Yamada <yamada.masahiro@socionext.com>
4 years agocommon: add blkcache init
Angelo Durgehello [Tue, 21 Jan 2020 09:37:27 +0000 (10:37 +0100)]
common: add blkcache init

On m68k, block_cache list is relocated, but next and prev list
pointers are not adjusted to the relocated struct list_head address,
so the first iteration over the block_cache list hangs.

This patch initializes the block_cache list after relocation.

Signed-off-by: Angelo Durgehello <angelo.dureghello@timesys.com>
Reviewed-by: Eric Nelson <eric@nelint.com>
4 years agonet: macb: Drop local cache flush
Vignesh Raghavendra [Thu, 16 Jan 2020 08:53:48 +0000 (14:23 +0530)]
net: macb: Drop local cache flush

Now that arch specific dma mapping APIs take care of cache
flush/invalidate, drop local cache flush operation.
While at that fix dma_unmap_single() call to match new prototype

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
4 years agomtd: denali: Drop custom dma mapping functions
Vignesh Raghavendra [Thu, 16 Jan 2020 08:53:47 +0000 (14:23 +0530)]
mtd: denali: Drop custom dma mapping functions

Drop local dma_map_single() and dma_unmap_single() and use arch specific
common implementation

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
Acked-by: Masahiro Yamada <yamada.masahiro@socionext.com>
4 years agommc: tmio-common: Drop custom dma mapping functions
Vignesh Raghavendra [Thu, 16 Jan 2020 08:53:46 +0000 (14:23 +0530)]
mmc: tmio-common: Drop custom dma mapping functions

Drop local dma_map_single() and dma_unmap_single() and use arch specific
common implementation

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
Acked-by: Masahiro Yamada <yamada.masahiro@socionext.com>
4 years agoasm: dma-mapping.h: Fix dma mapping functions
Vignesh Raghavendra [Thu, 16 Jan 2020 08:53:45 +0000 (14:23 +0530)]
asm: dma-mapping.h: Fix dma mapping functions

Subsystems such as USB expect dma_map_single() and dma_unmap_single() to
do dcache flush/invalidate operations as required. For example, see
see drivers/usb/gadget/udc/udc-core.c::usb_gadget_map_request().
Currently drivers do this locally, (see drivers/usb/dwc3/ep0.c,
drivers/mtd/nand/raw/denali.c etc..)
Update arch specific dma_map_single() and dma_unmap_single() APIs to do
cache flush/invalidate  operations, so that drivers need not implement
them locally.

Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
Reviewed-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Rick Chen <rick@andestech.com>
4 years agofastboot: mt85xx: add command to flash/erase emmc hwpart
mingming lee [Thu, 16 Jan 2020 08:11:42 +0000 (16:11 +0800)]
fastboot: mt85xx: add command to flash/erase emmc hwpart

This patch includes the following:
1. Add fastboot command to erase the whole EMMC_USER
2. Add fastboot command to flash image at EMMC_BOOT1
3. Add fastboot command to erase the whole EMMC_BOOT1
4. Enale CONFIG_FASTBOOT_MMC_BOOT1_SUPPORT for mt8518

Signed-off-by: mingming lee <mingming.lee@mediatek.com>
4 years agoconfigs: mt8518: Enable fastboot related configs
mingming lee [Thu, 16 Jan 2020 08:11:41 +0000 (16:11 +0800)]
configs: mt8518: Enable fastboot related configs

Enable EFI module.
Enable fastboot.

Signed-off-by: mingming lee <mingming.lee@mediatek.com>
4 years agoconfigs: mt8518: enable usb gadget driver
mingming lee [Thu, 16 Jan 2020 08:11:40 +0000 (16:11 +0800)]
configs: mt8518: enable usb gadget driver

Enable board_late_init and usb gadget for mt8518

Signed-off-by: mingming lee <mingming.lee@mediatek.com>
4 years agoconfigs: mt8518: set global variables for fastboot
mingming lee [Thu, 16 Jan 2020 08:11:39 +0000 (16:11 +0800)]
configs: mt8518: set global variables for fastboot

set common fastboot variables for mt8518

Signed-off-by: mingming lee <mingming.lee@mediatek.com>
4 years agoARM: Mediatek: Add board_late_init to init usb gadget driver
mingming lee [Thu, 16 Jan 2020 08:11:38 +0000 (16:11 +0800)]
ARM: Mediatek: Add board_late_init to init usb gadget driver

Add board_late_init function to init usb gadget driver for mt8518

Signed-off-by: mingming lee <mingming.lee@mediatek.com>
4 years agousb: musb-new: mt85xx: add musb-new gadget driver.
mingming lee [Thu, 16 Jan 2020 08:11:37 +0000 (16:11 +0800)]
usb: musb-new: mt85xx: add musb-new gadget driver.

Using musb-new structure for mt85xx gadget driver.
Add gadget driver dts for mt8518 SoCs.

Signed-off-by: mingming lee <mingming.lee@mediatek.com>
4 years agocrypto: make mod_exp_sw() static
Heinrich Schuchardt [Sun, 19 Jan 2020 18:48:04 +0000 (19:48 +0100)]
crypto: make mod_exp_sw() static

Function mod_exp_sw() is only used via the operators of the uclass.
It is not defined in any include.

Make mod_exp_sw() static.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
4 years agolib: Kconfig dependencies for pseudo-random library
Heinrich Schuchardt [Sun, 19 Jan 2020 18:28:12 +0000 (19:28 +0100)]
lib: Kconfig dependencies for pseudo-random library

drivers/rng/sandbox_rng.c requires rand() to be defined but configuration
option CONFIG_CONFIG_LIB_RAND selected in drivers/rng/Kconfig does not
exist.

test/lib/test_aes.c requires rand() to be defined.

Fix the selection criteria for choice "Pseudo-random library support type".

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
4 years agolib: rsa: consider CONFIG_SPL_RSA
Heinrich Schuchardt [Sun, 19 Jan 2020 08:26:22 +0000 (09:26 +0100)]
lib: rsa: consider CONFIG_SPL_RSA

CONFIG_SPL_RSA is meant to control if lib/rsa/* is used for SPL. Adjust
lib/Makefile to consider this setting.

This was correctly setup with commit 51c14cd128f4 ("verified-boot: Minimal
support for booting U-Boot proper from SPL") and got lost with commit
089df18bfe9d ("lib: move hash CONFIG options to Kconfig").

Fixes: 089df18bfe9d ("lib: move hash CONFIG options to Kconfig")
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
4 years agosunxi: Add Libre Computer ALL-H5-CC H5 board
Chen-Yu Tsai [Sun, 12 Jan 2020 15:36:15 +0000 (23:36 +0800)]
sunxi: Add Libre Computer ALL-H5-CC H5 board

The Libre Computer ALL-H5-CC board is an upgraded version of the
ALL-H3-CC. Changes include:

  - Gigabit Ethernet via external RTL8211E Ethernet PHY
  - 16 MiB SPI NOR flash memory
  - PoE tap header
  - Line out jack removed

Only H5 variant test samples were made available, and the vendor is not
certain whether other SoC variants would be made or not. Furthermore the
board is a minor upgrade compared to the ALL-H3-CC. Thus the device tree
simply includes the one for the ALL-H3-CC, and adds the changes on top.

The device tree was synced over from the Linux kernel, along with other
H3/H5 changes, in a previous patch. Thus only the defconfig and an entry
to the MAINTAINERS file is added.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
[jagan: drop CONFIG_SYS_SPI_U_BOOT_OFFS]
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agosunxi: Add Libre Computer ALL-H3-IT H5 board
Chen-Yu Tsai [Sun, 12 Jan 2020 15:36:14 +0000 (23:36 +0800)]
sunxi: Add Libre Computer ALL-H3-IT H5 board

The Libre Computer ALL-H3-IT board is a small single board computer that
is roughly the same size as the Raspberry Pi Zero, or around 20% smaller
than a credit card.

The board features:

  - H2, H3, or H5 SoC from Allwinner
  - 2 DDR3 DRAM chips
  - Realtek RTL8821CU based WiFi module
  - 128 Mbit SPI-NOR flash
  - micro-SD card slot
  - micro HDMI video output
  - FPC connector for camera sensor module
  - generic Raspberri-Pi style 40 pin GPIO header
  - additional pin headers for extra USB host ports, ananlog audio and
    IR receiver

Only H5 variant test samples were made available, but the vendor does
have plans to include at least an H3 variant. Thus the device tree is
split much like the ALL-H3-CC, with a common dtsi file for the board
design, and separate dts files including the common board file and the
SoC dtsi file. The other variants will be added as they are made
available.

The device tree was synced over from the Linux kernel, along with other
H3/H5 changes, in a previous patch. Thus only the defconfig and an entry
to the MAINTAINERS file is added.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
[jagan: drop CONFIG_SYS_SPI_U_BOOT_OFFS]
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agosunxi: move CONFIG_SYS_SPI_U_BOOT_OFFS out of defconfig
Andre Przywara [Mon, 6 Jan 2020 01:29:10 +0000 (01:29 +0000)]
sunxi: move CONFIG_SYS_SPI_U_BOOT_OFFS out of defconfig

For Allwinner SoCs the CONFIG_SYS_SPI_U_BOOT_OFFS value is not really a
board choice: The boot ROM only loads the SPL from offset 0 of the SPI
NOR flash, and loads at most 32KB. This is a similar situation as on MMC,
so consequently we create our "joint" image (SPL + U-Boot proper) with
that 32KB offset during the build.

So define the value of this symbol to be 32KB by default for every
Allwinner SoC. This removes the definition of this symbol from the
_defconfig files, and avoids every board to define this over and over
again.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agosunxi: defconfig: R40 boards: enable USB
Andre Przywara [Wed, 1 Jan 2020 23:44:49 +0000 (23:44 +0000)]
sunxi: defconfig: R40 boards: enable USB

Now that the USB PHY on the Allwinner R40 SoC is supported, enable USB
support for the two R40 boards U-Boot supports.
For this we need to add the GPIO pin that powers the USB port(s), also
enable the usual suspects (OHCI/EHCI support).

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agophy: sun4i-usb: Add Allwinner R40 support
Andre Przywara [Wed, 1 Jan 2020 23:44:48 +0000 (23:44 +0000)]
phy: sun4i-usb: Add Allwinner R40 support

Since every Allwinner USB PHY seems to be slightly different from each
other, we need to add the compatible string and the respective data
structure to make it work on the R40/V40 SoC.
Nothing spectacular this time, just one less USB controller than the H3.
Copied from the Linux kernel.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agosunxi: defconfig: Bananapi M2 Berry: enable Ethernet
Andre Przywara [Wed, 1 Jan 2020 23:44:47 +0000 (23:44 +0000)]
sunxi: defconfig: Bananapi M2 Berry: enable Ethernet

The M2 Berry features the normal Gigabit PHY connected to the SoC's MAC,
so enable the sun8i-emac driver to support Ethernet on the board.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agosunxi: dts: R40: Update Bananapi M2 Berry .dts
Andre Przywara [Wed, 1 Jan 2020 23:44:46 +0000 (23:44 +0000)]
sunxi: dts: R40: Update Bananapi M2 Berry .dts

Update the .dts file from the kernel, which carries much more nodes,
some of them we need to enable USB and Ethernet support for the board.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agosunxi: H3/H5 Sync DT files from upstream Linux kernel as of next-20200108
Chen-Yu Tsai [Sun, 12 Jan 2020 15:36:13 +0000 (23:36 +0800)]
sunxi: H3/H5 Sync DT files from upstream Linux kernel as of next-20200108

Sync the device tree files and device tree header files from upstream
Linux kernel, as of 2020-01-08. The commit synced to in the sunxi repo

    98d25b0b266d Merge branch 'sunxi/dt-for-5.6' into sunxi/for-next

which is also part of next-20200108.

Changes brought in include:

  - cleanup of pinmux node names
  - addition of Security ID, MBUS, CSI, crypto engine, video codec,
    pmu, and thermal sensor device nodes for both SoCs
  - addition of deinterlacing engine device node on H3
  - cleanup of RTC device node and addition of its clocks
  - various board cleanups and improvements
    - removal of pinmux node for GPIO lines
    - cpufreq / DVFS
    - HDMI output
    - UART-based Bluetooth
    - audio codec
    - USB ports
  - new boards

Most of the changes don't concern U-boot.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
4 years agocommon: Update comment to show progress
Simon Glass [Sat, 28 Dec 2019 17:45:12 +0000 (10:45 -0700)]
common: Update comment to show progress

This file doesn't include any declarations anymore but it does include
other headers. Update the header comment to mention this.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Collect all the header files together
Simon Glass [Sat, 28 Dec 2019 17:45:11 +0000 (10:45 -0700)]
common: Collect all the header files together

There are many header files included here. Put them all together since the
blank lines are not useful.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move and rename CONFIG_SYS_SUPPORT_64BIT_DATA
Simon Glass [Sat, 28 Dec 2019 17:45:10 +0000 (10:45 -0700)]
common: Move and rename CONFIG_SYS_SUPPORT_64BIT_DATA

This is not really a CONFIG since it is not intended to be set by boards.
Move it into the compiler header with other similar defines, and rename
it.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move ROUND() into kernel.h
Simon Glass [Sat, 28 Dec 2019 17:45:09 +0000 (10:45 -0700)]
common: Move ROUND() into kernel.h

Move this macro in with all the other rounding macros.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move check_member() to kernel.h
Simon Glass [Sat, 28 Dec 2019 17:45:08 +0000 (10:45 -0700)]
common: Move check_member() to kernel.h

The kernel.h file has a number of useful macros including a few related
to structures. Move check_member() there too.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move hang() to the same header as panic()
Simon Glass [Sat, 28 Dec 2019 17:45:07 +0000 (10:45 -0700)]
common: Move hang() to the same header as panic()

At present panic() is in the vsprintf.h header file. That does not seem
like an obvious choice for hang(), even though it relates to panic(). So
let's put hang() in its own header.

Signed-off-by: Simon Glass <sjg@chromium.org>
[trini: Migrate a few more files]
Signed-off-by: Tom Rini <trini@konsulko.com>
4 years agocommon: Move testdram() into init.h
Simon Glass [Sat, 28 Dec 2019 17:45:06 +0000 (10:45 -0700)]
common: Move testdram() into init.h

This function is called during init so move it to the init header file.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move RAM-sizing functions to init.h
Simon Glass [Sat, 28 Dec 2019 17:45:05 +0000 (10:45 -0700)]
common: Move RAM-sizing functions to init.h

These functions relate to memory init so move them into the init
header.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Rename and move source()
Simon Glass [Sat, 28 Dec 2019 17:45:04 +0000 (10:45 -0700)]
common: Rename and move source()

This function has a very generic name which does not adequately describe
its purpose. Rename it and move it to image.h, since it relates to reading
a script from an image.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move the image globals into image.h
Simon Glass [Sat, 28 Dec 2019 17:45:03 +0000 (10:45 -0700)]
common: Move the image globals into image.h

These three globals relate to image handling. Move them to the image
header file.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agoimage: Rename load_addr, save_addr, save_size
Simon Glass [Sat, 28 Dec 2019 17:45:02 +0000 (10:45 -0700)]
image: Rename load_addr, save_addr, save_size

These global variables are quite short and generic. In fact the same name
is more often used locally for struct members and function arguments.

Add a image_ prefix to make them easier to distinguish.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move reset_cpu() to the CPU header
Simon Glass [Sat, 28 Dec 2019 17:45:01 +0000 (10:45 -0700)]
common: Move reset_cpu() to the CPU header

Move this function out of common.h and into a relevant header file.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move reset_misc() function to arch header
Simon Glass [Sat, 28 Dec 2019 17:45:00 +0000 (10:45 -0700)]
common: Move reset_misc() function to arch header

This function is only used on ARM devices. Move it out of the common file
and to a arch-specific header.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move get_tbclk() to time.h
Simon Glass [Sat, 28 Dec 2019 17:44:59 +0000 (10:44 -0700)]
common: Move get_tbclk() to time.h

This function related to timer and most of the timer functions are in
time.h, so move this function there.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move clock functions into a new file
Simon Glass [Sat, 28 Dec 2019 17:44:58 +0000 (10:44 -0700)]
common: Move clock functions into a new file

These three clock functions don't use driver model and should be migrated.
In the meantime, create a new file to hold them.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move upmconfig() to ppc.h
Simon Glass [Sat, 28 Dec 2019 17:44:57 +0000 (10:44 -0700)]
common: Move upmconfig() to ppc.h

This file is only used by PowerPC so move it to an arch-specific header
file.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move ll_boot_init() to init.h
Simon Glass [Sat, 28 Dec 2019 17:44:56 +0000 (10:44 -0700)]
common: Move ll_boot_init() to init.h

This is an init-related function so belongs in that file. Move it.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: arm: Move s_init() to an ARM-specific header
Simon Glass [Sat, 28 Dec 2019 17:44:55 +0000 (10:44 -0700)]
common: arm: Move s_init() to an ARM-specific header

This function is only used on ARM devices so does not belong in the global
common header file. Move it to an ARM header.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move device-tree setup functions to fdt_support.h
Simon Glass [Sat, 28 Dec 2019 17:44:54 +0000 (10:44 -0700)]
common: Move device-tree setup functions to fdt_support.h

These functions relate to setting up the device tree for booting the OS.
The fdt_support.h header file supports similar functions, so move these
there.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move type declarations to linux/types.h
Simon Glass [Sat, 28 Dec 2019 17:44:53 +0000 (10:44 -0700)]
common: Move type declarations to linux/types.h

This file already has lots of type declarations so it seems better to put
all of them there.

Move them.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Drop the symbol_lookup() declaration
Simon Glass [Sat, 28 Dec 2019 17:44:52 +0000 (10:44 -0700)]
common: Drop the symbol_lookup() declaration

This function is not called anywhere so we can drop the declaration. If
it is needed one day, it should be added in its own header file.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Drop CONFIG_HAS_POST
Simon Glass [Sat, 28 Dec 2019 17:44:51 +0000 (10:44 -0700)]
common: Drop CONFIG_HAS_POST

This only exists to control whether the post/ directory is build. It is
just as easy to check this in the Makefile. Remove CONFIG_HAS_POST and use
an ifdef in the Makefile instead.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Drop CONFIG_POST_STD/ALT_LIST
Simon Glass [Sat, 28 Dec 2019 17:44:50 +0000 (10:44 -0700)]
common: Drop CONFIG_POST_STD/ALT_LIST

These CONFIG options are not used anymore. CONFIG_POST_ALT_LIST just
causes CONFIG_POST_STD_LIST to be set and it causes tests.c to be
compiled. So just make compiling tests.c unconditional.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move CONFIG_SYS_DEF_EEPROM_ADDR out of common.h
Simon Glass [Sat, 28 Dec 2019 17:44:49 +0000 (10:44 -0700)]
common: Move CONFIG_SYS_DEF_EEPROM_ADDR out of common.h

This define seems better suited to the eeprom header file, particularly
as it is only used in the eeprom.c file.

Move it.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move reset_phy() to net.h
Simon Glass [Sat, 28 Dec 2019 17:44:48 +0000 (10:44 -0700)]
common: Move reset_phy() to net.h

This is a network function so let's move it into that header.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Drop floppy disk support
Simon Glass [Sat, 28 Dec 2019 17:44:47 +0000 (10:44 -0700)]
common: Drop floppy disk support

This seems pretty old now. It has not been converted to driver model and
is not used by any boards.

Drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move jumptable_init() out of common.h
Simon Glass [Sat, 28 Dec 2019 17:44:46 +0000 (10:44 -0700)]
common: Move jumptable_init() out of common.h

This function is defined in exports.c so move it to its header file.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
4 years agocommon: Move relocate_code() to init.h
Simon Glass [Sat, 28 Dec 2019 17:44:45 +0000 (10:44 -0700)]
common: Move relocate_code() to init.h

This is an init function so move it out of the common header. Avoid using
the typedef so that we don't have to include the global_data header file.

Also tidy up the function style in comments while we are here.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move functions for loading from fat/ext2 to fs.h
Simon Glass [Sat, 28 Dec 2019 17:44:44 +0000 (10:44 -0700)]
common: Move functions for loading from fat/ext2 to fs.h

These are filesystem functions and belong in the filesystem header file.
Move them.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move do_tftpb() to net.h
Simon Glass [Sat, 28 Dec 2019 17:44:43 +0000 (10:44 -0700)]
common: Move do_tftpb() to net.h

This function belongs in the network header file. Move it.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move embedded fdt location to fdtdec.h
Simon Glass [Sat, 28 Dec 2019 17:44:42 +0000 (10:44 -0700)]
common: Move embedded fdt location to fdtdec.h

These declarations are only used in fdtdec.c so move them to its header
file.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Drop checkflash() and checkdram()
Simon Glass [Sat, 28 Dec 2019 17:44:41 +0000 (10:44 -0700)]
common: Drop checkflash() and checkdram()

These functions are not used in U-Boot. Drop them.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move flash_perror() to flash.h
Simon Glass [Sat, 28 Dec 2019 17:44:40 +0000 (10:44 -0700)]
common: Move flash_perror() to flash.h

This function belongs more in flash.h than common.h so move it.

Also remove the space before the bracket in some calls.

Signed-off-by: Simon Glass <sjg@chromium.org>
4 years agocommon: Move main_loop() to init.h
Simon Glass [Sat, 28 Dec 2019 17:44:39 +0000 (10:44 -0700)]
common: Move main_loop() to init.h

Move this function out of common.h and into a better place.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Simon Goldschmidt <simon.k.r.goldschmidt@gmail.com>
4 years agocommon: Drop mdm_init()
Simon Glass [Sat, 28 Dec 2019 17:44:38 +0000 (10:44 -0700)]
common: Drop mdm_init()

This is not used in U-Boot. Drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Simon Goldschmidt <simon.k.r.goldschmidt@gmail.com>
4 years agotools: ftdgrep: correct the find regions loop in do_fdtgrep
Patrick Delaunay [Mon, 13 Jan 2020 08:33:51 +0000 (09:33 +0100)]
tools: ftdgrep: correct the find regions loop in do_fdtgrep

Use realloc and update the loop executed in do_fdtgrep to find all
the regions: only test count > max_region after the second pass.

This patch solve an issue if the number of region found (count)
is greater then the default value (max_region = count = 100):
the second pass is never executed, because the loop stops after
the first pass (i = 0, count > 100, max_regions = 100)
with error -1 and the error message
"Internal error with fdtgrep_find_region".

I also update the error message.

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
4 years agoarm: Add arm handoff header file
Michael Trimarchi [Sun, 5 Jan 2020 15:51:13 +0000 (16:51 +0100)]
arm: Add arm handoff header file

Add an arch-specific handoff header so that we can use the HANDOFF feature
on arm devices.

Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
4 years agoserial: ns16550: Use old baud rate divisor for flushing if not given
Patrik Dahlström [Sat, 21 Dec 2019 16:25:12 +0000 (17:25 +0100)]
serial: ns16550: Use old baud rate divisor for flushing if not given

If baud_divisor is not set (i.e. == -1), we should use the baud divisor
already in use for flushing the xmit register. If we don't flush the
xmit register, then SPL will hang.

Signed-off-by: Patrik Dahlström <risca@dalakolonin.se>
4 years agocmd: mtd: solve bad block support in erase command
Patrick Delaunay [Fri, 20 Sep 2019 07:20:12 +0000 (09:20 +0200)]
cmd: mtd: solve bad block support in erase command

This patch modify the loop in mtd erase command to erase one by one
the blocks in the requested area.

It solves issue on "mtd erase" command on nand with existing bad block,
the command is interrupted on the first bad block with the trace:
"Skipping bad block at 0xffffffffffffffff"

In MTD driver (nand/raw), when a bad block is present on the MTD
device, the erase_op.fail_addr is not updated and we have the initial
value MTD_FAIL_ADDR_UNKNOWN = (ULL)-1.

This case seems normal in nand_base.c:nand_erase_nand(),
we have the 2 exit cases during the loop:

1/ we have a bad block (nand_block_checkbad)
instr->state = MTD_ERASE_FAILED
loop interrupted (goto erase_exit)

2/ if block erase failed (status & NAND_STATUS_FAIL)
instr->state = MTD_ERASE_FAILED;
instr->fail_addr =
((loff_t)page << chip->page_shift);
loop interrupted (goto erase_exit)

So erase_op.fail_addr can't be used if bad blocks were present
in the erased area; we need to use mtd_erase only one block to detect
and skip these existing bad blocks (as it is done in nand_util.c).

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
4 years agoremoteproc: elf_loader: fix program header parsing
Fabien Dessenne [Wed, 4 Sep 2019 07:53:22 +0000 (09:53 +0200)]
remoteproc: elf_loader: fix program header parsing

Fix an issue where some sections are never loaded : if p_type is
different from PT_LOAD the phdr pointer must be incremented.

Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com>
Acked-by: Suman Anna <s-anna@ti.com>
4 years agoconfigs: ls1028aqds: enable mdio muxing by default
Alex Marginean [Mon, 2 Dec 2019 10:58:14 +0000 (12:58 +0200)]
configs: ls1028aqds: enable mdio muxing by default

LS1028A QDS boards have a MDIO MUX and they require the driver for it for
PHYs to work.

Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoconfigs: fsl-layerscape: secure_boot: Enable setexpr command
Udit Agarwal [Wed, 20 Nov 2019 08:51:27 +0000 (08:51 +0000)]
configs: fsl-layerscape: secure_boot: Enable setexpr command

setexpr command is used while running secure boot
(chain of trust with confidentiality) feature.

Enable CONFIG_CMD_SETEXPR to enable setexpr command.

Signed-off-by: Udit Agarwal <udit.agarwal@nxp.com>
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoboard: fsl: lx2160a: Fix the loop in board_fix_fdt function
Pankaj Bansal [Wed, 15 Jan 2020 05:57:00 +0000 (05:57 +0000)]
board: fsl: lx2160a: Fix the loop in board_fix_fdt function

Fix loop in board_fix_fdt that erroneously increments the counter
in all cases whereas the counter should be incremented only if a
matching string has been found.

Fixes: 5d535aa40b ("board: fsl: lx2160a: implement board_fix_fdt")

Signed-off-by: Pankaj Bansal <pankaj.bansal@nxp.com>
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoarch: armv8: fsl-layerscape: export serdes config to environment
Alex Marginean [Fri, 10 Jan 2020 23:05:40 +0000 (01:05 +0200)]
arch: armv8: fsl-layerscape: export serdes config to environment

Exports the serdes configuration as an environment variable for LS gen 3
SoCs, so it can be used in u-boot command line.  It should particularly
be useful for applying Linux DT overlays for the given serdes
configuration.
This code is called from arch_misc_init and not from the existing
serdes_init function because it depends on U-Boot environment being set
up.

Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoboard: fsl: ls1028a: free up arch_misc_init
Alex Marginean [Fri, 10 Jan 2020 23:05:39 +0000 (01:05 +0200)]
board: fsl: ls1028a: free up arch_misc_init

Currently LS1028A board code uses arch_misc_init to set up the board mux
on QDS.  Move this code to misc_init_r.  This is consistent with LS gen 2
and T series SoCs/boards.

Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoboard: fsl: ls1088a: remove empty arch_misc_init
Alex Marginean [Fri, 10 Jan 2020 23:05:38 +0000 (01:05 +0200)]
board: fsl: ls1088a: remove empty arch_misc_init

The arch_misc_init function is empty on LS108x SoCs/boards, remove it.

Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoboard: fsl: ls2080a/ls2081a: remove empty arch_misc_init
Alex Marginean [Fri, 10 Jan 2020 23:05:37 +0000 (01:05 +0200)]
board: fsl: ls2080a/ls2081a: remove empty arch_misc_init

The arch_misc_init function is empty on LS2 SoCs/boards, remove it.

Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoboard: fsl: lx2160a: free up arch_misc_init
Alex Marginean [Fri, 10 Jan 2020 23:05:36 +0000 (01:05 +0200)]
board: fsl: lx2160a: free up arch_misc_init

Currently LX2 board code uses arch_misc_init to set up the board mux on
RDB and QDS.  Move this code to misc_init_r.  This is consistent with LS
gen 2 and T series SoCs/boards.

Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoarmv8: ls1028a_serdes: Add few missing serdes protocols
Alex Marginean [Fri, 10 Jan 2020 21:51:32 +0000 (23:51 +0200)]
armv8: ls1028a_serdes: Add few missing serdes protocols

Add serdes protocol 0x7777, 0x9999, 0xb998, 0xbb56 to supported list.
These protocols are supported and functional but they trigger a warning
in U-Boot console at boot because they are not on this list.

Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>