]> git.dujemihanovic.xyz Git - u-boot.git/log
u-boot.git
3 years agoclk: stm32mp1: add support of I2C6_K
Patrick Delaunay [Fri, 22 Jan 2021 14:34:25 +0000 (15:34 +0100)]
clk: stm32mp1: add support of I2C6_K

Add support of missing I2C6_K with bit 3 of RCC_MC_APB5ENSETR =
I2C6EN: I2C6 peripheral clocks enable.

This patch allows customer to use I2C6 in SPL or in U-Boot
as other I2C instance, already support in clk driver.

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
3 years agopinctrl: stm32: bind only the enabled GPIO subnode
Patrick Delaunay [Thu, 21 Jan 2021 16:39:08 +0000 (17:39 +0100)]
pinctrl: stm32: bind only the enabled GPIO subnode

Bind only the enabled GPIO subnode, to avoid to probe the node
"gpio-controller" present in SOC dtsi (disabled by default) but
not enabled in the included pincontrol dtsi file.

For example, in stm32mp15xxac-pinctrl.dtsi 2 gpio bank are absent:
 gpioj: gpio@5000b000
 gpiok: gpio@5000c000

Then these GPIO are absent in output of command "dm tree" and
"gpio status -a"

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
3 years agopinctrl: stm32: correct management pin display of OTYPE
Patrick Delaunay [Thu, 21 Jan 2021 16:39:07 +0000 (17:39 +0100)]
pinctrl: stm32: correct management pin display of OTYPE

OTYPE can be used for output or for alternate function to select
PP = push-pull or OP = open-drain mode, according reference manual
(Table 81. Port bit configuration table).

This patch removes this indication for input pins and adds it
for AF and output pins for pinmux command output.

Fixes: b305dbc08b08 ("pinctrl: stm32: display bias information for all pins")
Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
3 years agopinctrl: stmfx: Use PINNAME_SIZE for pin's name size
Patrice Chotard [Wed, 20 Jan 2021 12:43:40 +0000 (13:43 +0100)]
pinctrl: stmfx: Use PINNAME_SIZE for pin's name size

Instead of redefining a pin's name size, use PINNAME_SIZE defined
in include/dm/pinctrl.h

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
3 years agopinctrl: stmfx: Fix pin configuration issue
Patrice Chotard [Wed, 20 Jan 2021 12:43:39 +0000 (13:43 +0100)]
pinctrl: stmfx: Fix pin configuration issue

pin-controller pin's name must be equal to pin's name used in device
tree with "pins" DT property.

Issue detected on stm32mp157c-ev1 board with goodix touchscreen.
In DT, the goodix's pin is declared in DT with the node:

        goodix_pins: goodix {
pins = "gpio14";
bias-pull-down;
};

Whereas in stmfx pin-controller driver, pin's name are equal to
"stmfx_gpioxx" where xx is the pin number.
This lead to not configure stmfx's pins at probe because pins is
identified by its name (see pinctrl_pin_name_to_selector() in
pinctrl-generic.c) and stmfx pin "gpio14" can't be found.

To fix this issue, come back to the original stmfx pin's name.

Revert "pinctrl: stmfx: update pin name"

This reverts commit 38d30cdcd65c73eeefac5efa328ad444a53b77dd.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Tested-by: Patrick DELAUNAY <patrick.delaunay@st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
3 years agoconfigs: stm32mp1: enable the fastboot oem command bootbus
Patrick Delaunay [Wed, 9 Sep 2020 13:24:35 +0000 (15:24 +0200)]
configs: stm32mp1: enable the fastboot oem command bootbus

Enable the fastboot oem command bootbus, used to configure the eMMC
boot behavior, with same format than 'mmc bootbus'
and with parameter: boot_bus_width reset_boot_bus_width boot_mode

On stm32mp1 boards the expected command is
$> fastboot oem partconf:0 0 0

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@st.com>
3 years agoconfigs: stm32mp1: enable the fastboot oem command partconf
Patrick Delaunay [Wed, 9 Sep 2020 13:24:34 +0000 (15:24 +0200)]
configs: stm32mp1: enable the fastboot oem command partconf

Enable the fastboot oem command partconf, used to select the correct
eMMC boot partition, with same format than 'mmc partconf'
with parameter: boot_ack boot_partition
On stm32mp1 family:
- boot_ack = 1 (Boot Acknowledge is needed by ROM code)
- boot_partition = 1 or 2 (Boot partition 1 / 2 enabled for boot)

So on EV1 board the expected commands to select boot partition 1 or 2
$> fastboot oem partconf:1 1
$> fastboot oem partconf:1 2

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@st.com>
3 years agoconfigs: stm32mp1: enable the fastboot oem command format
Jean-Philippe ROMAIN [Wed, 9 Sep 2020 13:24:33 +0000 (15:24 +0200)]
configs: stm32mp1: enable the fastboot oem command format

Enable the fastboot oem command format and set the variable
"partitions" with default eMMC partitions list.

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Signed-off-by: Jean-Philippe ROMAIN <jean-philippe.romain@st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@st.com>
3 years agoconfigs: stm32mp1: enable fastboot support of eMMC boot partition
Jean-Philippe ROMAIN [Wed, 9 Sep 2020 13:24:32 +0000 (15:24 +0200)]
configs: stm32mp1: enable fastboot support of eMMC boot partition

Activate fastboot support on boot partition for eMMC, mmc1 device
on STMicroelectronics board (EV1).

Signed-off-by: Jean-Philippe ROMAIN <jean-philippe.romain@st.com>
Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@st.com>
3 years agoMerge git://git.denx.de/u-boot-marvell
Tom Rini [Mon, 8 Feb 2021 15:55:51 +0000 (10:55 -0500)]
Merge git://git.denx.de/u-boot-marvell

- Espressobin: Set default env values at runtime (Pali)
- Espressobin: Set the maximum slave SPI speed to 40MHz (Pali)
- theadorable: PCIe test code enhancement and early deemphasis
  enabling (Stefan)
