platform/kernel/u-boot.git
3 years agoMerge https://source.denx.de/u-boot/custodians/u-boot-marvell
Tom Rini [Tue, 6 Apr 2021 12:37:06 +0000 (08:37 -0400)]
Merge https://source.denx.de/u-boot/custodians/u-boot-marvell

- Enhance WDT handling (starting / stopping) and introduce
  CONFIG_WATCHDOG_AUTOSTART to allow disabling of autostart of
  the WDT (Pali)

3 years agoMerge https://source.denx.de/u-boot/custodians/u-boot-cfi-flash
Tom Rini [Tue, 6 Apr 2021 12:36:49 +0000 (08:36 -0400)]
Merge https://source.denx.de/u-boot/custodians/u-boot-cfi-flash

- Fix detection of 8-bit bus flash devices via address shift

3 years agoMerge tag 'dm-pull-6apr21' of https://source.denx.de/u-boot/custodians/u-boot-dm
Tom Rini [Tue, 6 Apr 2021 12:36:11 +0000 (08:36 -0400)]
Merge tag 'dm-pull-6apr21' of https://source.denx.de/u-boot/custodians/u-boot-dm

ENOSYS clean-up
Minor dtoc improvements
Convert CONFIG_MISC_INIT_F to Kconfig
Allow unit tests to run on any board
pylibfdt build-rule fix

3 years agoarm: mvebu: Espressobin: Enable watchdog support but do not start it
Pali Rohár [Tue, 9 Mar 2021 13:26:57 +0000 (14:26 +0100)]
arm: mvebu: Espressobin: Enable watchdog support but do not start it

Espressobin had disabled watchdog support (CONFIG_WDT) because older stable
Linux kernel versions (which are used by current stable OpenWRT and Debian
versions) do not have support for Armada 3700 watchdog driver. Therefore
they are not able to periodically kick watchdog so Espressobin enter into
boot loop.

This change enable CONFIG_WDT, CONFIG_WDT_ARMADA_37XX and CONFIG_CMD_WDT
options which add support for U-Boot 'wdt' command. And unset new
CONFIG_WATCHDOG_AUTOSTART option which cause that watchdog is not
automatically started by U-Boot during init phase, like when CONFIG_WDT
option is not set at all.

So with this change, U-Boot on Espressobin would have working 'wdt' command
which can be used from boot scripts (e.g. for enabling watchdog prior new
Linux booting kernel). But default behavior of watchdog status stays
unchanged, U-Boot does not start watchdog on Espressobin during its init
phase.

Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Stefan Roese <sr@denx.de>
3 years agowatchdog: Allow to use CONFIG_WDT without starting watchdog
Pali Rohár [Tue, 9 Mar 2021 13:26:56 +0000 (14:26 +0100)]
watchdog: Allow to use CONFIG_WDT without starting watchdog

In some cases it is useful to compile support for U-Boot command 'wdt'
without starting HW watchdog in early U-Boot phase. For example when the
user want to start the watchdog only on demand by some boot script.

This change adds a new compile option WATCHDOG_AUTOSTART to control whether
U-Boot should automatically start the watchdog during init phase or not.

This option is enabled by default as it was the default behavior prior
introducing this new change. When compiling U-Boot users can decide to turn
this option off.

Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Stefan Roese <sr@denx.de>
3 years agowatchdog: Show error message when initr_watchdog() cannot start watchdog
Pali Rohár [Tue, 9 Mar 2021 13:26:55 +0000 (14:26 +0100)]
watchdog: Show error message when initr_watchdog() cannot start watchdog

Function wdt_start() may fail. So in initr_watchdog() function check return
value of wdt_start() call and print error message when watchdog starting
failed.

Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Stefan Roese <sr@denx.de>
3 years agowatchdog: Set/unset GD_FLG_WDT_READY flag in wdt_start()/wdt_stop()
Pali Rohár [Tue, 9 Mar 2021 13:26:54 +0000 (14:26 +0100)]
watchdog: Set/unset GD_FLG_WDT_READY flag in wdt_start()/wdt_stop()

Watchdog is ready after successful call of ops->start() callback in
wdt_start() function. And is stopped after successful call of ops->stop()
callback in wdt_stop function.

So move setting of GD_FLG_WDT_READY flag from initr_watchdog() function to
wdt_start() and ensure that GD_FLG_WDT_READY flag is unset in wdt_stop()
function.

This change ensures that GD_FLG_WDT_READY flag is set only when watchdog is
running. And ensures that flag is also also when watchdog was started not
only by initr_watchdog() call (e.g. by U-Boot 'wdt' command).

Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Stefan Roese <sr@denx.de>
3 years agocfi_flash: Fix detection of 8-bit bus flash devices via address shift
Jagannadha Sutradharudu Teki [Fri, 26 Feb 2021 07:51:49 +0000 (08:51 +0100)]
cfi_flash: Fix detection of 8-bit bus flash devices via address shift

We had a problem detecting 8/16bit flash devices connected only via
8bits to the SoC for quite a while. Commit 239cb9d9
[mtd: cfi_flash: Fix CFI flash driver for 8-bit bus support] finally
fixed this 8-bit bus support. But also broke some other boards using
this cfi driver. So this patch had to be reverted.

I spotted a different, simpler approach for this 8-bit bus support
on the barebox mailing list posted by
Oleksij Rempel <bug-track@fisher-privat.net>:

http://www.spinics.net/lists/u-boot-v2/msg14687.html

Here the commit text:

"
Many cfi chips support 16 and 8 bit modes. Most important
difference is use of so called "Q15/A-1" pin. In 16bit mode this
pin is used for data IO. In 8bit mode, it is an address input
which add one more least significant bit (LSB). In this case
we should shift all adresses by one:
For example 0xaa << 1 = 0x154
"

This patch now is a port of this barebox patch to U-Boot.

Along with the change w.r.t from barebox,
Some flash chips can support multiple bus widths, override the
interface width and limit it to the port width.

Tested on 16-bit Spansion flash on sequoia.
Tested 8-bit flashes like 256M29EW, 512M29EW.

