summaryrefslogtreecommitdiffstats
path: root/firmware/target/arm/imx233/clkctrl-imx233.h
diff options
context:
space:
mode:
authorAmaury Pouly <pamaury@rockbox.org>2011-10-18 22:00:50 +0000
committerAmaury Pouly <pamaury@rockbox.org>2011-10-18 22:00:50 +0000
commitd0e8c35862d977aa328a45889a17cab4b6f85878 (patch)
tree038aef4de2fea3a668bb8f9dc0ef6d45c4de097a /firmware/target/arm/imx233/clkctrl-imx233.h
parent0b3347e47f8b6a1d81b4d6cf83178a017db5b1f0 (diff)
downloadrockbox-d0e8c35862d977aa328a45889a17cab4b6f85878.tar.gz
rockbox-d0e8c35862d977aa328a45889a17cab4b6f85878.tar.bz2
rockbox-d0e8c35862d977aa328a45889a17cab4b6f85878.zip
imx233/fuze+: move to a more generic xtal derived clock enabling function, fix timrot accordingly
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30793 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/arm/imx233/clkctrl-imx233.h')
-rw-r--r--firmware/target/arm/imx233/clkctrl-imx233.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/firmware/target/arm/imx233/clkctrl-imx233.h b/firmware/target/arm/imx233/clkctrl-imx233.h
index 7aa4f716e8..e59f954071 100644
--- a/firmware/target/arm/imx233/clkctrl-imx233.h
+++ b/firmware/target/arm/imx233/clkctrl-imx233.h
@@ -50,6 +50,8 @@
#define HW_CLKCTRL_XTAL (*(volatile uint32_t *)(HW_CLKCTRL_BASE + 0x50))
#define HW_CLKCTRL_XTAL__TIMROT_CLK32K_GATE (1 << 26)
+#define HW_CLKCTRL_XTAL__DRI_CLK24M_GATE (1 << 28)
+#define HW_CLKCTRL_XTAL__FILT_CLK24M_GATE (1 << 30)
#define HW_CLKCTRL_PIX (*(volatile uint32_t *)(HW_CLKCTRL_BASE + 0x60))
#define HW_CLKCTRL_PIX__DIV_BM 0xfff
@@ -84,7 +86,15 @@ enum imx233_clock_t
CLK_AHB /* div */
};
-void imx233_enable_timrot_xtal_clk32k(bool enable);
+enum imx233_xtal_clkt_t
+{
+ XTAL_FILT = 1 << 30,
+ XTAL_DRI = 1 << 28,
+ XTAL_TIMROT = 1 << 26,
+};
+
+/* can use a mask of clocks */
+void imx233_enable_xtal_clock(enum imx233_xtal_clkt_t xtal_clk, bool enable);
/* only use it for non-fractional clocks (ie not for IO) */
void imx233_enable_clock(enum imx233_clock_t clk, bool enable);
void imx233_set_clock_divisor(enum imx233_clock_t clk, int div);