Commit Graph

54150 Commits

Author SHA1 Message Date
Martin Husemann
757ab988e4 tools: improve portability of imx_cntr_image.sh
Replace non-portable operator == with =

The operator == in sh(1) / test(1) is non-POSIX and only implemented by
some shells (like bash). It is equivalent to the standard defined operator =.
2019-01-01 14:12:18 +01:00
Fabien Lahoudere
725019bebe embestmx6boards: Add SPL support
In order to boot faster with falcon mode, we need to add SPL
support to riotboard.

Signed-off-by: Fabien Lahoudere <fabien.lahoudere@collabora.com>
2019-01-01 14:12:18 +01:00
Peng Fan
0b366cf2b0 imx: imx8qxp_mek: imximage: remove config.h
config.h is not needed, remove it.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
2019-01-01 14:12:18 +01:00
Michael Heimpold
210594a868 doc: imx: fix typos in mxsimage.txt
This fixes two small typos in mxsimage.txt.

Signed-off-by: Michael Heimpold <mhei@heimpold.de>
Reviewed-by: Breno Lima <breno.lima@nxp.com>
2019-01-01 14:12:18 +01:00
Michael Heimpold
5271dcf581 doc: imx: fix typo in imximage.txt
Signed-off-by: Michael Heimpold <mhei@heimpold.de>
Reviewed-by: Breno Lima <breno.lima@nxp.com>
2019-01-01 14:12:18 +01:00
Michael Heimpold
499609374a configs: mx23_olinuxino_defconfig: disable bootefi command
CONFIG_CMD_BOOTEFI is enabled by Kconfig default, but rarely
used on this board/platform.
So let's disable it for the boards default config.
This also saves around 16 KiB in the final u-boot.sb.

Signed-off-by: Michael Heimpold <mhei@heimpold.de>
2019-01-01 14:12:18 +01:00
Michael Heimpold
49cc1646f3 configs: mx23_olinuxino_defconfig: fix status led definition
While migrating individual status led usages to Kconfig stuff,
a (random) value was introduced for this board which does not
work but produces the following error message during boot:

__led_init: failed requesting GPIO59!

Since Kconfig does not seem to accept a define as this point,
but the mxs gpio driver requires not only a simple integer value,
we need to use the plain value of MX23_PAD_SSP1_DETECT__GPIO_2_1.

Signed-off-by: Michael Heimpold <mhei@heimpold.de>
Fixes: 2d8d190c83 ("status_led: Kconfig migration")
2019-01-01 14:12:18 +01:00
Martin Fuzzey
a2e99a71b2 w1: Add driver for i.MX bus master controller
Two variants of controllers are supported:
V1 (bitwise only) found in
	i.MX21, i.MX27, i.MX31, i.MX51
V2 (byte operations) found in
	i.MX25, i.MX35, i.MX50, i.MX53

Only tested on i.MX53 hardware but in both modes
(by modifying the device tree).

Signed-off-by: Martin Fuzzey <martin.fuzzey@flowbird.group>
2019-01-01 14:12:18 +01:00
Xiaoliang Yang
da4918acb8 watchdog: imx: add config to disable wdog reset
Add Kconfig option WATCHDOG_RESET_DISABLE to disable watchdog reset
in imx_watchdog driver, so that the watchdog will not be fed in
u-boot if CONFIG_WATCHDOG_RESET_DISABLE is enabled.

Signed-off-by: Xiaoliang Yang <xiaoliang.yang_1@nxp.com>
2019-01-01 14:12:18 +01:00
Xiaoliang Yang
005c1cf888 watchdog: driver support for fsl-lsch2
Support watchdog driver for fsl-lsch2. It's disabled in default.
If you want to use it, please enable CONFIG_IMX_WATCHDOG.
Define CONFIG_WATCHDOG_TIMEOUT_MSECS to set watchdog timeout.

Signed-off-by: Xiaoliang Yang <xiaoliang.yang_1@nxp.com>
2019-01-01 14:12:18 +01:00
Denis Zalevskiy
4dcbccf794 board: ge: Move VPD reading to the vpd_reader
Merge functionality duplicated in bx50v3 and mx53ppd: the logic
is the same except that process_vpd is called at different phases.
Also read_vpd could end up in error, so there is no VPD data in this
case - it shouldn't be processed.