Signed-off-by: Stefan Roese <sr@denx.de>
Tested-by: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Cc: Jagannadha Sutradharudu Teki <jaganna@xilinx.com>
Cc: Aaron Williams <awilliams@marvell.com>
Cc: Chandrakala Chavva <cchavva@marvell.com>
Cc: Andre Przywara <andre.przywara@arm.com>
Cc: Vignesh Raghavendra <vigneshr@ti.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Mario Six <mario.six@gdsys.cc>
Cc: York Sun <york.sun@nxp.com>
Cc: Marek Vasut <marek.vasut+renesas@gmail.com>
3 years agotest: Allow tests to run on any board
Simon Glass [Wed, 24 Mar 2021 21:44:33 +0000 (10:44 +1300)]
test: Allow tests to run on any board

Due to a recent change, tests are limited to running on sandbox only.
Correct this so that any architecture can run them.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reported-by: Sean Anderson <seanga2@gmail.com>
Fixes: c79705ea938 ("test: Move dm_test_init() into test-main.c")
Tested-by: Sean Anderson <seanga2@gmail.com>
3 years agosandbox: document parameters of os_realloc()
Heinrich Schuchardt [Sun, 28 Mar 2021 09:05:00 +0000 (11:05 +0200)]
sandbox: document parameters of os_realloc()

Avoid 'make htmldocs' build warnings:

    ./include/os.h:139: warning:
    Function parameter or member 'ptr' not described in 'os_realloc'
    ./include/os.h:139: warning:
    Function parameter or member 'length' not described in 'os_realloc'

Fixes: 14e46dfb176b ("sandbox: Add os_realloc()")
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
3 years agoConvert CONFIG_MISC_INIT_F to Kconfig
Simon Glass [Fri, 26 Mar 2021 03:17:30 +0000 (16:17 +1300)]
Convert CONFIG_MISC_INIT_F to Kconfig

This converts the following to Kconfig:
   CONFIG_MISC_INIT_F

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Stefan Roese <sr@denx.de>
3 years agomoveconfig: Handle binary files cleanly
Simon Glass [Fri, 26 Mar 2021 03:17:29 +0000 (16:17 +1300)]
moveconfig: Handle binary files cleanly

Some files are not actually source code and thus can produce unicode
errors. Report this and continue.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agolog: Fix up debug_cond() when LOG is enabled
Simon Glass [Fri, 26 Mar 2021 03:17:28 +0000 (16:17 +1300)]
log: Fix up debug_cond() when LOG is enabled

At present debug() statements can cause debuf output to appear when LOG is
enabled but DEBUG is not. This is not intended and it seems that the
condition is wrong.

Fix it.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agodtoc: Improve handling of reg properties
Simon Glass [Fri, 26 Mar 2021 03:17:27 +0000 (16:17 +1300)]
dtoc: Improve handling of reg properties

This existing code assumes that a reg property is larger than one cell,
but this is not always the case. Fix this assumption.

Also if a node's parent is missing the #address-cells and #size-cells
properties we use 2 as a default for each. But this should not happen in
practice. More likely the properties were removed for SPL due to there
being no 'u-boot,dm-pre-reloc' property, or similar. Add a warning for
this as the failure can be very confusing.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agodtoc: Adjust detection of 64-bit properties
Simon Glass [Fri, 26 Mar 2021 03:17:26 +0000 (16:17 +1300)]
dtoc: Adjust detection of 64-bit properties

At present an empty size is considered to be a 64-bit value. This does not
seem useful and wastes space. Limit the 64-bit detection to where one or
both of the addr/size is two cells or more.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agodtoc: Show driver warnings once at the end
Simon Glass [Fri, 26 Mar 2021 03:17:25 +0000 (16:17 +1300)]
dtoc: Show driver warnings once at the end

At present warnings are shown as soon as they are discovered in the
source scannner. But the function that detects them may be called multiple
times.

Collect all the warnings and show them at the end.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agobuildman: Add an encoding to the out-env file
Simon Glass [Fri, 26 Mar 2021 01:39:39 +0000 (14:39 +1300)]
buildman: Add an encoding to the out-env file

The environment may contain some unicode characters. At least that is what
seemed to happen on one commit:

Building current source for 1 boards (0 threads, 64 jobs per thread)
    0    0    0 /1       -1      (starting)
Traceback (most recent call last):
  File ".../tools/buildman/buildman", line 64, in <module>
    ret_code = control.DoBuildman(options, args)
  File "tools/buildman/control.py", line 372, in DoBuildman
    options.keep_outputs, options.verbose)
  File ".../tools/buildman/builder.py", line 1704, in BuildBoards
    results = self._single_builder.RunJob(job)
  File ".../tools/buildman/builderthread.py", line 526, in RunJob
    self._WriteResult(result, job.keep_outputs, job.work_in_output)
  File ".../tools//buildman/builderthread.py", line 349, in _WriteResult
    print('%s="%s"' % (var, env[var]), file=fd)
UnicodeEncodeError: 'ascii' codec can't encode characters in position
311-312: ordinal not in range(128)

The problem defies repetition with any change at all to buildman. But
let's set an encoding in any case.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agopinctrl: Return -ENOSYS when system call is not available
Simon Glass [Wed, 24 Mar 2021 21:26:11 +0000 (10:26 +1300)]
pinctrl: Return -ENOSYS when system call is not available

Update the code to use -ENOSYS, which is the correct error code for an
unimplemented system call in U-Boot.

Also we should not check for a missing operations array as this is not
permitted. For now this can be covered by an assert().

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agosimple-pm-bus: Use -ENOSYS for checking missing system call
Simon Glass [Wed, 24 Mar 2021 21:26:10 +0000 (10:26 +1300)]
simple-pm-bus: Use -ENOSYS for checking missing system call

We don't need to check -ENOTSUPP since this is not used for this purpose
in U-Boot. Update the code accordingly.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Sean Anderson <seanga2@gmail.com>
3 years agoclk: Return -ENOSYS when system call is not available
Simon Glass [Wed, 24 Mar 2021 21:26:09 +0000 (10:26 +1300)]
clk: Return -ENOSYS when system call is not available

Update clk_composite_set_parent() to use -ENOSYS, which is the correct
error code for U-Boot. Also rearrange the code so that the error condition
is clearly indicated and the function runs to the end in the normal case,
since this is the common style in U-Boot.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Sean Anderson <seanga2@gmail.com>
3 years agoclk: Update drivers to use -EINVAL
Simon Glass [Wed, 24 Mar 2021 21:26:08 +0000 (10:26 +1300)]
clk: Update drivers to use -EINVAL

