Hi Dinesh,

On 29/4/2026 1:32 pm, [email protected] wrote:
From: Dinesh Maniyam <[email protected]>

Enable CONFIG_OF_UPSTREAM for the Arria 10 SoCDK SDMMC target so that
the device tree is taken from the dts/upstream/ subtree (synchronised
from the Linux kernel) instead of the locally-maintained copy. This
keeps U-Boot in sync with Linux and avoids drift between the two trees.

Update CONFIG_DEFAULT_DEVICE_TREE to the upstream path
"intel/socfpga/socfpga_arria10_socdk_sdmmc".

Remove the now-obsolete device tree files:
- arch/arm/dts/socfpga_arria10_socdk_sdmmc.dts
- arch/arm/dts/socfpga_arria10_socdk.dtsi
and drop the corresponding entry from arch/arm/dts/Makefile.

The upstream socfpga_arria10.dtsi does not provide a label on the
"clkmgr@ffd04000" node, so reference it via its full path in
socfpga_arria10-u-boot.dtsi to keep adding the bootph-all property.

arch/arm/dts/socfpga_arria10.dtsi is intentionally kept since it is
still consumed by the Chameleon V3 / Mercury AA1 device trees which
have not yet been migrated to OF_UPSTREAM.

Build tested with socfpga_arria10_defconfig (arm-none-eabi-).

Signed-off-by: Dinesh Maniyam <[email protected]>
---
  arch/arm/dts/Makefile                        |   1 -
  arch/arm/dts/socfpga_arria10-u-boot.dtsi     |   2 +-
  arch/arm/dts/socfpga_arria10_socdk.dtsi      | 178 -------------------
  arch/arm/dts/socfpga_arria10_socdk_sdmmc.dts |  27 ---
  configs/socfpga_arria10_defconfig            |   3 +-
  5 files changed, 3 insertions(+), 208 deletions(-)
  delete mode 100644 arch/arm/dts/socfpga_arria10_socdk.dtsi
  delete mode 100644 arch/arm/dts/socfpga_arria10_socdk_sdmmc.dts

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 4085d4c2de1..51c5b802269 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -446,7 +446,6 @@ dtb-$(CONFIG_ARCH_SOCFPGA) +=                               
\
        socfpga_arria10_chameleonv3_270_2.dtb           \
        socfpga_arria10_chameleonv3_270_3.dtb           \
        socfpga_arria10_chameleonv3_480_2.dtb           \
-       socfpga_arria10_socdk_sdmmc.dtb                 \
        socfpga_cyclone5_mcvevk.dtb                     \
        socfpga_cyclone5_is1.dtb                        \
        socfpga_cyclone5_socdk.dtb                      \
diff --git a/arch/arm/dts/socfpga_arria10-u-boot.dtsi 
b/arch/arm/dts/socfpga_arria10-u-boot.dtsi
index 2ed532ffb54..c0ce337d72e 100644
--- a/arch/arm/dts/socfpga_arria10-u-boot.dtsi
+++ b/arch/arm/dts/socfpga_arria10-u-boot.dtsi
@@ -18,7 +18,7 @@
        };
  };
-&clkmgr {
+&{/soc/clkmgr@ffd04000} {


Path-reference override for clkmgr is fragile to upstream DT path drift
The better fix is a Linux kernel device-tree change, not a U-Boot-only hack
  Linux: add the label in kernel DT, e.g.
     clkmgr: clkmgr@ffd04000 {
  in socfpga_arria10.dtsi

acceptable; optional please follow-up with Linux owner to add upstream label.

        bootph-all;
clocks {
diff --git a/arch/arm/dts/socfpga_arria10_socdk.dtsi 
b/arch/arm/dts/socfpga_arria10_socdk.dtsi
deleted file mode 100644
index 0efbeccc5cd..00000000000
--- a/arch/arm/dts/socfpga_arria10_socdk.dtsi
+++ /dev/null
@@ -1,178 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0+
-/*
- * Copyright (C) 2015 Altera Corporation <www.altera.com>
- */
-#include "socfpga_arria10.dtsi"


[...]


diff --git a/arch/arm/dts/socfpga_arria10_socdk_sdmmc.dts 
b/arch/arm/dts/socfpga_arria10_socdk_sdmmc.dts
deleted file mode 100644
index 64dc0799f3d..00000000000
--- a/arch/arm/dts/socfpga_arria10_socdk_sdmmc.dts
+++ /dev/null
@@ -1,27 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0+
-/*
- * Copyright (C) 2014-2015 Altera Corporation <www.altera.com>
- */
-
-/dts-v1/;
-#include "socfpga_arria10_socdk.dtsi"
-
-&mmc {
-       status = "okay";
-       cap-sd-highspeed;
-       cap-mmc-highspeed;
-       broken-cd;
-       bus-width = <4>;
-};
-
-&eccmgr {
-       sdmmca-ecc@ff8c2c00 {
-               compatible = "altr,socfpga-sdmmc-ecc";
-               reg = <0xff8c2c00 0x400>;
-               altr,ecc-parent = <&mmc>;
-               interrupts = <15 IRQ_TYPE_LEVEL_HIGH>,
-                            <47 IRQ_TYPE_LEVEL_HIGH>,
-                            <16 IRQ_TYPE_LEVEL_HIGH>,
-                            <48 IRQ_TYPE_LEVEL_HIGH>;
-       };
-};
diff --git a/configs/socfpga_arria10_defconfig 
b/configs/socfpga_arria10_defconfig
index b32f40ae408..17169472462 100644
--- a/configs/socfpga_arria10_defconfig
+++ b/configs/socfpga_arria10_defconfig
@@ -7,7 +7,7 @@ CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0xffe2b000
  CONFIG_ENV_SIZE=0x2000
  CONFIG_ENV_OFFSET=0x4400
  CONFIG_DM_GPIO=y
-CONFIG_DEFAULT_DEVICE_TREE="socfpga_arria10_socdk_sdmmc"
+CONFIG_DEFAULT_DEVICE_TREE="intel/socfpga/socfpga_arria10_socdk_sdmmc"


CONFIG_DEFAULT_DEVICE_TREE changed to "intel/socfpga/socfpga_arria10_socdk_sdmmc" while CONFIG_DEFAULT_FDT_FILE="socfpga_arria10_socdk_sdmmc.dtb" is unchanged

Can drop this as socfpga_agilex_defconfig OF_UPSTREAM migration omits DEFAULT_FDT_FILE entirely.


Best regards,
Tien Fong

Reply via email to