oweals/u-boot.git
4 years agoi2c: designware_i2c: Read device-tree properties
Simon Glass [Thu, 23 Jan 2020 18:48:11 +0000 (11:48 -0700)]
i2c: designware_i2c: Read device-tree properties

The i2c controller defines a few timing properties. Read these in and
store them for use by the driver.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Heiko Schocher <hs@denx.de>
4 years agoi2c: designware_i2c: Bring in the binding file
Simon Glass [Thu, 23 Jan 2020 18:48:10 +0000 (11:48 -0700)]
i2c: designware_i2c: Bring in the binding file

Bring in this file from Linux v5.4.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Heiko Schocher <hs@denx.de>
4 years agoi2c: designware_i2c: Use an accurate bus clock instead of MHz
Simon Glass [Thu, 23 Jan 2020 18:48:09 +0000 (11:48 -0700)]
i2c: designware_i2c: Use an accurate bus clock instead of MHz

At present the driver uses an approximation for the bus clock, e.g. 166MHz
instead of 166 2/3 MHz.

This can result in small errors in the resulting I2C speed, perhaps 0.5%
or so.

Adjust the existing code to start from the accurate figure, even if later
rounding reduces this accuracy.

Update the bus speed code to work in KHz instead of MHz, which removes
most of the error.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Heiko Schocher <hs@denx.de>
4 years agoi2c: designware_i2c: Use an enum for selected speed mode
Simon Glass [Thu, 23 Jan 2020 18:48:08 +0000 (11:48 -0700)]
i2c: designware_i2c: Use an enum for selected speed mode

Group these #defines into an enum to make it easier to understand the
relationship between them.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Jun Chen <ptchentw@gmail.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
4 years agoi2c: designware_i2c: Rename 'max' speed to 'high' speed
Simon Glass [Thu, 23 Jan 2020 18:48:07 +0000 (11:48 -0700)]
i2c: designware_i2c: Rename 'max' speed to 'high' speed

Some SoCs support a higher speed than what is currently called 'max' in
this driver. Rename it to 'high' speed, which is the official name of the
3.4MHz speed.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Jun Chen <ptchentw@gmail.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
4 years agoi2c: designware_i2c: Include clk.h in the header file
Simon Glass [Thu, 23 Jan 2020 18:48:06 +0000 (11:48 -0700)]
i2c: designware_i2c: Include clk.h in the header file

We use struct clk here so really should include this header file to avoid
build errors. Also switch the order of clk.h in the C file to match the
required code style.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Ley Foon Tan <ley.foon.tan@intel.com>
Reviewed-by: Jun Chen <ptchentw@gmail.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
4 years agoi2c: designware_i2c: Don't allow changing IC_CLK
Simon Glass [Thu, 23 Jan 2020 18:48:05 +0000 (11:48 -0700)]
i2c: designware_i2c: Don't allow changing IC_CLK

If a different input clock is required then the correct way to do this is
with a clock driver. Don't allow boards to override IC_CLK.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Heiko Schocher <hs@denx.de>
4 years agoi2c: designware_i2c: Add more registers
Simon Glass [Thu, 23 Jan 2020 18:48:04 +0000 (11:48 -0700)]
i2c: designware_i2c: Add more registers

Some versions of this peripherals provide more control of the bus
behaviour. Add definitions for these registers.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Ley Foon Tan <ley.foon.tan@intel.com>
Reviewed-by: Jun Chen <ptchentw@gmail.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
4 years agoglobal_data: remove unused mxc_i2c specific field
Baruch Siach [Wed, 25 Dec 2019 15:57:06 +0000 (17:57 +0200)]
global_data: remove unused mxc_i2c specific field