At present some drivers use -ENOSUPP to indicate that an unknown or
unsupported clock is used. Most use -EINVAL, indicating an invalid value,
so convert everything to that.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Sean Anderson <seanga2@gmail.com>
Reviewed-by: Stefan Roese <sr@denx.de>
3 years agotlv_eeprom: Return -ENOSYS when system call is not available
Simon Glass [Wed, 24 Mar 2021 21:26:07 +0000 (10:26 +1300)]
tlv_eeprom: Return -ENOSYS when system call is not available

When CMD_TLV_EEPROM is not enabled, use -ENOSYS, which is the correct
error code for U-Boot.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agospi: Return -ENOSYS when system call is not available
Simon Glass [Wed, 24 Mar 2021 21:26:06 +0000 (10:26 +1300)]
spi: Return -ENOSYS when system call is not available

Update spi_controller_dma_map_mem_op_data() to use -ENOSYS, which is the
correct error code for U-Boot.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agousb: Return -ENOSYS when system call is not available
Simon Glass [Wed, 24 Mar 2021 21:26:05 +0000 (10:26 +1300)]
usb: Return -ENOSYS when system call is not available

Update usb_gadget_release() to use -ENOSYS, which is the correct error
code for U-Boot.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agodm: core: Use -ENOSPC in acpi_get_path()
Simon Glass [Wed, 24 Mar 2021 21:26:04 +0000 (10:26 +1300)]
dm: core: Use -ENOSPC in acpi_get_path()

Update this function to use -ENOSPC which is more commly used when a buffer
runs out of space.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agodm: core: Document the common error codes
Simon Glass [Wed, 24 Mar 2021 21:26:03 +0000 (10:26 +1300)]
dm: core: Document the common error codes

Driver model uses quite strong conventions on error codes, but these are
currently not clearly documented. Add a description of the commonly used
errors.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Sean Anderson <seanga2@gmail.com>
3 years agopatman: Continue on if warnings are found outside a commit
Simon Glass [Mon, 22 Mar 2021 05:01:42 +0000 (18:01 +1300)]
patman: Continue on if warnings are found outside a commit

While we cannot know which commit the warning relates to, this should not
be fatal. Print the warning and carry on.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agodtc: Update the build rule for pylibfdt
Simon Glass [Sat, 27 Mar 2021 22:27:18 +0000 (11:27 +1300)]
dtc: Update the build rule for pylibfdt

Some versions of make complain about using a grouped target without a
recipe:

.../pylibfdt/Makefile:36: *** grouped targets must provide a recipe.  Stop.

Fix this by adding a dummy recipe.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMerge tag 'rockchip-for-v2021.07' of https://source.denx.de/u-boot/custodians/u-boot...
Tom Rini [Tue, 6 Apr 2021 02:39:10 +0000 (22:39 -0400)]
Merge tag 'rockchip-for-v2021.07' of https://source.denx.de/u-boot/custodians/u-boot-rockchip

- Fix rk3368 lion board support;
- Fix px30 odroid-go2 board support;
- Add rk3399 NanoPi R4s and NanoPi M4B board support;

3 years agoMerge branch 'next'
Tom Rini [Mon, 5 Apr 2021 15:29:57 +0000 (11:29 -0400)]
Merge branch 'next'

3 years agoPrepare v2021.04
Tom Rini [Mon, 5 Apr 2021 15:03:29 +0000 (11:03 -0400)]
Prepare v2021.04

Signed-off-by: Tom Rini <trini@konsulko.com>
3 years agoimx8mn_ddr4_evk: Allow booting the kernel by default
Fabio Estevam [Thu, 4 Mar 2021 11:07:16 +0000 (08:07 -0300)]
imx8mn_ddr4_evk: Allow booting the kernel by default

Currently it is not possible to boot Linux from the SD card
by default.

Make the necessary adjustments to allow it.

Reported-by: Peter Bergin <peter@berginkonsult.se>
Signed-off-by: Fabio Estevam <festevam@gmail.com>
Tested-by: Andrey Zhizhikin <andrey.z@gmail.com> # imx8mn_ddr4_evk
Reviewed-by: Peng Fan <peng.fan@nxp.com>
3 years agosphinx: Pin to docutils-0.16
Tom Rini [Sun, 4 Apr 2021 20:04:56 +0000 (16:04 -0400)]
sphinx: Pin to docutils-0.16

In newer docutils writers/latex2e/docutils.sty has a unicode character
in the comments which can in turn cause Python 3.6 at least to fail.
Pin to the previous docutils release for now.

Cc: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Tom Rini <trini@konsulko.com>
3 years agocmd: CMD_USB depends on USB
Heinrich Schuchardt [Sun, 4 Apr 2021 13:35:07 +0000 (13:35 +0000)]
cmd: CMD_USB depends on USB

The usb command cannot be compiled with CONFIG_USB=n:

ld.bfd: cmd/usb.c:660: undefined reference to `usb_stop'
ld.bfd: cmd/usb.c:663: undefined reference to `usb_started'

Reviewed-by: Marek Vasut <marex@denx.de>
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
3 years agoMakefile: Silence the deprecation script
Simon Glass [Wed, 31 Mar 2021 22:18:13 +0000 (11:18 +1300)]
Makefile: Silence the deprecation script

This bash code is currently showing up in the build unless 'make -s' is
used. We don't normally show these sorts of things as they are confusing.
Also this code was not shown before the recent refactoring of how these
messages are displayed.

Add an '@' to silence it.

Suggested-by: Tom Rini <trini@konsulko.com>
Signed-off-by: Simon Glass <sjg@chromium.org>
Reported-by: Bin Meng <bmeng.cn@gmail.com>
Fixes: 13732528516 ("Makefile: Add common code to report deprecation")

3 years agoMerge tag 'efi-2021-04-rc6' of https://source.denx.de/u-boot/custodians/u-boot-efi
Tom Rini [Wed, 31 Mar 2021 17:05:57 +0000 (13:05 -0400)]
Merge tag 'efi-2021-04-rc6' of https://source.denx.de/u-boot/custodians/u-boot-efi

Pull request for efi-2021-04-rc6

Bug fix:
    Fix ConvertDeviceNodeToText() for Uart()

