summaryrefslogtreecommitdiff
path: root/arch/m68k/lib
diff options
context:
space:
mode:
Diffstat (limited to 'arch/m68k/lib')
-rw-r--r--arch/m68k/lib/Makefile1
-rw-r--r--arch/m68k/lib/clock.c23
2 files changed, 24 insertions, 0 deletions
diff --git a/arch/m68k/lib/Makefile b/arch/m68k/lib/Makefile
index cf93715637a..9ad67c4272c 100644
--- a/arch/m68k/lib/Makefile
+++ b/arch/m68k/lib/Makefile
@@ -9,3 +9,4 @@ lib-$(CONFIG_USE_PRIVATE_LIBGCC) += lshrdi3.o muldi3.o ashldi3.o ashrdi3.o
obj-$(CONFIG_CMD_BOOTM) += bootm.o
obj-$(CONFIG_ARCH_COLDFIRE) += cache.o interrupts.o time.o traps.o bdinfo.o fec.o
+obj-$(CONFIG_MCF5441x) += clock.o
diff --git a/arch/m68k/lib/clock.c b/arch/m68k/lib/clock.c
new file mode 100644
index 00000000000..5d9aeed96c3
--- /dev/null
+++ b/arch/m68k/lib/clock.c
@@ -0,0 +1,23 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * (C) Copyright 2026 Kernelspace
+ * Angelo Dureghello <[email protected]>
+ */
+
+#include <config.h>
+#include <asm/arch/clock.h>
+#include <asm/global_data.h>
+
+DECLARE_GLOBAL_DATA_PTR;
+/*
+ * Stub to use existing nxp/fsl drivers.
+ */
+int mxc_get_clock(enum mxc_clock clk)
+{
+ if (clk == MXC_ESDHC_CLK)
+ return gd->arch.sdhc_clk;
+
+ printf("Unsupported MXC CLK: %d\n", clk);
+
+ return 0;
+}