Neil Armstrong [Thu, 25 Feb 2021 08:44:35 +0000 (09:44 +0100)]
configs: meson: use Designware glue driver for Amlogic Meson8b & later SoCs
Use the proper Synopsys DWMAC Meson8b glue to handle the ethernet link type.
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Neil Armstrong [Thu, 25 Feb 2021 08:44:34 +0000 (09:44 +0100)]
arm: meson: remove static MDIO mux handling
The static MDIO mux handling in mach-meson is no more needed, delete it.
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Neil Armstrong [Thu, 25 Feb 2021 08:44:33 +0000 (09:44 +0100)]
configs: update Amlogic Meson G12A, G12B & SM1 configs for MDIO MUX
Use DM_MDIO and the new G12A MDIO MUX driver for G12A, G12B & SM1 boards.
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Neil Armstrong [Thu, 25 Feb 2021 08:44:32 +0000 (09:44 +0100)]
configs: update Amlogic Meson GXL & GXM config for MDIO MUX
Use DM_MDIO and the new MMIOREG MDIO MUX driver for GXL & GXM board.
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Neil Armstrong [Wed, 24 Feb 2021 19:33:56 +0000 (20:33 +0100)]
net: designware: add Amlogic Meson8b & later glue driver
This adds a proper glue driver for the Designware DWMAC ethernet MAC IP
found in the Amlogic Meson8, GXBB, GXL, GXM, G12A, G12B & SM1 SoCs.
This is aimed to replace the static ethernet link setup found on the board
init code for the Amlogic SoC based boards.
Tested on a libretech-cc (S905x Internal RMII 10/100 PHY) and Khadas VIM3 (A113d
with external 10/100/1000 RGMII PHY) to cover the most extreme setups.
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Neil Armstrong [Wed, 24 Feb 2021 16:31:53 +0000 (17:31 +0100)]
net: add Amlogic Meson G12A MDIO MUX driver
The Amlogic G12A & compatible SoCs embeds a mux to either communicate with
the external PHY or the internal 10/100 PHY.
This adds support for this mux as a MDIO MUX device.
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
Neil Armstrong [Wed, 24 Feb 2021 14:02:39 +0000 (15:02 +0100)]
net: designware: add DM_MDIO support
Add support for DM_MDIO to connect to PHY and expose a MDIO device for the
internal MDIO bus in order to dynamically connect to MDIO PHYs with DT
with eventual MDIO muxes in between.
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
Neil Armstrong [Wed, 24 Feb 2021 14:02:23 +0000 (15:02 +0100)]
net: add MMIO Register MDIO MUX driver
Add support for MMIO register MDIO muxes based on the Linux mdio-mux-mmioreg driver.
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Reviewed-by: Ramon Fried <rfried.dev@gmail.com>
Tom Rini [Mon, 5 Apr 2021 15:29:57 +0000 (11:29 -0400)]
Merge branch 'next'
Tom Rini [Mon, 5 Apr 2021 15:03:29 +0000 (11:03 -0400)]
Prepare v2021.04
Signed-off-by: Tom Rini <trini@konsulko.com>
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>
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>
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>
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")
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()
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)
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>
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
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>
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>
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>
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>
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.
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
Tom Rini [Mon, 29 Mar 2021 21:53:19 +0000 (17:53 -0400)]
Merge tag 'v2021.04-rc5' into next
Prepare 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>
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
Tom Rini [Mon, 29 Mar 2021 00:28:51 +0000 (20:28 -0400)]
Merge branch '2021-03-28-assorted-bugfixes'
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>
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>
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>
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.
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
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>
T Karthik Reddy [Wed, 17 Mar 2021 11:31:30 +0000 (12:31 +0100)]
spi: spi-uclass: Add support to manually relocate spi memory ops
Add spi memory operations to relocate manually when
CONFIG_NEEDS_MANUAL_RELOC is enabled.
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>
Reviewed-by: Pratyush Yadav <p.yadav@ti.com>
Simon Glass [Sun, 21 Mar 2021 05:24:39 +0000 (18:24 +1300)]
dtoc: Add new check that offsets are correct
Add a few more internal checks to make sure offsets are correct, before
updating the dtb.
To make this easier, update the functions which add a property to return
that property,.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:38 +0000 (18:24 +1300)]
dtoc: Support adding subnodes alongside existing ones
So far we have only needed to add subnodes to empty notds, so have not
had to deal with ordering. However this feature is needed for binman's
expanded nodes, since there may be another node in the same section.
While libfdt adds new properties after existing properties, it adds new
subnodes before existing subnodes. This means that we must reorder the
nodes in the cached version, so that the ordering remains consistent.
Update the sync implementation to sync existing subnodes first, then
add new ones, then tidy up the ordering in the cached version. Update the
test to cover this behaviour.
Also improve the comment about property syncing while we are here.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:37 +0000 (18:24 +1300)]
dtoc: Add a subnode test for multiple nodes
Add a new test that adds a subnode alongside an existing one, as well as
adding properties to a subnode. This will expand to adding multiple
subnodes in future patches. Put a node after the one we are adding to so
we can check that things sync correctly.
The testAddNode() test should be in the TestNode class since it is a node
test, so move it.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:36 +0000 (18:24 +1300)]
dtoc: Tweak ordering of fdt-offsets refreshing
Once the tree has been synced, thus potentially moving things around in the
fdt, we set _cached_offsets to False so that a refresh will happen next
time a property is accessed.
This 'lazy' refresh doesn't really save much time, since refresh is a very
fast operation, just a single walk of the tree. Also, having the refresh
happen in the bowels of property access it makes it harder to figure out
what is going on.
Simplify the code by always doing a refresh before and after a sync. Set
_cached_offsets to True immediately after this, in the Refresh() function,
since this makes more sense than doing it in the caller.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:35 +0000 (18:24 +1300)]
dtoc: Tidy up property-offset handling
If a property does not yet have an offset, then that means it exists in
the cache'd fdt but has not yet been synced back to the flat tree. Use
the dirty flag for this so we don't need to check the offset too. Improve
the comments for Prop and Node to make it clear what an offset of None
means.
Also clear the dirty flag after the property is synced.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:34 +0000 (18:24 +1300)]
dtoc: Improve internal error for Refresh()
Add the node name too so it is easy to see which node failed.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:33 +0000 (18:24 +1300)]
binman: Support default alignment for sections
Sometimes it is useful to specify the default alignment for all entries
in a section, such as when word-alignment is necessary, for example. It
is tedious and error-prone to specify this individually for each section.
Add a property to control this for a section.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:32 +0000 (18:24 +1300)]
binman: Support obtaining section contents immediately
Generally the content of sections is not built until the final assembly
of the image. This is partly to avoid wasting time, since the entries
within sections may change multiple times as binman works through its
various stages. This works quite well since sections exist in a strict
hierarchy, so they can be processed in a depth-first manner.
However the 'collection' entry type does not have this luxury. If it
contains a section within its 'content' list, then it must produce the
section contents, if available. That section is typically a sibling
node, i.e. not part oc the collection's hierarchy.
Add a new 'required' argument to section.GetData() to support this. When
required is True, any referenced sections are immediately built. If this
is not possible (because one of the subentries does not have its data yet)
then an error is produced.
The test for this uses a 'collection' entry type, referencing a section as
its first member. This forces a call to _BuildSectionData() with required
set to False, at first, then True later, when the image is assembled.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:31 +0000 (18:24 +1300)]
binman: Add support for a collection of entries
The vblock entry type includes code to collect the data from a number of
other entries (not necessarily subentries) and concatenating it. This is
a useful feature for other entry types.
Make it a base class, so that vblock can use it, along with other entry
types.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:30 +0000 (18:24 +1300)]
binman: Allow disabling expanding an entry
At present there is a command-line flag to disable substitution of expanded
entries. Add an option to the entry node as well, so it can be controlled
at the node level.
Add a test to cover this. Fix up the comment to the checkSymbols() function
it uses, while we are here.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 05:24:29 +0000 (18:24 +1300)]
binman: Use a unique number for the symbols test file
Two test devicetree files currently have 192 as their unique number. Fix
this by separating them out.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Sun, 21 Mar 2021 03:50:07 +0000 (16:50 +1300)]
x86: coral: Show memory config and SKU ID on startup
Provide the model information through sysinfo so that it shows up on
boot. For memconfig 4 pins are provided, for 16 combinations. For SKU
ID there are two options:
- two pins provided in a ternary arrangement, for 9 combinations.
- reading from the EC
Add a binding doc and drop the unused #defines as well.
Example:
U-Boot 2021.01-rc5
CPU: Intel(R) Celeron(R) CPU N3450 @ 1.10GHz
DRAM: 3.9 GiB
MMC: sdmmc@1b,0: 1, emmc@1c,0: 2
Video: 1024x768x32 @
b0000000
Model: Google Coral (memconfig 5, SKU 3)
This depends on the GPIO series:
http://patchwork.ozlabs.org/project/uboot/list/?series=228126
Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Bin Meng <bmeng.cn@gmail.com>
Simon Glass [Sun, 21 Mar 2021 03:50:06 +0000 (16:50 +1300)]
sysinfo: Allow showing model info from sysinfo
Some boards may want to show the SKU ID or other information obtained at
runtime. Allow this to come from sysinfo. The board can then provide a
sysinfo driver to provide it.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Simon Glass [Mon, 15 Mar 2021 05:11:24 +0000 (18:11 +1300)]
sandbox: Correct uninit conflict
It is not possible to remove the state before driver model is uninited,
since the devices are allocated in the memory buffer. Also it is not
possible to uninit driver model afterwards, since the RAM has been
freed.
Drop the uninit altogether, since it is not actually necessary.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:23 +0000 (18:11 +1300)]
bootm: Skip command-line substitution if !CONFIG_CMDLINE
When there is no command line, we cannot enable this feature. Add a check
to avoid a build error.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:22 +0000 (18:11 +1300)]
bloblist: Make BLOBLIST_TABLES depend on BLOBLIST
Add an extra condition here since we cannot put x86 tables in a bloblist
when bloblists are not supported.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:21 +0000 (18:11 +1300)]
command: Fix operation of !CONFIG_CMDLINE
The U_BOOT_CMDREP_COMPLETE() macro produces a build error if CONFIG_CMDLINE
is not enabled. Fix this by updating the macro to provide the 'repeatable'
arugment in this case.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:20 +0000 (18:11 +1300)]
doc: Convert Chromium OS docs to rst
Move this documentation over to reST. Move the example files into a files/
directory so they are still separate.
Do a few minor updates while we are here:
- Tidy up sandbox build instructions
- Update my github account name
- Add some talks and links
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:19 +0000 (18:11 +1300)]
malloc: Export malloc_simple_info()
Export this function always so it can be used behind IS_ENABLED() instead
of requiring an #ifdef.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:18 +0000 (18:11 +1300)]
cpu: Rename SPL_CPU_SUPPORT to SPL_CPU
The _SUPPORT suffix is from an earlier time and interferes with use of
the CONFIG_IS_ENABLED() macro. Rename the option to drop the suffix.
Tidy up the TODO that prompted this.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:17 +0000 (18:11 +1300)]
sf: Support querying write-protect
This feature was dropped from U-Boot some time ago:
f12f96cfaf5 (sf: Drop spl_flash_get_sw_write_prot")
However, we do need a way to see if a flash device is write-protected,
since if it is, it may not be possible to write to do (i.e. failing to
write is expected).
I am not sure of the correct layer to implement this, so this patch is a
stab at it. If spi-flash makes sense then I will add to the 'sf' also.
Re the points mentioned in the removal commit:
1) This kind of requirement can be achieved using existing
flash operations and flash locking API calls instead of
making a separate flash API.
Which uclass is this?
2) Technically there is no real hardware user for this API to
use in the source tree.
I do want coral (at least) to support this.
3) Having a flash operations API for simple register read bits
also make difficult to extend the flash operations.
This new patch only mentions write-protect being on or off, rather than
the actual mechanism.
4) Instead of touching generic code, it is possible to have
this functionality inside spinor operations in the form of
flash hooks or fixups for associated flash chips.
That sounds to me like what drivers are for. But we still need some sort
of API for it to be accessible.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:16 +0000 (18:11 +1300)]
bootstage: Warning if space is exhausted
At present bootstage silently ignores new records if it runs out of
space. It is sometimes obvious by looking at the report, but the IDs are
not contiguous, so it is easy to miss.
Aad a message so that action can be taken.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:15 +0000 (18:11 +1300)]
spl: Split out bootstage ID into a function
We have two separate places that need to figure out the bootstage ID to
use. Put this code in a function so that the logic is in one place.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:14 +0000 (18:11 +1300)]
binman: Show a message when changing subnodes
This change seems important enough to warrant a visible message. Change
the log_debug() to log_info().
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:13 +0000 (18:11 +1300)]
test: Silenece the echo and print tests
These tests current produce unwanted output on sandbox. Use the correct
functions to controller console output, to avoid this.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:12 +0000 (18:11 +1300)]
sandbox: image: Allow sandbox to load any image
Sandbox is special in that it is used for testing and it does not match
any particular target architecture. Allow it to load an image from any
architecture, so that 'bootm' can be used as needed.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:11 +0000 (18:11 +1300)]
sandbox: Provide a way to bind fixed/removeable devices
At present when a file is bound to a host device it is always marked as
removeable. Arguably the device is removeable, since it can be unbound at
will. However while it is bound, it is not considered removable by the
user. Also it is useful to be able to model both fixed and removeable
devices for code that distinguishes them.
Add a -r flag to the 'host bind' command and plumb it through to provide
this feature.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:10 +0000 (18:11 +1300)]
sandbox: Update do_host_bind() argument counting
Remove the 'bind' subcommand before processing the arguments. This will
make it easier to add an optional flag.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:09 +0000 (18:11 +1300)]
sandbox: Disintangle declarations in do_host_bind()
This function has a strange mix of declarations and argument parsing
which is a bit hard to follow and harder to modify. Separate out the
declarations at the start of the function and adjust the ordering of
the code slightly.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:08 +0000 (18:11 +1300)]
sandbox: cros_ec: Only write EC state when the EC is probed
This can crash if the EC has not yet been probed. Add a check to prevent
this.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:07 +0000 (18:11 +1300)]
sandbox: Only delete the executable if requested
At present sandbox removes its executable after failing to run it,
since there is no other way that it would get cleaned up.
However, this is actually only wanted if the image was created within
sandbox. For the case where the image was generated by the build system,
such as u-boot-spl, we don't want to delete it.
Handle the two code paths accordingly.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:11:06 +0000 (18:11 +1300)]
sandbox: Only call timer_timebase_fallback() if present
This function only exists if CPU is enabled. Update the code to take
account of this, so that it does not have to be enabled on all sandbox
builds.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Sean Anderson <seanga2@gmail.com>
Simon Glass [Mon, 15 Mar 2021 05:00:34 +0000 (18:00 +1300)]
x86: coreboot: Don't setup MTRR when booting from coreboot
This currently hangs and it is not necessary in any case. Drop the code
when booting from coreboot.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:00:33 +0000 (18:00 +1300)]
x86: fsp: Don't notify if booted from coreboot
When booting from coreboot there is no need to notify the FSP of anything,
since coreboot has already done it. Nor it is possible, since the FSP
details are not provided by coreboot.
Skip it in this case.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:00:32 +0000 (18:00 +1300)]
x86: coral: Fall back to coreboot video when FSP missing
When booting from coreboot the FSP video information is no-longer
available. Enable the coreboot driver so that we can get some sort of
display in this case.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:00:31 +0000 (18:00 +1300)]
x86: coral: Allow init of debug UART in U-Boot proper
At present the debug UART is only set up in SPL, on the assumption that
the boot flow will always pass through there. When booting from coreboot,
SPL is not used, so the debug UART is not available.
Move the code into a common place so that it can be used in U-Boot proper
also. Add the required init to start_from_spl.S as well.
Signed-off-by: Simon Glass <sjg@chromium.org>
Simon Glass [Mon, 15 Mar 2021 05:00:30 +0000 (18:00 +1300)]
x86: coral: Avoid build error with !CONFIG_ACPIGEN
When CONFIG_ACPIGEN is not enabled the CPU code does not build. Fix this
by moving things around.
Signed-off-by: Simon Glass <sjg@chromium.org>