3 years agoMerge tag 'xilinx-for-v2021.07' of https://source.denx.de/u-boot/custodians/u-boot...
Tom Rini [Wed, 31 Mar 2021 13:47:30 +0000 (09:47 -0400)]
Merge tag 'xilinx-for-v2021.07' of https://source.denx.de/u-boot/custodians/u-boot-microblaze into next

Xilinx changes for v2021.07

net:
- Fix gem PCS support

spi:
- Small trivial fixes

zynq:
- Enable time/timer commands
- Update bitmain platform
- Several DT changes

zynqmp:
- Update clock driver
- mini config alignments
- Add/update psu_init for zcu208/zcu216/zc1275
- Several DT changes
- Enable efi debug command (also for Versal)

3 years agotest: Don't unmount not (yet) mounted system
Andy Shevchenko [Thu, 11 Feb 2021 14:40:12 +0000 (16:40 +0200)]
test: Don't unmount not (yet) mounted system

When test suite tries to create a file for a new filesystem test case and fails,
the clean up of the exception tries to unmount the image, that has not yet been
mounted. When it happens, the fuse_mounted global variable is set to False and
inconveniently the test case tries to use sudo, so without this change the
admin of the machine gets an (annoying) email:

  Subject: *** SECURITY information for example.com ***

  example.com : Feb  5 19:43:47 : ... COMMAND=/bin/umount .../build-sandbox/persistent-data/mnt

and second run of the test cases on uncleaned build folder will ask for sudo
which is not what expected.

Besides that there is a double unmount calls during successfully run test case.

All of these due to over engineered Python try-except clause and people didn't
get it properly at all. The rule of thumb is that don't use more keywords than
try-except in the exception handling code. Nevertheless, here we adjust code
to be less intrusive to the initial logic behind that complex and unclear
constructions in the test case, although it adds a lot of lines of the code,
i.e. splits one exception handler to three, so on each step we know what
cleanup shall perform.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
3 years agoMerge https://source.denx.de/u-boot/custodians/u-boot-sunxi
Tom Rini [Wed, 31 Mar 2021 11:48:47 +0000 (07:48 -0400)]
Merge https://source.denx.de/u-boot/custodians/u-boot-sunxi

- H616 fixes to keep it in sync with upstream TF-A

3 years agosunxi: dts: H616: Drop reserved-memory node
Andre Przywara [Thu, 25 Mar 2021 16:19:52 +0000 (16:19 +0000)]
sunxi: dts: H616: Drop reserved-memory node

Trusted Firmware now adds the /reserved-memory subnode to the DT at
runtime[1], putting in the right values.

Drop our hard-coded version, as this might clash with the actual values
(which have also changed), and rely on TF-A to add the node.

[1] https://review.trustedfirmware.org/c/TF-A/trusted-firmware-a/+/7770

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Samuel Holland <samuel@sholland.org>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
3 years agosunxi: H616: Change TF-A load address to beginning of DRAM
Andre Przywara [Thu, 25 Mar 2021 16:20:13 +0000 (16:20 +0000)]
sunxi: H616: Change TF-A load address to beginning of DRAM

Loading Trusted-Firmware's BL31 at 16KB into DRAM was originally a hack
to allow sharing more code with the other SoCs (which use this offset
in SRAM). However there is no longer a reason for that, as the
problematic macros have been properly separated there.

The latest (and hopefully final) TF-A code drop now changes the load
address to the beginning of DRAM, which is also more easily protected
by the Trustzone memory controller (code to be done).

Adjust the load address of BL31 now, to avoid any issues with
incompatible versions later on (the TF-A patches are about to be merged).

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Samuel Holland <samuel@sholland.org>
3 years agoefi_loader: typo 'devide path'
Heinrich Schuchardt [Wed, 31 Mar 2021 06:34:33 +0000 (06:34 +0000)]
efi_loader: typo 'devide path'

Fix a typo in helloworld.efi.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
3 years agoefi_loader: Uart device path missing break
Heinrich Schuchardt [Wed, 31 Mar 2021 06:16:04 +0000 (08:16 +0200)]
efi_loader: Uart device path missing break

In the devicepath node to text conversion for Uart nodes a break statement
is missing.

Indicated by Coverity Scan CID 330038
Fixes: 62df6e9c9994 ("efi_loader: Uart device path")
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
3 years agoMerge tag 'u-boot-atmel-2021.07-a' of https://source.denx.de/u-boot/custodians/u...
Tom Rini [Tue, 30 Mar 2021 15:24:09 +0000 (11:24 -0400)]
Merge tag 'u-boot-atmel-2021.07-a' of https://source.denx.de/u-boot/custodians/u-boot-atmel into next

First set of u-boot-atmel features for 2021.07 cycle:
This small feature set includes the implementation of the slew rate for
the PIO4 pin controller device, and a fix for arm926ejs-based
microprocessors that avoids a crash.

3 years agoxilinx: Enable efi debug command
Michal Simek [Fri, 26 Mar 2021 10:16:24 +0000 (11:16 +0100)]
xilinx: Enable efi debug command

Enable EFI debug command to be able to setup various efi variables to avoid
software like grub.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoARM: bitmain: Enable saving variables to SD card
Michal Simek [Mon, 22 Mar 2021 14:43:46 +0000 (15:43 +0100)]
ARM: bitmain: Enable saving variables to SD card

Board has NAND and SD interfaces which can be used for saving variables
too.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoARM: bitmain: Enable legacy u-boot format
Michal Simek [Mon, 22 Mar 2021 14:42:02 +0000 (15:42 +0100)]
ARM: bitmain: Enable legacy u-boot format

Still legacy formats are used that's why enable them by default.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoARM: bitmain: Enable nand and smcc drivers
Michal Simek [Thu, 18 Mar 2021 15:04:44 +0000 (16:04 +0100)]
ARM: bitmain: Enable nand and smcc drivers

Enable nand and smcc via DT.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agospi: xilinx_spi: Trivial fixes in axi qspi driver
T Karthik Reddy [Wed, 17 Mar 2021 07:01:50 +0000 (01:01 -0600)]
spi: xilinx_spi: Trivial fixes in axi qspi driver

Use __func__ instead for function name in debug.
Use Linux style u32 instead of uint32_t.

Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
Acked-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoxilinx: Sync DTs with Linux kernel
Michal Simek [Thu, 26 Nov 2020 13:25:02 +0000 (14:25 +0100)]
xilinx: Sync DTs with Linux kernel