Signed-off-by: Denis Zalevskiy <denis.zalevskiy@ge.com>
Signed-off-by: Fabien Lahoudere <fabien.lahoudere@collabora.com>
2019-01-01 14:12:18 +01:00
Denis Zalevskiy
4c55208350 board: ge: Move VPD EEPROM configuration to the defconfig
Use standard configuration logic to define EEPROM constants.
Names are based on VPD_EEPROM_ prefix because EEPROM_ is already
used by i2c_eeprom driver.

Signed-off-by: Denis Zalevskiy <denis.zalevskiy@ge.com>
Signed-off-by: Fabien Lahoudere <fabien.lahoudere@collabora.com>
2018-12-17 10:46:04 +01:00
Denis Zalevskiy
33a6c8d4e6 board: ge: Remove EEPROM bus param from read_vpd()
The bus is statically defined, so remove redundant parameters
from read_vpd() for PPD and Bx50v3.

Signed-off-by: Denis Zalevskiy <denis.zalevskiy@ge.com>
Signed-off-by: Fabien Lahoudere <fabien.lahoudere@collabora.com>
2018-12-17 10:46:04 +01:00
Pierre-Jean Texier
7f4269b24a warp7: configs: add CONFIG_FIT option
This enable FIT image support.

Signed-off-by: Pierre-Jean Texier <pjtexier@koncepto.io>
2018-12-17 10:46:04 +01:00
Tom Rini
d117d8f19b Merge branch 'master' of git://git.denx.de/u-boot-i2c 2018-12-13 09:36:55 -05:00
Tom Rini
277b06684d Merge branch '2018-12-12-master-imports'
- Various small TI platform updates
- Two unit test fixes
- qemu-arm updates
2018-12-12 19:45:07 -05:00
Adam Ford
dda9af3ad1 am3517_evm: Use ttyS2 instead of ttyO2
The serial driver in the kernel moved from ttyOx to ttySx a while
ago.  This patch updates the console parameter to align with the
kernel change.

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-12-12 12:14:25 -05:00
Peng Fan
cdd7486616 firmware: psci: introduce SPL_ARM_PSCI_FW
Introduce a new macro SPL_ARM_PSCI_FW

Signed-off-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Stefano Babic <sbabic@denx.de>
2018-12-12 12:14:25 -05:00
Heinrich Schuchardt
3cc137616d test: overlay: NULL passed as fdt
The uts created in do_ut_overlay() is not the one used in
cmd_ut_category(). Currently all tests are therefore called with
uts->priv = NULL and fail.

Using a static variable is the easiest fix here.

Fixes: e93232e15e ("test: overlay: Use cmd_ut_category()")
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2018-12-12 12:14:24 -05:00
Adam Ford
76f6d52e61 ARM: omap3logic: Remove legacy USB code in favor of DM_USB
With the defconfig options enabling DM_USB, the legacy code
can be removed.

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-12-12 12:14:24 -05:00
Adam Ford
f99f4ebb54 ARM: omap3_logic/omap35_logic: Move to DM_USB
The existing config is setup as a gadget but it doesn't use
DM_USB.  This patch converts all boards to DM_USB, but as host.

As host, it is able to mount USB drives and browse them.

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-12-12 12:14:24 -05:00
Felix Brack
bfaaacd3b2 arm: am335x-pdu001: Move from embedded to separate DTB
There is no need for an embedded device tree for this board so let the
build process generate a separate u-boot.dtb file instead.

Signed-off-by: Felix Brack <fb@ltec.ch>
2018-12-12 12:14:23 -05:00
Sekhar Nori
d50d6817b5 spl: fix build failure with !CONFIG_SPL_PCI_SUPPORT
Building U-Boot with CONFIG_PCI and CONFIG_DM_PCI enabled, but
CONFIG_SPL_PCI_SUPPORT disabled, results in following linker
error:

