[rtems-libbsd commit] imx6_ccm: Port to RTEMS
Christian Mauderer
christianm at rtems.org
Wed Apr 15 15:11:43 UTC 2020
Module: rtems-libbsd
Branch: master
Commit: eb6ff6332297d33211b9ed6fea5a22fe6fe5d0ff
Changeset: http://git.rtems.org/rtems-libbsd/commit/?id=eb6ff6332297d33211b9ed6fea5a22fe6fe5d0ff
Author: Sebastian Huber <sebastian.huber at embedded-brains.de>
Date: Mon Feb 11 07:54:57 2019 +0100
imx6_ccm: Port to RTEMS
Update #3869.
---
freebsd/sys/arm/freescale/imx/imx6_ccm.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/freebsd/sys/arm/freescale/imx/imx6_ccm.c b/freebsd/sys/arm/freescale/imx/imx6_ccm.c
index 2993f1d..cef7993 100644
--- a/freebsd/sys/arm/freescale/imx/imx6_ccm.c
+++ b/freebsd/sys/arm/freescale/imx/imx6_ccm.c
@@ -92,6 +92,7 @@ WR4(struct ccm_softc *sc, bus_size_t off, uint32_t val)
static void
ccm_init_gates(struct ccm_softc *sc)
{
+#ifndef __rtems__
uint32_t reg;
/* ahpbdma, aipstz 1 & 2 buses */
@@ -129,6 +130,7 @@ ccm_init_gates(struct ccm_softc *sc)
reg = CCGR6_USBOH3 | CCGR6_USDHC1 | CCGR6_USDHC2 |
CCGR6_USDHC3 | CCGR6_USDHC4;
WR4(sc, CCM_CCGR6, reg);
+#endif /* __rtems__ */
}
static int
@@ -204,7 +206,12 @@ ccm_probe(device_t dev)
if (!ofw_bus_status_okay(dev))
return (ENXIO);
+#ifndef __rtems__
if (ofw_bus_is_compatible(dev, "fsl,imx6q-ccm") == 0)
+#else /* __rtems__ */
+ if (ofw_bus_is_compatible(dev, "fsl,imx6q-ccm") == 0 &&
+ ofw_bus_is_compatible(dev, "fsl,imx6ul-ccm") == 0)
+#endif /* __rtems__ */
return (ENXIO);
device_set_desc(dev, "Freescale i.MX6 Clock Control Module");
More information about the vc
mailing list