- pci_mvebu: Disable config access to PCI host bridge ports (Stefan)
- mv_sdhci: parse device-tree entry (Baruch)

3 years agoMerge git://git.denx.de/u-boot-fsl-qoriq
Tom Rini [Mon, 8 Feb 2021 15:55:28 +0000 (10:55 -0500)]
Merge git://git.denx.de/u-boot-fsl-qoriq

Layerscape: Enable gpio
Bug fixes & updates related to dspi, qspi, pciep, SVR mask,
stream-id, env variables, mdio for LAyerscape Platforms
Add SATA, network variant 1, 2 support on sl28
powerpc: T1042: drop CONFIG_VIDEO, Add kmcent2 board supporrt, keymile
Bug fixes and updates for keymile, Kontron

3 years agoMerge git://git.denx.de/u-boot-sh
Tom Rini [Mon, 8 Feb 2021 15:54:37 +0000 (10:54 -0500)]
Merge git://git.denx.de/u-boot-sh

- Beacon EmbeddedWorks RZG2H/N Dev Kit support

3 years agoMerge branch 'master' of git://git.denx.de/u-boot-usb
Tom Rini [Mon, 8 Feb 2021 15:54:01 +0000 (10:54 -0500)]
Merge branch 'master' of git://git.denx.de/u-boot-usb

3 years agoconfigs: lx2160aqds: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:19 +0000 (19:02 +0800)]
configs: lx2160aqds: enable CMD_GPIO

Enable CMD_GPIO for board lx2160aqds

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: lx2160ardb: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:18 +0000 (19:02 +0800)]
configs: lx2160ardb: enable CMD_GPIO

Enable CMD_GPIO for board lx2160ardb

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1088ardb: enable DM_GPIO and CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:17 +0000 (19:02 +0800)]
configs: ls1088ardb: enable DM_GPIO and CMD_GPIO

Enable DM_GPIO and CMD_GPIO for board ls1088ardb

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1088aqds: enable DM_GPIO and CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:16 +0000 (19:02 +0800)]
configs: ls1088aqds: enable DM_GPIO and CMD_GPIO

Enable DM_GPIO and CMD_GPIO for board ls1088aqds

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls2088aqds: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:15 +0000 (19:02 +0800)]
configs: ls2088aqds: enable CMD_GPIO

Enable CMD_GPIO for board ls2088aqds

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls2088ardb: enable DM_GPIO and CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:14 +0000 (19:02 +0800)]
configs: ls2088ardb: enable DM_GPIO and CMD_GPIO

Enable DM_GPIO and CMD_GPIO for board ls2088ardb

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1046aqds: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:13 +0000 (19:02 +0800)]
configs: ls1046aqds: enable CMD_GPIO

Enable CMD_GPIO for board ls1046aqds

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1046ardb: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:12 +0000 (19:02 +0800)]
configs: ls1046ardb: enable CMD_GPIO

Enable CMD_GPIO for board ls1046ardb

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1043ardb: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:11 +0000 (19:02 +0800)]
configs: ls1043ardb: enable CMD_GPIO

Enable CMD_GPIO for board ls1043ardb

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1043aqds: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:10 +0000 (19:02 +0800)]
configs: ls1043aqds: enable CMD_GPIO

Enable CMD_GPIO for board ls1043aqds

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1028ardb: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:09 +0000 (19:02 +0800)]
configs: ls1028ardb: enable CMD_GPIO

Enable CMD_GPIO for board ls1028ardb

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1028aqds: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:08 +0000 (19:02 +0800)]
configs: ls1028aqds: enable CMD_GPIO

Enable CMD_GPIO for board ls1028aqds

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1021atwr: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:07 +0000 (19:02 +0800)]
configs: ls1021atwr: enable CMD_GPIO

Enable CMD_GPIO for ls1021atwr

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1021aqds: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:06 +0000 (19:02 +0800)]
configs: ls1021aqds: enable CMD_GPIO

Enable CMD_GPIO for board ls1021aqds

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1012ardb: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:05 +0000 (19:02 +0800)]
configs: ls1012ardb: enable CMD_GPIO

Enable CMD_GPIO for ls1012ardb

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1012afrwy: enable CMD_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:04 +0000 (19:02 +0800)]
configs: ls1012afrwy: enable CMD_GPIO

Enable CMD_GPIO for ls1012afrwy

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1021aqds: enable CONFIG_MPC8XXX_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:03 +0000 (19:02 +0800)]
configs: ls1021aqds: enable CONFIG_MPC8XXX_GPIO

Enable CONFIG_MPC8XXX_GPIO for board ls1021aqds

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1021atwr: enable CONFIG_MPC8XXX_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:02 +0000 (19:02 +0800)]
configs: ls1021atwr: enable CONFIG_MPC8XXX_GPIO

Enable CONFIG_MPC8XXX_GPIO for board ls1021atwr

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1046a: enable MPC8XXX_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:01 +0000 (19:02 +0800)]
configs: ls1046a: enable MPC8XXX_GPIO

Enable MPC8XXX_GPIO for SoC LS1046A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: lx2160a: enable CONFIG_MPC8XXX_GPIO
Biwen Li [Fri, 5 Feb 2021 11:02:00 +0000 (19:02 +0800)]
configs: lx2160a: enable CONFIG_MPC8XXX_GPIO

Enable CONFIG_MPC8XXX_GPIO for SoC LX2160A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls208xa: enable CONFIG_MPC8XXX_GPIO
Biwen Li [Fri, 5 Feb 2021 11:01:59 +0000 (19:01 +0800)]
configs: ls208xa: enable CONFIG_MPC8XXX_GPIO