lib/built-in.o: In function `fdtdec_get_pci_bar32':
lib/fdtdec.c:305: undefined reference to `dm_pci_read_bar32'
fdtdec.c:305:(.text.fdtdec_get_pci_bar32+0x24): relocation truncated to fit: R_AARCH64_CALL26 against undefined symbol `dm_pci_read_bar32'

This is because reference to dm_pci_read_bar32() remains in lib/fdtdec.c
while SPL build does not descend into drivers/pci directory in
drivers/Makefile if CONFIG_SPL_PCI_SUPPORT is not enabled.

Fix this by applying appropriate #define guards in lib/fdtdec.c.
It looks like ns16550.c has the same problem, so fixed that too.

To simplify this, CONFIG_SPL_PCI_SUPPORT is renamed to CONFIG_SPL_PCI
(enables use of CONFIG_IS_ENABLED() macro).

Suggested-by: Vignesh R <vigneshr@ti.com>
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2018-12-12 12:14:23 -05:00
Andrew F. Davis
a6f6939e87 defconfigs: am335x_hs_evm: Sync HS and non-HS defconfigs
Sync new additions to non-HS defconfig with HS defconfig.

Signed-off-by: Andrew F. Davis <afd@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
2018-12-12 12:14:22 -05:00
Simon Glass
841d5fbae4 fdt: Add warning about CONFIG_OF_EMBED
This option has crept into use with some boards. Add a warning to try to
prevent this.

As an example:
   https://lists.denx.de/pipermail/u-boot/2017-September/304966.html

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
2018-12-12 12:14:22 -05:00
Tom Rini
91ff686562 blk: Rework guard around part_init call
The function part_init() will only be built when we have both
CONFIG_PARTITIONS and CONFIG_HAVE_BLOCK_DEVICE set.  Protect the call to
this function with both of these tests now.

Cc: Simon Glass <sjg@chromium.org>
Cc: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Cc: Michal Simek <michal.simek@xilinx.com>
Cc: York Sun <york.sun@nxp.com>
Cc: Prabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
Cc: Mingkai Hu <mingkai.hu@nxp.com>
Cc: Stefan Roese <sr@denx.de>
Cc: Marek Behún <marek.behun@nic.cz>
Cc: Vanessa Maegima <vanessa.maegima@nxp.com>
Cc: Eugen Hristev <eugen.hristev@microchip.com>
Cc: Adam Ford <aford173@gmail.com>
Cc: Jagan Teki <jagan@amarulasolutions.com>
Cc: Tom Warren <twarren@nvidia.com>
Cc: Stephen Warren <swarren@nvidia.com>
Cc: Vitaly Andrianov <vitalya@ti.com>
Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2018-12-12 12:14:22 -05:00
Simon Goldschmidt
b0b1768e1b test: hexdump: fix misplaced return
One of the hexdump tests in test/lib/hexdump.c returns right at the
start of the function without testing anything.

Fix this by moving the 'return 0;' statement to the end of the function.

Signed-off-by: Simon Goldschmidt <simon.k.r.goldschmidt@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2018-12-12 12:14:21 -05:00
Sumit Garg
03fb0958c9 qemu-arm: Add persistent environment support
Currently on qemu-arm platforms environment is kept in RAM. Instead
use pflash device 1 to provide persistent environment support across
device reset.

Also (optionally) provide support for persistent environment across
qemu machine OFF/ON using following instructions:

- Create envstore.img using qemu-img:
    qemu-img create -f raw envstore.img 64M
- Add a pflash drive parameter to the command line:
    -drive if=pflash,format=raw,index=1,file=envstore.img

Signed-off-by: Sumit Garg <sumit.garg@linaro.org>
2018-12-12 12:14:21 -05:00
Sumit Garg
5266db16ee qemu-arm: Enable VirtIO distro target
With -device virtio-blk-device,drive=hd0, it could detect distro boot
target.

Signed-off-by: Sumit Garg <sumit.garg@linaro.org>
Reviewed-by: Alexander Graf <agraf@suse.de>
2018-12-12 12:14:20 -05:00
Jean-Jacques Hiblot
22ecff594d i2c: tegra: Fix regression by implementing a dummy probe_chip() callback
Commit f32a8007ef ("dm: i2c: Make i2c_get_chip_for_busnum() fail if the
chip is not detected") introduced a regression for the NVIDIA Jetson TX2.

For some reason the xfer callback of the tegra i2c driver doesn't support
probing the I2C devices with a 0-length message.
Fixing the regression by providing a dummy implementation of probe_chip()
that does nothing.

Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
2018-12-12 06:06:14 +01:00
Adam Ford
286a5c44e6 ARM: davinci: Orphan Spectrum Digital AM18xx EVM
I had requested the da850 boards because their previous maintainer
had an invalid e-mail address.  I work at Logic PD who makes
the da850-evm kits, so I have access to various boards of theirs.

The Spectrum Digital AM18xx board is based on the Logic PD
da850 EVM, but it's not the same company.  Since I don't have the
hardware to test/verify changes, I would prefer to not be
responsible for this board.

Signed-off-by: Adam Ford <aford173@gmail.com>
2018-12-11 08:57:42 -05:00
Tom Rini
ee168783ae travis: Add check for configs without MAINTAINERS entries
The genboardscfg.py script will emit a WARNING message if we have new
defconfig files that are not listed in a MAINTAINERS file.  Make new
cases of this a failure we catch in Travis-CI.

Signed-off-by: Tom Rini <trini@konsulko.com>
2018-12-10 17:21:36 -05:00
Tom Rini
d94604d558 Add TFA boot flow for some Layerscape platforms
Add support for lx2160a SoC
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEorkTmaQ1QAtDiYw67UVZlNoLnbQFAlwOzFoACgkQ7UVZlNoL
 nbQUdQ//SRRBfjUe8RYTbojvTGQav0GTxnMkz4GFSrqu0nvGMW2YSlheOMqq72sg
 rK5mQqDvdkItCn+G8AZ5NV2ijkQ7NQWCfqL3EtApzTpv6qjfgv7xvopz8q4NZvzB
 Wp+4cFf9YQjNwhJ7kLvWHB7SBiz9AfMYRAj9cscH9xsGL3HxPj62WDfwyK/QXana
 KIxRKQ26/1AdOZy272yv70vlFj4IwForxV3ACimsWRuYcb8yre3pE0tD7XpMCSNv
 9GOfL7r4LS7U0+QnJoVeYLMhttRvOGJNUYtO2+ImO5NC3u9v8ehYEQ3FjGmM69CB
 vuPDQBDQc+Ap+Iu3k18PYSstp+mc9fbe9SQdlx6ARAecQqWTN4EOhf8s3m2bQq3S
 B58I0Zvowcdm8V2JKdXw94UqZX862U8PWH0BmcuX+4k+kRDwwU4XQY2nLp+Htz1w
 2q6vEdKGj7YUOaomx9fmKRL+9BFGoD+M9mTiHOwzqwxy6Pa9VkruSvMErM7p2l/z
 xI/Q+xPJhyk5TXgZRsz4Nat59WpifWruibKEd4PArQ446heHWmzLWjw/MWiFyd/H
 agCdpDZVJ8R7h1Krs+Ez8XjR1Qcg0gs+CdNBuvqxzOpMQGGonXA1nwi8YfHykhII
 urfoC8pew1yxiLGw7J2JSX808HV/09WCSEsrOOhE3T78rXTDlS4=
 =aT7d
 -----END PGP SIGNATURE-----

Merge tag 'fsl-qoriq-for-v2019.01-rc2' of git://git.denx.de/u-boot-fsl-qoriq

Add TFA boot flow for some Layerscape platforms
Add support for lx2160a SoC

[trini: Add a bunch of missing MAINTAINERS entries]
Signed-off-by: Tom Rini <trini@konsulko.com>
2018-12-10 17:19:59 -05:00
Tom Rini
2918f58faa - mips: bcm: disable CONFIG_SWAP_IO_SPACE to force native endianess in readl() & co.
this fixes 09ace9161b
 - mips: bcm6838: fix device tree warning
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEiQkHUH+J02LLC9InKPlOlyTyXBgFAlwOqAAACgkQKPlOlyTy
 XBgCKBAApaxFgFmni+pX81zxTBpcbM4YNXFgPdRrdsNXMJiEEgly/FLi1xnDmXpQ
 wohXo1UT9Nv0jTUV6aRTY0l183+AXV4voFGGh3Vsd38B/JPO4kEFDTCjA0yjRki0
 0FYaGRqIJiO9WaW5kUZvxlfKBFbaOIf+oZE9rAhMduPcaWCfpc9S6/tWltYAFnSm
 +s/51gEKyt/mLA/h5T+K932VkpBY2GggzGeuXof1kGGT4OaGdKi5mkN/MqcK9cR5
 kllsN8ZH5M+0IejrIZKhgsFp9X27g/MG7FR5D0OH3rzqybex63WWyJnRYmi31R0G
 xskFHjlVnF/1MGSeDG3c6cyqWpnddWm3LtRsrrb3MEWspYmoD4PbNftydjFb/1wi
 70y1wPci5pph/RCkeeOZ5ciUWdJdgxlhtB6BJcRlUXUo0WQm5ciZEQkvW/E+bAQJ
 igBde2xiLSND2xSljAoOCg9HZjaoog71WUOaf4++VLygo6D80J4dGzN7NOICxQf2
 1nMFHbJPbnTJtxg5CVem1wun45NUchEocz4ex4zz4R7K3IU0WTu1RdbxSTMX2KDF
 Iwb6TArSQbxezDH6C4cPHdFMwkb7WnVzGuQNRaPg0/bEeGg07Q7Cqag9spJII6iT
 /SlFXTHAzwDc/Fy5krsbE2wLiUYuircdQPNkStHzPuW7cWGmzNc=
 =eDsn
 -----END PGP SIGNATURE-----

Merge tag 'mips-fixes-for-2019.01' of git://git.denx.de/u-boot-mips

- mips: bcm: disable CONFIG_SWAP_IO_SPACE to force native endianess in readl() & co.
  this fixes 09ace9161b
- mips: bcm6838: fix device tree warning
2018-12-10 17:12:28 -05:00
Álvaro Fernández Rojas
1410708eeb bmips: bcm6838: fix device tree warning
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2018-12-10 18:47:13 +01:00
Álvaro Fernández Rojas
4c0411eb44 bmips: swapping IO space isn't required
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
2018-12-10 18:46:45 +01:00
Tom Rini
8bf3c2442b Improvements:
- init DRAM for RK322x in SPL
 - add FAN53555 PMIC/regulator driver
 - update MicroCrystal RV3029 driver to Kconfig and sync from Linux
 - add bootcount uclass and first DM-driver for bootcount
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQEcBAABAgAGBQJcDiw9AAoJECaAFcEOcohNEa8H/RBWLbVQjHPXf6EjchXgVcSs
 Gc+g2QmKZbN21XebfzBpCuZj62NROTWUcrPtor17yEBiMM1xPfe1vC7qtbkR6USj
 VTt1JHeyGx3XafkkUpeps382YPfuaNqtabjwZaXlmeE4/VLbXQPE7x4tC4fdWus4
 9K3OGQgRNFirn+RIZ7dQWtCby82PEC3cHkPc/n82cVHofcDsgKYK9mPpfcCn/gWF
 A4Fa9cx4pjeaMrBHKjcByCiFmwYBPc97Hqzz64oHOdQP0g3h04ko+2w5DdwdeHVV
 jKNcvkHESF4m1RGjrTbLEhy1f5UuOfcA1ise/cDX4pjXlBdwxHmvqT5vsE0MQzI=
 =5sHL
 -----END PGP SIGNATURE-----

Merge tag 'for-master-20181210' of git://git.denx.de/u-boot-rockchip

Improvements:
- init DRAM for RK322x in SPL
- add FAN53555 PMIC/regulator driver
- update MicroCrystal RV3029 driver to Kconfig and sync from Linux
- add bootcount uclass and first DM-driver for bootcount
2018-12-10 10:19:09 -05:00
Tom Rini
7ff485c68b Merge branch 'master' of git://git.denx.de/u-boot-i2c
- DM_I2C_COMPAT removal for all ti platforms from Jean-Jacques Hiblot
- Fix in i2c command help output from Chirstoph Muellner.
2018-12-10 07:16:33 -05:00
Tom Rini
7504e9e75f Merge branch 'master' of git://git.denx.de/u-boot-sh 2018-12-10 07:15:55 -05:00
Tom Rini
e7463b37a1 Merge branch 'master' of git://git.denx.de/u-boot-socfpga 2018-12-10 07:15:41 -05:00
Tom Rini
48d299a799 Merge branch 'master' of git://git.denx.de/u-boot-usb
- DWC3 and UDC cleanup
2018-12-10 07:15:12 -05:00
Tom Rini
53287a89e9 Merge git://git.denx.de/u-boot-x86
- Enable RTC for Intel Tangier
- Wrap the call to 8259 PIC with Kconfig options for old targets without
  8259
- Warp the call to USB init with Kconfg options for coreboot & EFI
  payload
2018-12-10 07:14:48 -05:00
Philipp Tomsich
eff43904b7 rockchip: rk3399-puma: enable fan53555 regulators in DTS
Now that we have FAN53555 support, we can enable the regulators in our
DTS.  To make these easier to identify on the U-Boot commandline, we
rename them to the names of the voltage rails they control.

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2018-12-10 10:04:45 +01:00
Philipp Tomsich
3839431ea8 rockchip: rk3399-puma: defconfig: enable FAN53555 regulator driver
With a driver for the FAN53555 regulator family available, let's
enable it for the RK3399-Q7 (which has two of these devices
on-module).

We enable this for the full U-Boot stage only, as these regulators
provide a suitable default voltage and supply non-critical (i.e.
for booting up) power rails only.

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2018-12-10 10:04:45 +01:00
Philipp Tomsich
dfb0a70a1a power: add FAN53555 family support
This adds a driver for the FAN53555 family of regulators and wraps it
in a PMIC implementation.

While these devices support a 'normal' and 'suspend' mode (controlled
via an external pin) to switch between two programmable voltages, this
incarnation of the driver assumes that the device is always operating
in 'normal' mode.

Only setting/reading the programmed voltage is supported at this time
and the following device functionality remains unsupported:
  - switching the selected voltage (via a GPIO)
  - disabling the voltage output via software-control
This matches the functionality of the Linux driver.

Tested on a RK3399-Q7 (with 'option 5' devices): setting voltages from
the U-Boot shell and verifying output voltages on the board.

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Tested-by: Klaus Goger <klaus.goger@theobroma-systems.com>
2018-12-10 10:04:45 +01:00
Philipp Tomsich
482734aa66 bootcount: add a DM RTC backing store for bootcount
This implements a driver using a RTC-based backing store for the DM
bootcount implementation.  The node configuring this feature will be
compatible with 'u-boot,bootcount-rtc' and the underlying RTC device
shall be reference through the property 'rtc'. An offset into the RTC
device's register space can be provided through the 'offset' property.

Tested on a RK3399-Q7 on a Flamingo carrier board using the SRAM area
of the carrier board's RV3029 RTC.

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2018-12-10 10:04:45 +01:00
Philipp Tomsich
ebb73de168 bootcount: add uclass for bootcount
The original bootcount methods do not provide an interface to DM and
rely on a static configuration for I2C devices (e.g. bus, chip-addr,
etc. are configured through defines statically).  On a modern system
that exposes multiple devices in a DTS-configurable way, this is less
than optimal and a interface to DM-based devices will be desirable.

This adds a simple driver that is DM-aware and configurable via DTS.
If ambiguous (i.e. multiple bootcount-devices are present) the
/chosen/u-boot,bootcount-device property can be used to select one
bootcount device.

Initially, this provides support for the following DM devices:
 * RTC devices

Signed-off-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Tested-by: Klaus Goger <klaus.goger@theobroma-systems.com>
2018-12-10 10:04:44 +01:00
Kever Yang
f338cca1d2 rockchip: rk322x: ram: enable DRAM init in SPL instead of TPL
Patch for rk322x TPL is not merged, and only SPL is available now,
enable the sdram driver in SPL first. We should update back to TPL
after TPL is enabled for rk322x.

Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2018-12-10 10:04:44 +01:00
Christoph Muellner
19f8c4dfb6 cmd: i2c: Fix help output of i2c command.
In case SYS_I2C or DM_I2C are defined, then the "i2c " prefix
of the "i2c crc32" command is missing.
This patch addresses this, so that users can't get confused
by the "crc32" command.

Without the patch we get

    => i2c help
    i2c - I2C sub-system

    Usage:
    i2c bus [muxtype:muxaddr:muxchannel] - show I2C bus info
    crc32 chip address[.0, .1, .2] count - compute CRC32 checksum
    i2c dev [dev] - show or set current I2C bus
    [...]

With the patch we get

    => i2c help
    i2c - I2C sub-system

    Usage:
    i2c bus [muxtype:muxaddr:muxchannel] - show I2C bus info
    i2c crc32 chip address[.0, .1, .2] count - compute CRC32 checksum
    i2c dev [dev] - show or set current I2C bus
    ...

Signed-off-by: Christoph Muellner <christoph.muellner@theobroma-systems.com>
Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
2018-12-10 07:30:58 +01:00
Jean-Jacques Hiblot
40ecdbc648 dra7: Allow selecting a new dtb after board detection.
The DRA7 platforms requires that the dtb used in the SPL really matches the
platform  to have the best MMC performances.
To detect the board type/version an I2C EEPROM is read. This requires that
DM is initialized before the detection. As a consequence we must reset the
DM after the board detection is a new dtb would better match the platform.

Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
2018-12-10 07:27:25 +01:00