There are several changes which happen in mainline kernel which should get
also to U-Boot. Here is the list of patches from the kernel:

- ARM: zynq: Fix leds subnode name for zc702/zybo-z7
- arm64: dts: zynqmp: Fix leds subnode name for zcu100/ultra96 v1
- arm64: dts: zynqmp: Fix u48 si5382 chip on zcu111
- arm64: dts: zynqmp: Wire up the DisplayPort subsystem
- arm64: dts: zynqmp: Add DisplayPort subsystem
- arm64: dts: zynqmp: Add DPDMA node
- arm64: dts: zynqmp: Enable phy driver for Sata on zcu102/zcu104/zcu106
- arm64: dts: zynqmp: Enable si5341 driver for zcu102/106/111
- arm64: dts: zynqmp: Add DT description for si5328 for zcu102/zcu106
- arm64: dts: zynqmp-zcu100-revC: correct interrupt flags
- arm64: dts: xilinx: align GPIO hog names with dtschema
- arm64: zynqmp: Add Xilinx AES node
- dt: bindings: dma: xilinx: dpdma: DT bindings for Xilinx DPDMA

but also some other changes have been done.
- Using only one compatible string for adxl345 on zturn
- Remove Xilinx internal DP bindings
- Remove USB3.0 serdes configurations
- Remove SATA serdes configuration for zc1232
- Resort nvmem_firmware
- Update nand compatible string
- Aling power-domains property for sd0/1

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoclk: zynqmp: Fix clk dump values
T Karthik Reddy [Thu, 25 Feb 2021 06:44:46 +0000 (23:44 -0700)]
clk: zynqmp: Fix clk dump values

With "clk dump" command, few clocks are showing up incorrect values
and some clocks are displayed as "unknown".

Add missing clocks to zynqmp clock driver to display proper
clocks rates.

Implement a simple way to get clock source, instead of calling
functions. Change existing functions to this simple mechanism.

Fix gem clock name "gem_rx" to "gem_tx" which was incorrect.
Change dbf_fpd & dbf_lpd clk names to dbg_fpd & dbg_lpd.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
3 years agoarm64: zynqmp: Rename clocks as per the Arasan NAND driver
Amit Kumar Mahapatra [Tue, 23 Feb 2021 20:47:20 +0000 (13:47 -0700)]
arm64: zynqmp: Rename clocks as per the Arasan NAND driver

In zynqmp.dtsi file renamed "clk_sys" clock to "controller" and
"clk_flash" clock to "bus" as per upstreamed Arasan NAND driver.
This fixes NAND driver probe failure.

Signed-off-by: Amit Kumar Mahapatra <amit.kumar-mahapatra@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoarm64: zynqmp: Update device tree properties for nand flash
Amit Kumar Mahapatra [Thu, 18 Feb 2021 07:50:21 +0000 (00:50 -0700)]
arm64: zynqmp: Update device tree properties for nand flash

Update the following device tree properties for nand flash

- Set software ecc mode.
- Set bch as ecc algo.
- Set read block to 0.

Signed-off-by: Amit Kumar Mahapatra <amit.kumar-mahapatra@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoarm64: zynqmp: Update psu_init for zcu1275
Michal Simek [Wed, 17 Feb 2021 12:10:05 +0000 (13:10 +0100)]
arm64: zynqmp: Update psu_init for zcu1275

Update clock/pll setup, ddr, MIOs based on 2020.2 hw design.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoarm64: zynqmp: Add idt 8a34001 chip to zcu208/zcu216
Michal Simek [Fri, 22 Jan 2021 13:42:29 +0000 (14:42 +0100)]
arm64: zynqmp: Add idt 8a34001 chip to zcu208/zcu216

There is Linux driver for these chips that's why add it to device tree.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoarm64: zynqmp: Add missing psu inits for zcu208/216
Michal Simek [Wed, 17 Feb 2021 08:40:38 +0000 (09:40 +0100)]
arm64: zynqmp: Add missing psu inits for zcu208/216

Add missing configurations file for zcu208 and zcu216.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoarm64: zynqmp: Add emmc specific parameters
Ashok Reddy Soma [Tue, 16 Feb 2021 14:02:14 +0000 (07:02 -0700)]
arm64: zynqmp: Add emmc specific parameters

EMMC will have bus-width 8 and it is non-removable in general. These
are missing from dt node. Add bus-width and non-removable parameters
to emmc node.

Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoarm64: zynqmp: Increase size of malloc pool
Ashok Reddy Soma [Tue, 16 Feb 2021 14:02:13 +0000 (07:02 -0700)]
arm64: zynqmp: Increase size of malloc pool

size of malloc() pool for use before relocation is not sufficient
for ZynqMP mini u-boot with emmc configuration. Increase it to 4K.

Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoxilinx: zynq: Enable time and timer commands
Ashok Reddy Soma [Thu, 4 Feb 2021 07:39:01 +0000 (00:39 -0700)]
xilinx: zynq: Enable time and timer commands

Enable time command to get the elapsed time and timer commands.

Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoboard: dts: rockchip: Add NanoPi M4B
Alexandre Vicenzi [Fri, 26 Mar 2021 12:37:10 +0000 (13:37 +0100)]
board: dts: rockchip: Add NanoPi M4B

Add initial support for NanoPi M4B, a minor revision of
the original NanoPi M4.

Commit details of rk3399-nanopi-m4b.dts sync from Linux 5.12-rc4:
"arm64: dts: rockchip: Add NanoPi M4B board"
(sha1: c7b03115003f7f337ab165542cee37148cf30a8a)

Signed-off-by: Alexandre Vicenzi <alexandre.vicenzi@suse.com>
Reviewed-by: Kever Yang <kever.yang@rock-cihps.com>
3 years agoarm64: rk3399: Add support NanoPi R4s
Xiaobo Tian [Sat, 27 Feb 2021 14:39:11 +0000 (22:39 +0800)]
arm64: rk3399: Add support NanoPi R4s

NanoPi R4s is SBC base on Rockchip RK3399 hexa-core processor with
dual-Core Cortex-A72 and Mali-T864 GPU with 4GiB(LPDDR4) of RAM, SD card support,
including 2 gigabit ethernet(RTL8211E 1Gbps - RTL8111H 1Gbps) and 2 USB 3.0 port.
port.It also has two GPIO headers which allows further peripherals to be used.