Enable CONFIG_MPC8XXX_GPIO for LS208xA

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1088a: enable CONFIG_MPC8XXX_GPIO
Biwen Li [Fri, 5 Feb 2021 11:01:58 +0000 (19:01 +0800)]
configs: ls1088a: enable CONFIG_MPC8XXX_GPIO

Enable CONFIG_MPC8XXX_GPIO for LS1088A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1028a: enable CONFIG_MPC8XXX_GPIO
Biwen Li [Fri, 5 Feb 2021 11:01:57 +0000 (19:01 +0800)]
configs: ls1028a: enable CONFIG_MPC8XXX_GPIO

Enable CONFIG_MPC8XXX_GPIO for SoC LS1028A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1043a: enable CONFIG_MPC8XXX_GPIO
Biwen Li [Fri, 5 Feb 2021 11:01:56 +0000 (19:01 +0800)]
configs: ls1043a: enable CONFIG_MPC8XXX_GPIO

Enable CONFIG_MPC8XXX_GPIO for SoC LS1043A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1012a: enable CONFIG_MPC8XXX_GPIO
Biwen Li [Fri, 5 Feb 2021 11:01:55 +0000 (19:01 +0800)]
configs: ls1012a: enable CONFIG_MPC8XXX_GPIO

Enable CONFIG_MPC8XXX_GPIO for SoC LS1012A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarm64: dts: ls208xa: add gpio node
Biwen Li [Fri, 5 Feb 2021 11:01:54 +0000 (19:01 +0800)]
arm64: dts: ls208xa: add gpio node

Add gpio node for SoC LS208xA

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarm64: dts: ls1088a: add gpio node
Biwen Li [Fri, 5 Feb 2021 11:01:53 +0000 (19:01 +0800)]
arm64: dts: ls1088a: add gpio node

Add gpio node for SoC LS1088A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarm64: dts: ls1046a: add gpio node
Biwen Li [Fri, 5 Feb 2021 11:01:52 +0000 (19:01 +0800)]
arm64: dts: ls1046a: add gpio node

Add gpio node for SoC LS1046A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarm64: dts: ls1043a: add gpio node
Biwen Li [Fri, 5 Feb 2021 11:01:51 +0000 (19:01 +0800)]
arm64: dts: ls1043a: add gpio node

Add gpio node for SoC LS1043A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarm64: dts: ls1028a: add gpio node
Biwen Li [Fri, 5 Feb 2021 11:01:50 +0000 (19:01 +0800)]
arm64: dts: ls1028a: add gpio node

Add gpio node for SoC LS1028A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarm64: dts: ls1012a: add gpio node
Biwen Li [Fri, 5 Feb 2021 11:01:49 +0000 (19:01 +0800)]
arm64: dts: ls1012a: add gpio node

Add gpio node for SoC LS1012A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarm: dts: ls1021a: add gpio node
Biwen Li [Fri, 5 Feb 2021 11:01:48 +0000 (19:01 +0800)]
arm: dts: ls1021a: add gpio node

Add gpio node for SoC LS1021A

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agogpio: mpc8xxx_gpio: Fix for litte endian
Biwen Li [Fri, 5 Feb 2021 11:01:47 +0000 (19:01 +0800)]
gpio: mpc8xxx_gpio: Fix for litte endian

Update gpio driver to use same logic for big-endian and little-endian

Signed-off-by: Biwen Li <biwen.li@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: T1042: Drop the CONFIG_VIDEO
Hou Zhiqiang [Fri, 5 Feb 2021 08:34:02 +0000 (16:34 +0800)]
configs: T1042: Drop the CONFIG_VIDEO

Drop the CONFIG_VIDEO to fix the following build warning.
===================== WARNING ======================
This board does not use CONFIG_DM_VIDEO Please update
the board to use CONFIG_DM_VIDEO before the v2019.07 release.
UPD     include/generated/dt.h
Failure to update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
UPD     include/generated/timestamp_autogenerated.h
====================================================

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agompc8xxx: fsl_pamu: Update data type in config_pamu
Priyanka Jain [Fri, 5 Feb 2021 08:31:11 +0000 (14:01 +0530)]
mpc8xxx: fsl_pamu: Update data type in config_pamu

Update data type of '1' to '1ull' in below assignment
size = 1ull << sizebit;

to fix incorrect assignment issue.
e.g: when sizebit was 31, 0x80000000 got sign extended to
0xffffffff_80000000

Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
Reported-by: Dean Saridakis <dean.saridakis@baesystems.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarmv7: ls102xa: Enable I-Cache to speed up the boot time
Hou Zhiqiang [Fri, 5 Feb 2021 07:45:12 +0000 (15:45 +0800)]
armv7: ls102xa: Enable I-Cache to speed up the boot time

Enable the I-Cache to speed up the boot time, especailly for the NOR
boot, currently it takes about 15 seconds from power up to the U-Boot
prompt, and with the I-Cache enabled it only takes around 2.5 seconds.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoboard/km: move km i2c deblock declarations to a km/common.h
Aleksandar Gerasimovski [Fri, 5 Feb 2021 06:02:01 +0000 (06:02 +0000)]
board/km: move km i2c deblock declarations to a km/common.h

Cleanup, move the declarations to keymile/common.h instead declaring them
per-board config.h

Signed-off-by: Aleksandar Gerasimovski <aleksandar.gerasimovski@hitachi-powergrids.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agopci: kconfig: layerscape: Change LX2162A PCIe node compatible string
Hou Zhiqiang [Fri, 29 Jan 2021 05:22:02 +0000 (13:22 +0800)]
pci: kconfig: layerscape: Change LX2162A PCIe node compatible string

LX2162A is not like LX2160A which has different PCIe controller
in rev1 and rev2 silicon. It supports only one configuration of
PCIe controller, which is same as LS2088A. So update PCIe
compatible string same as LS2088A.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Reviewed-by: Wasim Khan <wasim.khan@nxp.com>
Tested-by: Wasim Khan <wasim.khan@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agopci: layerscape: Remove the shadow SVR definitions
Hou Zhiqiang [Fri, 29 Jan 2021 04:47:05 +0000 (12:47 +0800)]
pci: layerscape: Remove the shadow SVR definitions

