[PATCH V2 5/6] ARM: dts: stm32: Rework DDR DT inclusion

Patrick DELAUNAY patrick.delaunay at st.com
Wed Apr 22 11:06:34 CEST 2020


Dear Marek,

> From: Marek Vasut <marex at denx.de>
> Sent: vendredi 10 avril 2020 20:56
> 
> Adjust the DDR configuration dtsi such that they only generate the DRAM
> configuration node, the DDR controller node is moved into the stm32mp157-u-
> boot.dtsi itself. This permits including multiple DDR configuration dtsi files in
> board DT.
> 
> Signed-off-by: Marek Vasut <marex at denx.de>
> Cc: Manivannan Sadhasivam <manivannan.sadhasivam at linaro.org>
> Cc: Patrick Delaunay <patrick.delaunay at st.com>
> Cc: Patrice Chotard <patrice.chotard at st.com>
> ---
> V2: Add compatible string
> ---
>  arch/arm/dts/stm32mp15-ddr.dtsi               | 358 +++++++++++-------
>  .../dts/stm32mp15-ddr3-1x4Gb-1066-binG.dtsi   |   1 +
>  .../dts/stm32mp15-ddr3-2x4Gb-1066-binG.dtsi   |   1 +
>  arch/arm/dts/stm32mp157-u-boot.dtsi           |  25 ++
>  4 files changed, 248 insertions(+), 137 deletions(-)
> 
> diff --git a/arch/arm/dts/stm32mp15-ddr.dtsi b/arch/arm/dts/stm32mp15-ddr.dtsi
> index 38f29bb789..026237b088 100644
> --- a/arch/arm/dts/stm32mp15-ddr.dtsi
> +++ b/arch/arm/dts/stm32mp15-ddr.dtsi
> @@ -2,153 +2,237 @@
>  /*
>   * Copyright : STMicroelectronics 2018
>   */
> +#include <linux/stringify.h>
> 
> -/ {
> -	soc {
> -		ddr: ddr at 5a003000 {
> -			u-boot,dm-pre-reloc;
> +&ddr {
> +	config-DDR_MEM_COMPATIBLE {
> +		u-boot,dm-pre-reloc;
> -			compatible = "st,stm32mp1-ddr";
> +		compatible = __stringify(st,DDR_MEM_COMPATIBLE);

I have just a concern here, but only for ST ecosystem.

As the DDR_MEM_COMPATIBLE is not generated by CubeMX tools. 

But I will manage it after.....

2 solution; I add a default value.

#ifndef DDR_MEM_COMPATIBLE
#define DDR_MEM_COMPATIBLE ddr-0
#endif

Or don't create sub-node when the COMPATIBLE is absent.

So for this patch:

Reviewed-by: Patrick Delaunay <patrick.delaunay at st.com>

Thanks

Patrick


More information about the U-Boot mailing list