The devicetree file is taken of the rk3399 nanopi4 Linux kernel [1].

[1] https://github.com/torvalds/linux/commit/e7a095908227fb3ccc86d001d9e13c9ae2bef8e6

Signed-off-by: xiaobo <peterwillcn@gmail.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agoodroid-go2: fix default FDT file path
Roger Pau Monné [Mon, 22 Feb 2021 09:25:59 +0000 (10:25 +0100)]
odroid-go2: fix default FDT file path

The path in the Linux kernel dts directory is
rockchip/rk3326-odroid-go2.dtb.

That also seems to match the FDT path set on other boards (ie:
rock64-rk3328 for example).

Signed-off-by: Roger Pau Monne <royger@FreeBSD.org>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agoodroid-go2: do not disable EFI
Roger Pau Monné [Mon, 22 Feb 2021 09:25:58 +0000 (10:25 +0100)]
odroid-go2: do not disable EFI

Remove the unset of the EFI loader, it's possible for U-Boot to
provide a EFI environment on this board, and it's also required by
the FreeBSD loader which mandated EFI on Aarch64.

Signed-off-by: Roger Pau Monné <royger@FreeBSD.org>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3399-puma: Increase environment size to 16 kiB.
Christoph Muellner [Fri, 19 Feb 2021 00:30:02 +0000 (01:30 +0100)]
rockchip: rk3399-puma: Increase environment size to 16 kiB.

On Puma we have the environment at an offset of 16 kiB.
On the eMMC this gives us 16 kiB for the environment before the SPL starts.
On the SPI NOR we also have 16 kiB until end of flash.
So let's increase the environment size from 8 kiB to its maximum
of 16 kiB for both MMC and SPI NOR.

Signed-off-by: Christoph Muellner <christoph.muellner@theobroma-systems.com>
Reviewed-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3399-puma: Restore correct VDD_LOG supply.
Christoph Muellner [Fri, 19 Feb 2021 00:29:48 +0000 (01:29 +0100)]
rockchip: rk3399-puma: Restore correct VDD_LOG supply.

A commit from last year re-imported the DTS files form the upstream kernel.
By doing so the VDD_LOG regulator in the board's DTS was dropped.
Let's restore this, but move it into the u-boot overlay to prevent this
issue in the future.

Fixes: 167efc2c7a46 ("arm64: dts: rk3399: Sync v5.7-rc1 from Linux")
Signed-off-by: Christoph Muellner <christoph.muellner@theobroma-systems.com>
Reviewed-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3399: rock960: explicitly disable SPI flash
Peter Robinson [Sun, 14 Feb 2021 19:43:28 +0000 (19:43 +0000)]
rockchip: rk3399: rock960: explicitly disable SPI flash

The Rock960 doesn't have SPI flash on-board, but the bits
get enabled by default which means when booting we get
some errors. Explicitly disable it to stop the errors.

Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agoinclude: configs: rk3399: drop a dangling comment
Peter Robinson [Sun, 14 Feb 2021 19:40:15 +0000 (19:40 +0000)]
include: configs: rk3399: drop a dangling comment

Drop a irrelevent comment now the related configs have moved
to the various config files.

Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: lion: update board defconfig
Heiko Stuebner [Tue, 9 Feb 2021 13:47:10 +0000 (14:47 +0100)]
rockchip: lion: update board defconfig

Adds the needed target option and drivers needed for correct
bringup.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3368: sync down rk3368-lion board devicetree from Linux
Heiko Stuebner [Tue, 9 Feb 2021 13:47:09 +0000 (14:47 +0100)]
rockchip: rk3368: sync down rk3368-lion board devicetree from Linux

This brings the actual rk3368-lion devicetree files from Linux 5.10
instead of using something separate.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3368: sync main rk3368 dtsi from Linux
Heiko Stuebner [Tue, 9 Feb 2021 13:47:08 +0000 (14:47 +0100)]
rockchip: rk3368: sync main rk3368 dtsi from Linux

This is the state as of v5.10 + the recently added timer0 phandle
targetted at the 5.12 merge window.

With this the non-mainline nodes like the dmc move to a separate
rk3368-u-boot.dtsi that is included from the board-specific
-u-boot.dtsi files, similar to how rk3399 does this.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3368: sync clock dt-binding header from Linux
Heiko Stuebner [Tue, 9 Feb 2021 13:47:07 +0000 (14:47 +0100)]
rockchip: rk3368: sync clock dt-binding header from Linux

This is the state as of v5.10 in Linux.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3368: move STACK_R_ADDR address and into Kconfig
Heiko Stuebner [Tue, 9 Feb 2021 13:47:06 +0000 (14:47 +0100)]
rockchip: rk3368: move STACK_R_ADDR address and into Kconfig

With the STACK_R_ADDR at 0x600000 (6MB) we're competing with
with the loading address of either u-boot or atf parts, so move
that away to 0x4000000 (64MB) similar to rk3399.

Only lion currently sets that at all but not sheep the second
rk3368 board, so just move that to the Kconfig for rk3368 similar
to rk3399 as well.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3368: increase SYS_MALLOC_F_LEN to 0x4000
Heiko Stuebner [Tue, 9 Feb 2021 13:47:05 +0000 (14:47 +0100)]
rockchip: rk3368: increase SYS_MALLOC_F_LEN to 0x4000

To prevent running out of memory, increase SYS_MALLOC_F_LEN to 0x4000
similar to what rk3399 uses.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3368: set CONFIG_SYS_BOOTM_LEN to 64MB
Heiko Stuebner [Tue, 9 Feb 2021 13:47:04 +0000 (14:47 +0100)]
rockchip: rk3368: set CONFIG_SYS_BOOTM_LEN to 64MB

Mimicing for example the rk3399, set the SYS_BOOTM_LEN to 64MB so
that regular kernel images can get loaded without problems.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agorockchip: rk3368: adjust CONFIG_SYS_LOAD_ADDR
Heiko Stuebner [Tue, 9 Feb 2021 13:47:03 +0000 (14:47 +0100)]
rockchip: rk3368: adjust CONFIG_SYS_LOAD_ADDR

CONFIG_SYS_LOAD_ADDR currently is at 0x00280000 which is only 512KB
behind the area where we load u-boot to, which depending on u-boot size
may overlap at some point.