This patch moves the SVR definitions to a new svr.h for
Layerscape armv7 and armv8 platforms respectively, so that
the PCIe driver can reuse them.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Reviewed-by: Wasim Khan <wasim.khan@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agospi: fsl_qspi: apply the same settings for LS1088 as LS208x
Mathew McBride [Mon, 25 Jan 2021 03:55:22 +0000 (03:55 +0000)]
spi: fsl_qspi: apply the same settings for LS1088 as LS208x

The LS1088 requires the same QUADSPI_QURIK_BASE_INTERNAL
workaround as the LS208x and also has a 64 byte TX buffer.

With the previous settings SPI-NAND reads over AHB were
corrupted.

Fixes: 91afd36f3802 ("spi: Transform the FSL QuadSPI driver to use the SPI MEM API")
Signed-off-by: Mathew McBride <matt@traverse.com.au>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agospi: fsl_qspi: Ensure width is respected in spi-mem operations
Mathew McBride [Mon, 25 Jan 2021 03:55:21 +0000 (03:55 +0000)]
spi: fsl_qspi: Ensure width is respected in spi-mem operations

Adapted from kernel commit b0177aca7aea
From: Michael Walle <michael@walle.cc>

Make use of a core helper to ensure the desired width is respected
when calling spi-mem operators.

Otherwise only the SPI controller will be matched with the flash chip,
which might lead to wrong widths. Also consider the width specified by
the user in the device tree.

Fixes: 91afd36f38 ("spi: Add a driver for the Freescale/NXP QuadSPI controller")
Signed-off-by: Michael Walle <michael@walle.cc>
Link: https://lore.kernel.org/r/20200114154613.8195-1-michael@walle.cc
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Mathew McBride <matt@traverse.com.au> [adapt for U-Boot]
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agomem: spi-mem: add declaration for spi_mem_default_supports_op
Mathew McBride [Mon, 25 Jan 2021 03:55:20 +0000 (03:55 +0000)]
mem: spi-mem: add declaration for spi_mem_default_supports_op

spi_mem_default_supports_op is used internally by controller
drivers to verify operation semantics are correct.

It is used internally inside spi-mem but has not (in U-Boot)
been declared in spi-mem.h for external use.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
Reviewed-by: Pratyush Yadav <p.yadav@ti.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoPowerPC: keymile: Add support for kmcent2 board
Niel Fourie [Thu, 21 Jan 2021 12:19:20 +0000 (13:19 +0100)]
PowerPC: keymile: Add support for kmcent2 board

Add basic support for the Hitachi Power Grids kmcent2 board, based
on the NXP QorIQ T1040 SoC.

Signed-off-by: Valentin Longchamp <valentin.longchamp@hitachi-powergrids.com>
Signed-off-by: Rainer Boschung <rainer.boschung@hitachi-powergrids.com>
Signed-off-by: Niel Fourie <lusus@denx.de>
Cc: Holger Brunck <holger.brunck@hitachi-powergrids.com>
Cc: Heiko Schocher <hs@denx.de>
Reviewed-by: Stefan Roese <sr@denx.de>
[Fixed blank line at EOF errors]
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agokeymile: common: update to set_env_hex(), fix "pram" radix
Niel Fourie [Thu, 21 Jan 2021 12:19:19 +0000 (13:19 +0100)]
keymile: common: update to set_env_hex(), fix "pram" radix

Replace instances of sprintf()/set_env() for setting hexadecimal
values with set_env_hex().

In set_km_env() the "pram" variable was set to an hexadecimal
value, while initr_mem() expects an unsigned decimal, so use
set_env_ulong() instead.

Signed-off-by: Niel Fourie <lusus@denx.de>
Cc: Holger Brunck <holger.brunck@hitachi-powergrids.com>
Cc: Heiko Schocher <hs@denx.de>
Reviewed-by: Stefan Roese <sr@denx.de>
[Rebased]
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoPowerPC: dts: Pulled in kmcent2 dts files from Linux 5.10
Niel Fourie [Thu, 21 Jan 2021 12:19:18 +0000 (13:19 +0100)]
PowerPC: dts: Pulled in kmcent2 dts files from Linux 5.10

Pulled in the kmcent2.dts and all its dependents from Linux 5.10,
commit 2c85ebc57b3e upstream. Replaced the license text with
SPDX License Identifiers.

Signed-off-by: Niel Fourie <lusus@denx.de>
Cc: Holger Brunck <holger.brunck@hitachi-powergrids.com>
Cc: Heiko Schocher <hs@denx.de>
Reviewed-by: Stefan Roese <sr@denx.de>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoboard/km/common: fix pnvramaddr and varaddr
Aleksandar Gerasimovski [Tue, 19 Jan 2021 10:41:00 +0000 (10:41 +0000)]
board/km/common: fix pnvramaddr and varaddr

Take into account SDRAM_BASE address when calculating pnvramaddr and
varaddr offsets.
Up to now Keymile designs had SDRAM_BASE equal to zero and the offsets
where calculated correctly, this fix is for the upcoming designs that
have SDRAM_BASE different then zero.

Signed-off-by: Aleksandar Gerasimovski <aleksandar.gerasimovski@hitachi-powergrids.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agokeymile: common: qrio: print QRIO id and revision number
Aleksandar Gerasimovski [Wed, 13 Jan 2021 16:20:51 +0000 (16:20 +0000)]
keymile: common: qrio: print QRIO id and revision number

Add show_qrio function to print chip id and revision information.
There are already multiple QRIO chip versions available and the upcoming
designs may want to show used version.