The srdata field is unused since commit 71204e95ce13228 ("i2c: mxc:
refactor i2c driver and support dm").

Cc: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Reviewed-by: Peng Fan <peng.fan@nxp.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 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>
4 years agodrivers: net: fsl_enetc: fix SXGMII MAC configuration
Alex Marginean [Fri, 10 Jan 2020 21:32:20 +0000 (23:32 +0200)]
drivers: net: fsl_enetc: fix SXGMII MAC configuration

Separate MAC and serdes configuration, MAC configuration must be applied
at each enetc_start() as FLR clears it.
This restores traffic for ENETC interfaces in USXGMII mode.

Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agolx2160: Correct default environment variable
Meenakshi Aggarwal [Fri, 10 Jan 2020 14:43:19 +0000 (20:13 +0530)]
lx2160: Correct default environment variable

Create separate "boot_scripts" and "boot_script_hdr" environment
variable for LX2160A RDB and QDS board.

Signed-off-by: Meenakshi Aggarwal <meenakshi.aggarwal@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoinclude/configs: ls1012afrwy: adjust kernel_addr_r
Biwen Li [Fri, 10 Jan 2020 09:16:05 +0000 (17:16 +0800)]
include/configs: ls1012afrwy: adjust kernel_addr_r

The linux kernel Image is growing quite quickly,
if kernel Image size grow beyond 36 MB then
kernel Image at load address 0x81000000
overlaps with the reserved memory region
at 0x83400000.

Adjust kernel load address(kernel_addr_r) from
0x81000000 to 0x96000000 to avoid kernel Image
overlapping with reserved memory region.

This change fixes the below U-Boot error while
booting uncompressed kernel Image through booti command,
ERROR: reserving fdt memory region failed (addr=83400000 size=c00000)

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoinclude/configs: ls1012ardb: adjust kernel_addr_r
Biwen Li [Fri, 10 Jan 2020 09:16:04 +0000 (17:16 +0800)]
include/configs: ls1012ardb: adjust kernel_addr_r

The linux kernel Image is growing quite quickly,
if kernel Image size grow beyond 36 MB then
kernel Image at load address 0x81000000
overlaps with the reserved memory region
at 0x83400000.

Adjust kernel load address(kernel_addr_r) from
0x81000000 to 0x96000000 to avoid kernel Image
overlapping with reserved memory region.

This change fixes the below U-Boot error while
booting uncompressed kernel Image through booti command,
ERROR: reserving fdt memory region failed (addr=83400000 size=c00000)

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoarmv8: fsl-layerscape: LS1044A/1048A: enable Only 1x 10GE port
Pramod Kumar [Thu, 9 Jan 2020 08:53:16 +0000 (08:53 +0000)]
armv8: fsl-layerscape: LS1044A/1048A: enable Only 1x 10GE port

LS1088A has four personalities, LS1088A, LS1084A, LS1048A and LS1044A.
LS1044A, LS1048A are LS1088A personalities, which support only one
1x 10GE port.
MAC1 and MAC2 are associated with 1G SGMII, 2.5G SGMII, and XFI.
Disable MAC1 to have only one 1x 10GE port for LS1044A, LS1048A.

Signed-off-by: Pramod Kumar <pramod.kumar_1@nxp.com>
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoARM: LS1021A: remove redundant "depends on ARCH_LS1021A"
Masahiro Yamada [Wed, 8 Jan 2020 10:46:45 +0000 (19:46 +0900)]
ARM: LS1021A: remove redundant "depends on ARCH_LS1021A"

These config entries are inside the menu block, which already
depends on ARCH_LS1021A:

  menu "LS102xA architecture"
          depends on ARCH_LS1021A

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoboard/lx2160aqds: Update the DSPI status fixup
Xiaowei Bao [Wed, 8 Jan 2020 06:29:54 +0000 (14:29 +0800)]
board/lx2160aqds: Update the DSPI status fixup

The dts node of the DSPI controller in kernel is spi instead of dspi,
it is not correct if use "/soc/dspi@" to fix up the status of the dts
in kernel, so, modify it to "/soc/spi@".

The DSPI2 and I2C5 are muxed, and the status of DSPI2 node in kernel dts
default value is okay, So set the status of DSPI2 node in kernel dts to
disabled if it is muxed as I2C5.

Signed-off-by: Xiaowei Bao <xiaowei.bao@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
4 years agoconfigs: lx2160a: enable CONFIG_OF_BOARD_FIXUP for SECURE_BOOT defconfig
Wasim Khan [Mon, 6 Jan 2020 12:06:02 +0000 (12:06 +0000)]
configs: lx2160a: enable CONFIG_OF_BOARD_FIXUP for SECURE_BOOT defconfig

lx2160a rev1 and rev2 SoC has different pcie controller.
The pcie controller device tree node fields "compatible"
and registers names needs to be updated accordingly.

Enable CONFIG_OF_BOARD_FIXUP to apply board_fix_fdt
which updates the "compatible" and registers names.

Signed-off-by: Wasim Khan <wasim.khan@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>