So for safety just pick the same value rk3399 has and set
CONFIG_SYS_LOAD_ADDR to 0x00800800 on rk3368 as well.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agoodroid-go2: remove setting SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR
Roger Pau Monné [Sat, 13 Feb 2021 15:59:01 +0000 (16:59 +0100)]
odroid-go2: remove setting SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR

Using a non-default SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR setting makes the
resulting u-boot-rockchip.bin unbootable, as it gets stuck after SPL.
Removing the setting from the defconfig allows U-Boot to load
successfully.

Signed-off-by: Roger Pau Monné <royger@FreeBSD.org>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
3 years agonet: gem: Fix setting PCS auto-negotiation state
Robert Hancock [Thu, 11 Mar 2021 22:55:50 +0000 (16:55 -0600)]
net: gem: Fix setting PCS auto-negotiation state

The code was trying to disable PCS auto-negotiation when a fixed-link node
is present and enable it otherwise. However, the PCS registers were being
written before the PCSSEL bit was set in the network configuration
register, and it appears that in this state, PCS register writes are
ignored. The result is that the intended change only took effect on the
second network operation that was performed, since at that time PCSSEL is
already enabled.

Fix the order of register writes so that PCS registers are only written to
after the PCS is enabled.

Fixes: 26e62cc971 ("net: gem: Disable PCS autonegotiation in case of fixed-link")
Signed-off-by: Robert Hancock <robert.hancock@calian.com>
Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
Reviewed-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
3 years agoMerge tag 'v2021.04-rc5' into next
Tom Rini [Mon, 29 Mar 2021 21:53:19 +0000 (17:53 -0400)]
Merge tag 'v2021.04-rc5' into next

Prepare v2021.04-rc5

3 years agoPrepare v2021.04-rc5
Tom Rini [Mon, 29 Mar 2021 21:20:13 +0000 (17:20 -0400)]
Prepare v2021.04-rc5

Signed-off-by: Tom Rini <trini@konsulko.com>
3 years agoMerge tag 'dm-pull-28mar21' of git://git.denx.de/u-boot-dm into next
Tom Rini [Mon, 29 Mar 2021 00:29:39 +0000 (20:29 -0400)]
Merge tag 'dm-pull-28mar21' of git://git.denx.de/u-boot-dm into next

binman support for expanding entries, connections
misc fixes and improvements to sandbox, etc.
x86 CBFS improvements
x86 coreboot improvements

3 years agoMerge branch '2021-03-28-assorted-bugfixes'
Tom Rini [Mon, 29 Mar 2021 00:28:51 +0000 (20:28 -0400)]
Merge branch '2021-03-28-assorted-bugfixes'

3 years agoSupport building on macOS/arm64
Jessica Clarke [Sat, 20 Mar 2021 20:43:05 +0000 (20:43 +0000)]
Support building on macOS/arm64

On Arm-based Macs, -no_pie is ignored and gives a linker warning.
Moreover, the build falls over with:

  ld: Absolute addressing not allowed in arm64 code but used in '_image_type_ptr_aisimage' referencing '_image_type_aisimage'

for dumpimage and mkimage, since we put data structs in text sections
not data sections and so cannot have dynamic relocations. Instead, move
the sections to __DATA and drop disabling PIE.

Signed-off-by: Jessica Clarke <jrtc27@jrtc27.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
3 years agodm: test: Always include command.h for print_ut
Sean Anderson [Fri, 26 Mar 2021 02:02:28 +0000 (22:02 -0400)]
dm: test: Always include command.h for print_ut

We need this header for U_BOOT_CMD, which is always present even without
EFI.

Fixes: 82c468a049 ("dm: test: Update Makefile conditions")

Signed-off-by: Sean Anderson <seanga2@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
3 years agotest: Add udevice declaration to avoid build error
Simon Glass [Sat, 27 Mar 2021 17:53:08 +0000 (06:53 +1300)]
test: Add udevice declaration to avoid build error

When including this file on a board other than sandbox (e.g by enabling
UNIT_TEST and CMD_SETEXPR) an results. Fix it by declaring struct udevice
first.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
3 years agoMerge branch '2021-03-27-master-imports'
Tom Rini [Sat, 27 Mar 2021 15:58:37 +0000 (11:58 -0400)]
Merge branch '2021-03-27-master-imports'

- Rework the deprecation warnings to be consistently phrased.
- Add in a warning for DM_I2C, for a year from next release.
- Fix Azure builds of Windows host tools.

3 years agoAzure: Use "pacman -Sy" to install the toolchain
Tom Rini [Fri, 26 Mar 2021 19:14:14 +0000 (15:14 -0400)]
Azure: Use "pacman -Sy" to install the toolchain

We now see an error such as:
warning: database file for 'ucrt64' does not exist (use '-Sy' to download)
error: failed to prepare transaction (could not find database)

So use -Sy as suggested.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
3 years agodm: i2c: Add a migration method for I2C
Simon Glass [Thu, 25 Mar 2021 08:24:44 +0000 (21:24 +1300)]
dm: i2c: Add a migration method for I2C

This probably should have been done a while back since it is a core
system. Add a migration deadline of later this year, to catch the
stragglers.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Drop the old SPI flash migration message
Simon Glass [Thu, 25 Mar 2021 08:24:43 +0000 (21:24 +1300)]
Makefile: Drop the old SPI flash migration message

This message does not seem to make sense. It may be out of date. Drop it.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Use common code for DM_ETH deprecation warning
Simon Glass [Thu, 25 Mar 2021 08:24:42 +0000 (21:24 +1300)]
Makefile: Use common code for DM_ETH deprecation warning

Update the CONFIG_DM_ETH check to use the 'deprecated' function.

Tested with snow

Old message:

===================== WARNING ======================
This board does not use CONFIG_DM_ETH (Driver Model
for Ethernet drivers). Please update the board to use
CONFIG_DM_ETH before the v2020.07 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

New message:

===================== WARNING ======================
This board does not use CONFIG_DM_ETH (Driver Model
for Ethernet drivers). Please update the board to use
CONFIG_DM_ETH before the v2020.07 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Use common code for WDT deprecation warning
Simon Glass [Thu, 25 Mar 2021 08:24:41 +0000 (21:24 +1300)]
Makefile: Use common code for WDT deprecation warning