Signed-off-by: Rainer Boschung <rainer.boschung@hitachi-powergrids.com>
Signed-off-by: Aleksandar Gerasimovski <aleksandar.gerasimovski@hitachi-powergrids.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoboard: keymile: common: fix qrio compilation for arm
Aleksandar Gerasimovski [Wed, 13 Jan 2021 16:20:35 +0000 (16:20 +0000)]
board: keymile: common: fix qrio compilation for arm

This patch is fixing qrio driver compilation for ARM architecture:
- It includes asm/io.h for in_/out_ access
- It use correct names for set/clear_bits as defined in linux/bitops.h

Signed-off-by: Aleksandar Gerasimovski <aleksandar.gerasimovski@hitachi-powergrids.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarmv8: lx2: SVR_SOC_VER: Mask CAN_FD and security bit
Wasim Khan [Wed, 13 Jan 2021 11:01:23 +0000 (12:01 +0100)]
armv8: lx2: SVR_SOC_VER: Mask CAN_FD and security bit

Multiple LX2(LX2160A/LX2162A SoC) personality variants
exists based on CAN-FD and security bit in SVR.

Currenly SVR_SOC_VER mask only security bit.
Update SVR_SOC_VER to mask CAN_FD and security bit
for LX2 products.

Signed-off-by: Wasim Khan <wasim.khan@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarmv8: ls1028a: fix stream id allocation
Nipun Gupta [Tue, 12 Jan 2021 13:12:46 +0000 (18:42 +0530)]
armv8: ls1028a: fix stream id allocation

When A-050382 errata is enabled, ECAM and EDMA have
conflicting stream id 40. This patch fixes the same.

Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Reviewed-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoboard: sl28: add SATA support
Michael Walle [Thu, 7 Jan 2021 23:08:59 +0000 (00:08 +0100)]
board: sl28: add SATA support

Enable SATA support. Although not supported by the usual SATA pins on
the SMARC baseboard connector, SATA mode is supported on a PCIe lane.
This way one can use a mSATA card in a Mini PCI slot.

We need to invert the received data because in this mode the polarity of
the SerDes lane is swapped. Provide a fixup in board_early_init_f() for
the SPL. board_early_init_f() is then not common between SPL and u-boot
proper anymore, thus common.c is removed, as it just contained said
function.

Signed-off-by: Michael Walle <michael@walle.cc>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoboard: sl28: add network variant 2 support
Michael Walle [Thu, 7 Jan 2021 23:08:58 +0000 (00:08 +0100)]
board: sl28: add network variant 2 support

Although this variant has two external network ports, they are not (yet)
supported by the bootloader because they are connected via an internal
network switch. Otherwise its the same as the other variants.

Signed-off-by: Michael Walle <michael@walle.cc>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoboard: sl28: add network variant 1 support
Michael Walle [Thu, 7 Jan 2021 23:08:57 +0000 (00:08 +0100)]
board: sl28: add network variant 1 support

This variant has one network port connected via RGMII and doesn't have
any TSN capabilities out-of-the-box. Instead it has all four SerDes
lanes available for customer use.

Signed-off-by: Michael Walle <michael@walle.cc>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoboard: sl28: move ethernet aliases to variant specific dtsi
Michael Walle [Thu, 7 Jan 2021 23:08:56 +0000 (00:08 +0100)]
board: sl28: move ethernet aliases to variant specific dtsi

The variants differ in their network configuration. Move the first two
network aliases to the proper variant device tree includes. This is in
prepartion for variant 1 and 2 support which has a different network
port mapping. The network aliases for the two internal ports will stay
in the common dtsi because they are present on all board variants.

This might leave a hole if there is no ethernet1 alias. This is
intended.

Signed-off-by: Michael Walle <michael@walle.cc>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agonet: eqos: Reduce the MDIO wait time
Ye Li [Mon, 28 Dec 2020 12:15:10 +0000 (20:15 +0800)]
net: eqos: Reduce the MDIO wait time

Current MDIO wait time is too long, which introduce long delay when
PHY negotiation register checking. Reduce it to 10us

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Fugang Duan <Fugang.duan@nxp.com>
Signed-off-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarmv8: dts: fsl-lx2162a: add dspi node into qds dts
Zhao Qiang [Fri, 11 Dec 2020 09:31:39 +0000 (17:31 +0800)]
armv8: dts: fsl-lx2162a: add dspi node into qds dts

Add dspi node into lx2162aqds device tree

Signed-off-by: Zhao Qiang <qiang.zhao@nxp.com>
[Rebased]
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoarmv8: lx2162aqds: disable non existing pcie controllers
Wasim Khan [Fri, 11 Dec 2020 08:56:51 +0000 (14:26 +0530)]
armv8: lx2162aqds: disable non existing pcie controllers

disable non existing pcie controllers on lx2162aqds

Signed-off-by: Wasim Khan <wasim.khan@nxp.com>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoconfigs: ls1088aqds: add COMMON_ENV to fix distroboot
Biwen Li [Thu, 10 Dec 2020 03:02:47 +0000 (11:02 +0800)]
configs: ls1088aqds: add COMMON_ENV to fix distroboot

Add COMMON_ENV(kernelheader_addr_r, fdtheader_addr_r,
kernel_addr_r, fdt_addr_r, load_addr)
to fix a bug that failed to boot to ubuntu
Failed log as follows,
## Executing script at 80000000
load - load binary file from a filesystemUsage:
load <interface> [<dev[:part]> [<addr> [<filename> [bytes [pos]]]]]
    - Load binary file filename from partition part on device
       type interface instance dev to address addr in memory.
      bytes gives the size to load in bytes.
      If bytes is 0 or omitted, the file is read until the end.
      pos gives the file byte position to start reading from.
      If pos is 0 or omitted, the file is read from the start.
...
Bad Linux ARM64 Image magic!
SCRIPT FAILED: continuing...

Signed-off-by: Biwen Li <biwen.li@nxp.com>
[Updated description]
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agonet: memac_phy: add a timeout to MDIO operations
Ioana Ciornei [Wed, 9 Dec 2020 11:31:58 +0000 (13:31 +0200)]
net: memac_phy: add a timeout to MDIO operations

