]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
arm: socfpga: agilex: Enable system manager driver for Agilex
authorAlif Zakuan Yuslaimi <alif.zakuan.yuslaimi@altera.com>
Mon, 4 Aug 2025 01:24:37 +0000 (18:24 -0700)
committerTien Fong Chee <tien.fong.chee@intel.com>
Fri, 8 Aug 2025 14:20:48 +0000 (22:20 +0800)
The base address of system manager can be retrieved
using DT framework through the system manager driver.

Enable system manager support for Agilex by probing the
system manager driver to initialize during SPL boot up.

Signed-off-by: Boon Khai Ng <boon.khai.ng@altera.com>
Signed-off-by: Alif Zakuan Yuslaimi <alif.zakuan.yuslaimi@altera.com>
Reviewed-by: Tien Fong Chee <tien.fong.chee@altera.com>
MAINTAINERS
arch/arm/dts/socfpga_agilex.dtsi
arch/arm/mach-socfpga/Makefile
arch/arm/mach-socfpga/spl_agilex.c
board/intel/agilex-socdk/Makefile [new file with mode: 0644]
board/intel/agilex-socdk/socfpga.c [new file with mode: 0644]

index fdce820c7925391899b317f75f35659f79a031a4..a04b93a807b0071523268038de4d9795459a52e3 100644 (file)
@@ -156,6 +156,7 @@ S:  Maintained
 T:     git https://source.denx.de/u-boot/custodians/u-boot-socfpga.git
 F:     arch/arm/dts/socfpga_*
 F:     arch/arm/mach-socfpga/
+F:     board/intel/agilex-socdk/
 F:     configs/socfpga_*
 F:     drivers/ddr/altera/
 F:     drivers/power/domain/altr-pmgr-agilex5.c
index be5100aea983dda5bfb0ca65013d77090db54990..84bc40dbcc3e26657f93082ceb95d449fbe2fc9c 100644 (file)
                        };
                };
        };
+
+       aliases {
+               sysmgr = &sysmgr;
+       };
 };
index c43fdee4a48c4efff687c87d0d16cf6179e0a7bb..7f53c249805e620c7a3bd8b5ae4038f3744eb7ad 100644 (file)
@@ -54,6 +54,7 @@ obj-y += timer_s10.o
 obj-$(CONFIG_SOCFPGA_SECURE_VAB_AUTH)  += vab.o
 obj-y  += wrap_handoff_soc64.o
 obj-y  += wrap_pll_config_soc64.o
+obj-y  += altera-sysmgr.o
 endif
 
 ifdef CONFIG_TARGET_SOCFPGA_AGILEX5
index c16519fc2bdadfcb3b7b248e1209ff5f751b90f6..351848f16e665d4ca0ab0c01f370db32bf8e1c88 100644 (file)
@@ -54,6 +54,7 @@ void board_init_f(ulong dummy)
        if (ret)
                hang();
 
+       socfpga_get_sys_mgr_addr();
        socfpga_get_managers_addr();
 
        /* Ensure watchdog is paused when debugging is happening */
diff --git a/board/intel/agilex-socdk/Makefile b/board/intel/agilex-socdk/Makefile
new file mode 100644 (file)
index 0000000..306a8cf
--- /dev/null
@@ -0,0 +1,7 @@
+#
+# Copyright (C) 2025 Altera Corporation <www.altera.com>
+#
+# SPDX-License-Identifier:     GPL-2.0
+#
+
+obj-y  := socfpga.o
diff --git a/board/intel/agilex-socdk/socfpga.c b/board/intel/agilex-socdk/socfpga.c
new file mode 100644 (file)
index 0000000..60c8704
--- /dev/null
@@ -0,0 +1,12 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright (C) 2025 Altera Corporation <www.altera.com>
+ */
+
+#include <asm/arch/misc.h>
+
+int board_early_init_f(void)
+{
+       socfpga_get_sys_mgr_addr();
+       return 0;
+}