Update the CONFIG_WDT check to use the 'deprecated' function.

Tested with kmcent2

Old message:

===================== WARNING ======================
This board does not use CONFIG_WDT (DM watchdog support).
Please update the board to use CONFIG_WDT before the
v2019.10 release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

New message:

===================== WARNING ======================
This board does not use CONFIG_WDT (Driver Model
for DM watchdog). Please update the board to use
CONFIG_WDT before the v2019.10 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Use common code for SPI_FLASH deprecation warning
Simon Glass [Thu, 25 Mar 2021 08:24:40 +0000 (21:24 +1300)]
Makefile: Use common code for SPI_FLASH deprecation warning

Update the CONFIG_DM_SPI_FLASH check to use the 'deprecated' function.

Tested with vinco

Old message:

===================== WARNING ======================
This board does not use CONFIG_DM_SPI_FLASH. Please update
the board to use CONFIG_SPI_FLASH before the v2019.07 release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

New message:

===================== WARNING ======================
This board does not use CONFIG_DM_SPI_FLASH (Driver Model
for SPI flash). Please update the board to use
CONFIG_DM_SPI_FLASH before the v2019.07 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Use common code for DM_VIDEO deprecation warning
Simon Glass [Thu, 25 Mar 2021 08:24:39 +0000 (21:24 +1300)]
Makefile: Use common code for DM_VIDEO deprecation warning

Update the CONFIG_DM_VIDEO check to use the 'deprecated' function.

Tested with pxm2

Old message:

===================== WARNING ======================
This board does not use CONFIG_DM_VIDEO Please update
the board to use CONFIG_DM_VIDEO before the v2019.07 release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

New message:

===================== WARNING ======================
This board does not use CONFIG_DM_VIDEO (Driver Model
for video). Please update the board to use
CONFIG_DM_VIDEO before the v2019.07 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
==================================================

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Use common code for PCI deprecation warning
Simon Glass [Thu, 25 Mar 2021 08:24:38 +0000 (21:24 +1300)]
Makefile: Use common code for PCI deprecation warning

Update the CONFIG_DM_PCI check to use the 'deprecated' function.

Tested with MPC8349ITX

Old message:

===================== WARNING ======================
This board does not use CONFIG_DM_PCI Please update
the board to use CONFIG_DM_PCI before the v2019.07 release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

New message:

===================== WARNING ======================
This board does not use CONFIG_DM_PCI (Driver Model
for PCI). Please update the board to use
CONFIG_DM_PCI before the v2019.07 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Use common code for LIBATA deprecation warning
Simon Glass [Thu, 25 Mar 2021 08:24:37 +0000 (21:24 +1300)]
Makefile: Use common code for LIBATA deprecation warning

Update the CONFIG_LIBATA check to use the 'deprecated' function.

Tested with MPC8349ITX

Old message:

===================== WARNING ======================
This board does use CONFIG_LIBATA but has CONFIG_AHCI not
enabled. Please update the storage controller driver to use
CONFIG_AHCI before the v2019.07 release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

New message:

===================== WARNING ======================
This board does not use CONFIG_AHCI (Driver Model
for AHCI). Please update the board to use
CONFIG_AHCI before the v2019.07 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Use common code for MVSATA_IDE deprecation warning
Simon Glass [Thu, 25 Mar 2021 08:24:36 +0000 (21:24 +1300)]
Makefile: Use common code for MVSATA_IDE deprecation warning

Update the CONFIG_MVSATA_IDE check to use the 'deprecated' function.

Tested with nas220

Old message:

===================== WARNING ======================
This board does use CONFIG_MVSATA_IDE which is not
ported to driver-model (DM) yet. Please update the storage
controller driver to use CONFIG_AHCI before the v2019.07
release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

New message:

===================== WARNING ======================
This board does not use CONFIG_AHCI (Driver Model
for AHCI instead of CONFIG_MVSATA_IDE). Please update the board to use
CONFIG_AHCI before the v2019.07 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Use common code for USB deprecation warning
Simon Glass [Thu, 25 Mar 2021 08:24:35 +0000 (21:24 +1300)]
Makefile: Use common code for USB deprecation warning

Update the USB check to use the 'deprecated' function.

Tested with xpress

Old message:

===================== WARNING ======================
This board does not use CONFIG_DM_USB. Please update
the board to use CONFIG_DM_USB before the v2019.07 release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

New message:

===================== WARNING ======================
This board does not use CONFIG_DM_USB (Driver Model
for  USB). Please update the board to use
CONFIG_DM_USB before the v2019.07 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Use common code for MMC deprecation warning
Simon Glass [Thu, 25 Mar 2021 08:24:34 +0000 (21:24 +1300)]
Makefile: Use common code for MMC deprecation warning

Update the MMC check to use the 'deprecated' function.

Tested with zc5202

Old message:

===================== WARNING ======================
This board does not use CONFIG_DM_MMC. Please update
the board to use CONFIG_DM_MMC before the v2019.04 release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

New message:

===================== WARNING ======================
This board does not use CONFIG_DM_MMC (Driver Model
for MMC). Please update the board to use
CONFIG_DM_MMC before the v2019.04 release. Failure to
update by the deadline may result in board removal.
See doc/driver-model/migration.rst for more info.
====================================================

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Add common code to report deprecation
Simon Glass [Thu, 25 Mar 2021 08:24:33 +0000 (21:24 +1300)]
Makefile: Add common code to report deprecation

Add a function which can be called to report a migration problem. This
will make it easier to add new migration checks, since the logic and
strings are not spread out over 8 lines of code.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agoMakefile: Move non-DM migration messages to the top
Simon Glass [Thu, 25 Mar 2021 08:24:32 +0000 (21:24 +1300)]
Makefile: Move non-DM migration messages to the top

At present the driver model migration messages are mixed with the others.
Collect them together before starting to refactor them.

Signed-off-by: Simon Glass <sjg@chromium.org>
3 years agosandbox: define __dyn_sym_start, dyn_sym_end
Heinrich Schuchardt [Tue, 23 Mar 2021 11:37:47 +0000 (12:37 +0100)]
sandbox: define __dyn_sym_start, dyn_sym_end

On RISC-V the symbols __dyn_sym_start, dyn_sym_end are referenced in
efi_runtime_relocate().

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Simon Glass <sjg@chromium.org>