We have encountered circumstances when a board design does not include
pull-up resistors on the external MDIO buses which are not used. This
leads to the MDIO data line not being pulled-up, thus the MDIO controller
will always see the line as busy.

Without a timeout in the MDIO bus driver, the execution is stuck in an
infinite loop when any access is initiated on that external bus.

Add a timeout in the driver so that we are protected in this
circumstance. This is similar to what is being done in the Linux
xgmac_mdio driver.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Reviewed-by: Madalin Bucur <madalin.bucur@oss.nxp.com>
[Rebased]
Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agoboard: kontron: disable flash unlock all
Michael Walle [Wed, 9 Dec 2020 09:53:26 +0000 (10:53 +0100)]
board: kontron: disable flash unlock all

Although the status register is protected by the hardware write
protection, there is a hardware jumper to disable that hardware write
protection. Thus if a user would set this jumper any u-boot start would
disable the write protection altogether.

Circumvent that by not disabling the write protection in the first
place.

Signed-off-by: Michael Walle <michael@walle.cc>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agomtd: spi-nor: add unlock all config option
Michael Walle [Wed, 9 Dec 2020 09:53:25 +0000 (10:53 +0100)]
mtd: spi-nor: add unlock all config option

Provide an explicit configuration option to disable default "unlock all"
of any flash chip which supports locking. It doesn't make sense to
automatically unprotect the entire flash on each u-boot startup if the
block protection bits are actually used.

Traditionally, the unlock was there to be able to write to flash devices
which powered-up with the block protection bits set. Over time this
feature creeped into all flash devices which support locking.

For a more detailed description and discussion see:
https://lore.kernel.org/linux-mtd/20201203162959.29589-8-michael@walle.cc/

Keep things simple in u-boot and just provide a configration option to
disable this behavior which can be set per board.

Signed-off-by: Michael Walle <michael@walle.cc>
Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
3 years agommc: mv_sdhci: parse device-tree entry
Baruch Siach [Tue, 2 Feb 2021 06:43:04 +0000 (08:43 +0200)]
mmc: mv_sdhci: parse device-tree entry

Call mmc_of_parse() so that generic DT properties like 'non-removable'
are taken into account.

This fixes boot on Clearfog with eMMC on SOM that requires the
non-removable property.

Reported-by: Thorsten Spille <thorsten_spille@netcor.de>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
Reviewed-by: Marek Behún <marek.behun@nic.cz>
3 years agoarm: mvebu: Espressobin: Set the maximum slave SPI speed to 40MHz
Konstantin Porotchkin [Wed, 27 Jan 2021 16:12:00 +0000 (17:12 +0100)]
arm: mvebu: Espressobin: Set the maximum slave SPI speed to 40MHz

While the SPI controller speed is defined by DTS, the maximum
slave speed (connected devices) is limited by the pre-defined
configuration value CONFIG_SF_DEFAULT_SPEED to 1MHz
This patch increases this maximum SPI slave device speed to 40MHz

Change-Id: I0d1239bd8a2061c66725c2c227c1e1f49c92c29e
Signed-off-by: Konstantin Porotchkin <kostap@marvell.com>
Reviewed-on: http://vgitil04.il.marvell.com:8080/59516
Tested-by: iSoC Platform CI <ykjenk@marvell.com>
Reviewed-by: Igal Liberman <igall@marvell.com>
[pali: Set CONFIG_SF_DEFAULT_SPEED via defconfig]
Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Stefan Roese <sr@denx.de>
3 years agocmd: mvebu/bubt: Fix default options in help
Pali Rohár [Wed, 27 Jan 2021 10:56:02 +0000 (11:56 +0100)]
cmd: mvebu/bubt: Fix default options in help

Default options depends on compile time defines.

Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Stefan Roese <sr@denx.de>
3 years agoarm: mvebu: theadorable: Set deephasis bit in PCIe configs very early
Stefan Roese [Mon, 25 Jan 2021 14:27:20 +0000 (15:27 +0100)]
arm: mvebu: theadorable: Set deephasis bit in PCIe configs very early

Testing has shown, that the quality of the PCIe signals and also the
stability of correct link establishment on the 2 PCIe ports is better,
when the deemphasis bit is set in the PCIe config register.

This needs to be done very early, even before the SERDES setup code is
run. This way, the first link will already be established with this
setup.

Signed-off-by: Stefan Roese <sr@denx.de>
3 years agoarm: mvebu: theadorable: Enhance "pcie" test cmd to check link width/speed
Stefan Roese [Mon, 25 Jan 2021 14:27:19 +0000 (15:27 +0100)]
arm: mvebu: theadorable: Enhance "pcie" test cmd to check link width/speed

This patch changes the board specific "pcie" U-Boot command to not only
check for PCIe device existance but also for the correct link speed
and width that has been established. This cmd can be used by U-Boot
scripts for automated testing, if the PCIe setup is correct. Meaning,
that all PCIe devices are correctly detected and the link speed and
width is corrent.

Signed-off-by: Stefan Roese <sr@denx.de>
3 years agopci: pci_mvebu: Disable config access to PCI host bridge ports
Stefan Roese [Mon, 25 Jan 2021 14:25:31 +0000 (15:25 +0100)]
pci: pci_mvebu: Disable config access to PCI host bridge ports

This patch changes the PCI config routines in the Armada XP / 38x driver
to not allow access to the PCIe root ports.

While updating the Armada XP based theadorable to the latest mainline
and testing it with the DM PCI driver I noticed, that the PCI root
bridge was being configured incorrectly. Resulting in the PCIe Intel
WiFi was not working correctly in Linux. With this patch applied, all
PCIe devices work without any issues in Linux again.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Marek Behún <marek.behun@nic.cz>
Cc: Phil Sutter <phil@nwl.cc>
Cc: Mario Six <mario.six@gdsys.cc>
3 years agoarm: mvebu: Espressobin: Set default value for $ethNaddr env variable
Pali Rohár [Wed, 23 Dec 2020 11:21:30 +0000 (12:21 +0100)]
arm: mvebu: Espressobin: Set default value for $ethNaddr env variable

