Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 3 Sep 2014 21:45:40 +0000 (UTC)
From:      Ian Lepore <ian@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r271055 - head/sys/arm/freescale/imx
Message-ID:  <201409032145.s83LjeCx084190@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ian
Date: Wed Sep  3 21:45:39 2014
New Revision: 271055
URL: http://svnweb.freebsd.org/changeset/base/271055

Log:
  Add a function to get the frequency of the AHB bus.  Another stopgap
  function until we have full clock support for imx6.

Modified:
  head/sys/arm/freescale/imx/imx51_ccm.c
  head/sys/arm/freescale/imx/imx6_ccm.c
  head/sys/arm/freescale/imx/imx_ccmvar.h

Modified: head/sys/arm/freescale/imx/imx51_ccm.c
==============================================================================
--- head/sys/arm/freescale/imx/imx51_ccm.c	Wed Sep  3 21:25:36 2014	(r271054)
+++ head/sys/arm/freescale/imx/imx51_ccm.c	Wed Sep  3 21:45:39 2014	(r271055)
@@ -580,3 +580,10 @@ imx_ccm_uart_hz(void)
 
 	return (imx51_get_clock(IMX51CLK_UART_CLK_ROOT));
 }
+
+uint32_t
+imx_ccm_ahb_hz(void)
+{
+
+	return (imx51_get_clock(IMX51CLK_AHB_CLK_ROOT));
+}

Modified: head/sys/arm/freescale/imx/imx6_ccm.c
==============================================================================
--- head/sys/arm/freescale/imx/imx6_ccm.c	Wed Sep  3 21:25:36 2014	(r271054)
+++ head/sys/arm/freescale/imx/imx6_ccm.c	Wed Sep  3 21:45:39 2014	(r271055)
@@ -238,6 +238,12 @@ imx_ccm_uart_hz(void)
 	return (80000000);
 }
 
+uint32_t
+imx_ccm_ahb_hz(void)
+{
+	return (132000000);
+}
+
 static device_method_t ccm_methods[] = {
 	/* Device interface */
 	DEVMETHOD(device_probe,  ccm_probe),

Modified: head/sys/arm/freescale/imx/imx_ccmvar.h
==============================================================================
--- head/sys/arm/freescale/imx/imx_ccmvar.h	Wed Sep  3 21:25:36 2014	(r271054)
+++ head/sys/arm/freescale/imx/imx_ccmvar.h	Wed Sep  3 21:45:39 2014	(r271055)
@@ -47,6 +47,7 @@ uint32_t imx_ccm_ipg_hz(void);
 uint32_t imx_ccm_perclk_hz(void);
 uint32_t imx_ccm_sdhci_hz(void);
 uint32_t imx_ccm_uart_hz(void);
+uint32_t imx_ccm_ahb_hz(void);
 
 void imx_ccm_usb_enable(device_t _usbdev);
 void imx_ccm_usbphy_enable(device_t _phydev);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201409032145.s83LjeCx084190>