[U-Boot] Functional clashes between vanilla and Yocto releases

Eugeniu Rosca erosca at de.adit-jv.com
Tue Jun 18 11:15:43 UTC 2019


Hello Marek, hello Yokoyama-san,

Reviewing the Renesas Yocto v3.19/3.21 U-Boot updates, I came across a
few patches which conflict with features in vanilla both conceptually
and functionally.

Making a local conflict resolution is not future-proof. That's why
I would like to kindly ask for your long-term view and feedback.

I have two topics, one relatively major and one relatively minor.

A. Getting platform information (e.g. DRAM, board id) from ATF.

A.1. Vanilla ATF already passes DRAM information via the first four
general-purpose registers x0...x3 of the primary CPU when control
is given to U-Boot. The relevant commits are shown in [1].

A.2. Renesas Yocto release achieves a similar goal very differently.
Currently, Renesas ATF implements a dedicated SMC call which is then
used by U-Boot to get the board id. The latter is read from the EEPROM
of the ROHM BD9571 PMIC, available on the reference targets.
The relevant commits implementing the feature are shown in [2].

It looks like the two approaches try to serve the same purpose, so is
there a chance from your point of view to make an alignment?

B. The Renesas commits listed in [3] talk about a "DMA controller
restriction of SDHI". I have a few questions/remarks:
 - Is the restriction described anywhere in the ERRATA documents?
   It would have been incredibly useful to see this information
   present in the commit description.
 - My guess is that increasing the cache line size from 64 to 128 bytes
   U-Boot-wide is not the best solution to fix a restriction of one
   specific HW IP in the SoC. Do you foresee a cleaner way to tackle it?

Thank you very much!

[1] Commits implementing feature A.1.
* https://github.com/ARM-software/arm-trusted-firmware/commit/1d85c4bd5b6291
  ("plat: rcar: Pass DTB with DRAM layout from BL2 to next stages")
* http://git.denx.de/?p=u-boot.git;a=commitdiff;h=4fa8375ffec5
  ("ARM: renesas: Save boot parameters passed in by ATF")
* http://git.denx.de/?p=u-boot.git;a=commit;h=175f5027345c
  ("ARM: renesas: Configure DRAM size from ATF DT fragment")
* http://git.denx.de/?p=u-boot.git;a=commit;h=6ef540d50f3b
  ("ARM: renesas: Factor out DRAM setup on R-Car Gen3")

[2] Commits implementing feature A.2.
* https://github.com/renesas-rcar/arm-trusted-firmware/commit/7a3e3a946b7804
  ("plat: rcar: BL31: Add SiP for getting board ID")
* https://github.com/renesas-rcar/u-boot/commit/37db17863e
  ("board: salvator-x: Add function to activate with suitable DT")
* https://github.com/renesas-rcar/u-boot/commit/943a619ba7
  ("board: ebisu: Add function to activate with suitable DT")
* https://github.com/renesas-rcar/u-boot/commit/0c86ed3bc6
  ("board: ulcb: Add function to activate with suitable DT")

[3] Commits fixing "DMA controller restriction of SDHI" on Gen3
* https://github.com/renesas-rcar/u-boot/commit/3fae6a05b4
  ("mmc: tmio: rcar_gen3: Add DMA transfer address alignment check at writing")
* https://github.com/renesas-rcar/u-boot/commit/73d658ca58
  ("ARM: rcar_gen3: Change to SYS_CACHE_SHIFT_7")

-- 
Best Regards,
Eugeniu.


More information about the U-Boot mailing list