On Espressobin board are MAC addresses stored in U-Boot env area. Therefore
they are not present in default_environment[] array constructed at compile
time.

This change puts permanent MAC addresses into default_environment[] array
at board runtime. Espressobin board has enabled DEFAULT_ENV_IS_RW option
and therefore can modify this array.

This change ensure that 'env default -a' does not delete permanent MAC
addresses from Espressobin env storage area.

Signed-off-by: Pali Rohár <pali@kernel.org>
Acked-by: Andre Heider <a.heider@gmail.com>
3 years agoarm: mvebu: Espressobin: Set default value for $fdtfile env variable
Pali Rohár [Wed, 23 Dec 2020 11:21:29 +0000 (12:21 +0100)]
arm: mvebu: Espressobin: Set default value for $fdtfile env variable

On Espressobin board value for $fdtfile cannot be determined at compile
time and is calculated at board runtime code. This change uses a new option
DEFAULT_ENV_IS_RW to allow modifying default_environment[] array at runtime
and set into it correct value.

This change also ensure that 'env default -a' set correct value to $fdtfile.

Signed-off-by: Pali Rohár <pali@kernel.org>
Acked-by: Andre Heider <a.heider@gmail.com>
3 years agoenv: Allow to set default_environment[] from board code via compile option DEFAULT_EN...
Pali Rohár [Wed, 23 Dec 2020 11:21:28 +0000 (12:21 +0100)]
env: Allow to set default_environment[] from board code via compile option DEFAULT_ENV_IS_RW

This change allows board code to modify default_environment[] array when
compile option DEFAULT_ENV_IS_RW is specified in board config file.

Some board default variables depend on runtime configuration which is not
known at compile time. Therefore allow to set default_environment[] array
as non-const and allow board code to modify it when it is needed.

Signed-off-by: Pali Rohár <pali@kernel.org>
Acked-by: Andre Heider <a.heider@gmail.com>
3 years agoARM: rmobile: Add Beacon EmbeddedWorks RZG2H Dev Kit
Adam Ford [Wed, 3 Feb 2021 12:57:20 +0000 (06:57 -0600)]
ARM: rmobile: Add Beacon EmbeddedWorks RZG2H Dev Kit

The Beacon EmbeddedWorks kit is based on the R8A774E1 SoC also
known as the RZ/G2H.

The kit consists of a SOM + Baseboard and supports microSD,
eMMC, Ethernet, a couple celular radios, two CAN interfaces,
Bluetooth and WiFi.  It shares much of the same design as
the RZ/G2M and RZ/G2N dev kits.

Signed-off-by: Adam Ford <aford173@gmail.com>
3 years agoARM: rmobile: Add Beacon EmbeddedWorks RZG2N Dev Kit
Adam Ford [Wed, 3 Feb 2021 12:57:19 +0000 (06:57 -0600)]
ARM: rmobile: Add Beacon EmbeddedWorks RZG2N Dev Kit

The Beacon EmbeddedWorks kit is based on the R8A774B1 SoC also
known as the RZ/G2N.

The kit consists of a SOM + Baseboard and supports microSD,
eMMC, Ethernet, a couple celular radios, two CAN interfaces,
Bluetooth and WiFi.  It shares much of the same design as
the RZ/G2M dev kit.

Signed-off-by: Adam Ford <aford173@gmail.com>
3 years agoarm: dts: r8a774b1: Import DTS queued for Linux 5.12-rc1
Adam Ford [Wed, 3 Feb 2021 12:57:18 +0000 (06:57 -0600)]
arm: dts: r8a774b1: Import DTS queued for Linux 5.12-rc1

Update the RZ/G2N dtsi from Renesas repo destined to become 5.12-rc1.

Signed-off-by: Adam Ford <aford173@gmail.com>
3 years agoarm: dts: r8a774e1: Import DTS queued for Linux 5.12-rc1
Adam Ford [Wed, 3 Feb 2021 12:57:17 +0000 (06:57 -0600)]
arm: dts: r8a774e1: Import DTS queued for Linux 5.12-rc1

Update the RZ/G2H dtsi from Renesas repo destined to become 5.12-rc1.

Signed-off-by: Adam Ford <aford173@gmail.com>
3 years agoarm: dts: r8a774a1: Import DTS queued for Linux 5.12-rc1
Adam Ford [Wed, 3 Feb 2021 12:57:16 +0000 (06:57 -0600)]
arm: dts: r8a774a1: Import DTS queued for Linux 5.12-rc1

Update the RZ/G2M dtsi and r8a774a1-beacon-rzg2m-kit kit
from Renesas repo destined to become 5.12-rc1.

Signed-off-by: Adam Ford <aford173@gmail.com>
3 years agodt-bindings: Sync versaclock.h with upcoming 5.12-rc1
Adam Ford [Wed, 3 Feb 2021 12:57:15 +0000 (06:57 -0600)]
dt-bindings: Sync versaclock.h with upcoming 5.12-rc1

The versaclock doesn't have a driver yet, but there are a bunch
of device tree updates for the Beacon RZ/G2 boards that won't
compile without these.  A driver is coming, so sync the bindings
for now

Signed-off-by: Adam Ford <aford173@gmail.com>
3 years agofastboot: reinit partition after storing GPT or MBR
Roman Stratiienko [Wed, 27 Jan 2021 15:40:16 +0000 (17:40 +0200)]
fastboot: reinit partition after storing GPT or MBR

In case MMC has MBR system and fastboot writes GPT,
MMC is still recognized as MBR.
Invoke part_init() to purge cached data and update
information about partition table type.

