[U-Boot] [PATCH v1 05/15] clk: imx: Rename and export get_cspi_clk() to imx6_get_cspi_clk()

Lukasz Majewski lukma at denx.de
Sat Jan 19 09:15:18 UTC 2019


This commit allows reusing the mach-imx/mx6/clock.c code in the CLK
driver model (DM) driver for iMX6Q.

Signed-off-by: Lukasz Majewski <lukma at denx.de>
---

 arch/arm/include/asm/arch-mx6/clock.h | 1 +
 arch/arm/mach-imx/mx6/clock.c         | 4 ++--
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/arch/arm/include/asm/arch-mx6/clock.h b/arch/arm/include/asm/arch-mx6/clock.h
index 5ce58e1b7a..81f5b43fcc 100644
--- a/arch/arm/include/asm/arch-mx6/clock.h
+++ b/arch/arm/include/asm/arch-mx6/clock.h
@@ -60,6 +60,7 @@ u32 imx_get_uartclk(void);
 u32 imx_get_fecclk(void);
 unsigned int mxc_get_clock(enum mxc_clock clk);
 u32 imx6_get_usdhc_clk(u32 port);
+u32 imx6_get_cspi_clk(void);
 void setup_gpmi_io_clk(u32 cfg);
 void hab_caam_clock_enable(unsigned char enable);
 void enable_ocotp_clk(unsigned char enable);
diff --git a/arch/arm/mach-imx/mx6/clock.c b/arch/arm/mach-imx/mx6/clock.c
index 96348b742b..cc19c92a4d 100644
--- a/arch/arm/mach-imx/mx6/clock.c
+++ b/arch/arm/mach-imx/mx6/clock.c
@@ -412,7 +412,7 @@ static u32 get_uart_clk(void)
 	return freq / (uart_podf + 1);
 }
 
-static u32 get_cspi_clk(void)
+u32 imx6_get_cspi_clk(void)
 {
 	u32 reg, cspi_podf;
 
@@ -1250,7 +1250,7 @@ unsigned int mxc_get_clock(enum mxc_clock clk)
 	case MXC_UART_CLK:
 		return get_uart_clk();
 	case MXC_CSPI_CLK:
-		return get_cspi_clk();
+		return imx6_get_cspi_clk();
 	case MXC_AXI_CLK:
 		return get_axi_clk();
 	case MXC_EMI_SLOW_CLK:
-- 
2.11.0



More information about the U-Boot mailing list