Signed-off-by: Roman Stratiienko <r.stratiienko@gmail.com>
3 years agofastboot: add command to select the eMMC boot configuration
Patrick Delaunay [Wed, 27 Jan 2021 13:46:49 +0000 (14:46 +0100)]
fastboot: add command to select the eMMC boot configuration

Add command oem bootbus which executes the command
``mmc bootbus <id> <arg>`` on the current fastboot mmc device
(<i> = CONFIG_FASTBOOT_FLASH_MMC_DEV) to set the eMMC boot
configuration on first update, with
<arg> =  boot_bus_width reset_boot_bus_width boot_mode

$> fastboot oem bootbus:<boot_bus_width> <reset_boot_bus_width> <boot_mode>

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
3 years agofastboot: add command to select the default emmc hwpart for boot
Patrick Delaunay [Wed, 27 Jan 2021 13:46:48 +0000 (14:46 +0100)]
fastboot: add command to select the default emmc hwpart for boot

Add fastboot command oem partconf which executes the command
``mmc partconf <id> <arg> 0`` on the current <id> mmc device
to configure the eMMC boot partition with
<arg>: boot_ack boot_partition, so the command is:

$> fastboot oem partconf:<boot_ack> <boot_partition>

The partition_access argument is forced to 0 (userdata)

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
[lukma - Kconfig adjustments after merging this patch]

3 years agofastboot: mmc: extend flash/erase for both emmc hwpart 1 and 2
Patrick Delaunay [Wed, 27 Jan 2021 13:46:47 +0000 (14:46 +0100)]
fastboot: mmc: extend flash/erase for both emmc hwpart 1 and 2

Update the code and the configs for eMMC boot and userdata
partitions acces
- FASTBOOT_MMC_BOOT_SUPPORT: boot partition 1 and 2 (erase/write)
- FASTBOOT_MMC_BOOT1_NAME: boot partition 1, default name="mmc0boot0"
- FASTBOOT_MMC_BOOT2_NAME: boot partition 2, default name="mmc0boot1"

This patch also removes the unnecessary dependency with
ARCH_MEDIATEK and EFI_PARTITION.

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
3 years agofastboot: mmc: Add CONFIG_FASTBOOT_MMC_USER_SUPPORT
Patrick Delaunay [Wed, 27 Jan 2021 13:46:46 +0000 (14:46 +0100)]
fastboot: mmc: Add CONFIG_FASTBOOT_MMC_USER_SUPPORT

Split userdata and boot partition support for eMMC update
and correct the description (update is supported).

The new configuration CONFIG_FASTBOOT_MMC_USER_SUPPORT
allows to activate support of userdata partition update,
based on target name=CONFIG_FASTBOOT_MMC_USER_NAME

This patch also removes the unnecessary dependency with
ARCH_MEDIATEK and EFI_PARTITION.

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
3 years agofastboot: Implement generic fastboot_set_reboot_flag
Roman Kovalivskyi [Tue, 26 Jan 2021 20:54:56 +0000 (22:54 +0200)]
fastboot: Implement generic fastboot_set_reboot_flag

It is possible to implement fastboot_set_reboot_flag in a generic way
if BCB commands are turned on for a target. Using
bcb_set_reboot_reason allows to do this by simply passing string with
correct reboot reason that should be handled during next boot process.

If BCB are turned off, then bcb_set_reboot_reason would simply return
error, so it won't introduce any new behaviour for such targets.

Signed-off-by: Roman Kovalivskyi <roman.kovalivskyi@globallogic.com>
3 years agoRevert "fastboot: Add default fastboot_set_reboot_flag implementation"
Roman Kovalivskyi [Tue, 26 Jan 2021 20:54:55 +0000 (22:54 +0200)]
Revert "fastboot: Add default fastboot_set_reboot_flag implementation"

This reverts commit 0ebf9842e56c5b8cb7cb1f990bb452cc14af6225.

Current generic implementation of fastboot_set_reboot_flag is somewhat
messy and requires some additional configuration option to be enabled
besides CMD_BCB, so it reverts that implementtion in order to bring a
new cleaner one.

Next commit introduces new generic implementation of
fastboot_set_reboot_flag.

Signed-off-by: Roman Kovalivskyi <roman.kovalivskyi@globallogic.com>
3 years agodfu: dfu_sf: use correct print code
Heinrich Schuchardt [Sun, 27 Dec 2020 08:58:05 +0000 (09:58 +0100)]
dfu: dfu_sf: use correct print code

For printing unsigned int %u has to be used.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
3 years agoMerge https://gitlab.denx.de/u-boot/custodians/u-boot-x86
Tom Rini [Sat, 6 Feb 2021 14:45:58 +0000 (09:45 -0500)]
Merge https://gitlab.denx.de/u-boot/custodians/u-boot-x86

- introduces some standard sysinfo options as a source, e.g. to read
  strapping pins to determine the board revision
- allows the U-Boot version number to be included
- allows the version number to be provided programmatically, e.g. to
  support the build system adding information after U-Boot is built

3 years agosmbios: Allow a few values to come from sysinfo
Simon Glass [Fri, 5 Feb 2021 04:17:23 +0000 (21:17 -0700)]
smbios: Allow a few values to come from sysinfo

While static configuration is useful it cannot cover every case. Sometimes
board revisions are encoded in resistor straps and must be read at
runtime.

The easiest way to provide this information is via sysinfo, since the
board can then provide a driver to read whatever is needed.

Add some standard sysinfo options for this, and use them to obtain the
required information.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
3 years agox86: coral: Add sysinfo ops
Simon Glass [Fri, 5 Feb 2021 04:17:22 +0000 (21:17 -0700)]
x86: coral: Add sysinfo ops

These ops are missing at present which is not permitted. Add an empty
operation struct.

Note: If the uclass requires operations then the drivers should provide
them. Otherwise, checking for missing operations must be done in every
uclass operation, so it adds to code size.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>