summaryrefslogtreecommitdiffstats
path: root/firmware/target/arm/imx233/clkctrl-imx233.c
AgeCommit message (Collapse)AuthorFilesLines
2016-05-28imx233: generate register headers using headergen_v2 and update code for itAmaury Pouly1-25/+23
NOTE: this commit does not introduce any change, ideally even the binary should be almost the same. I checked the disassembly by hand and there are only a few differences here and there, mostly the compiler decides to compile very close expressions slightly differently. I tried to run the new code on several targets to make sure and saw no difference. The major syntax changes of the new headers are as follows: - BF_{WR,SET,CLR} are now superpowerful and allows to set several fileds at once: BF_WR(reg, field1(value1), field2(value2), ...) - BF_CS (use like BF_WR) does a write to reg_CLR and then reg_SET instead of RMW - there is no more need for macros like BF_{WR_,SET,CLR}_V, since one can simply BF_WR with field_V(name) - the old BF_SETV macro has no trivial equivalent and is replaced with its its equivalent for BF_WR(reg_SET, ...) I also rename the register headers: "regs/regs-x.h" -> "regs/x.h" to avoid the redundant "regs". Final note: the registers were generated using the following command: ./headergen_v2 -g imx -o ../../firmware/target/arm/imx233/regs/ desc/regs-stmp3{600,700,780}.xml Change-Id: I7485e8b4315a0929a8edb63e7fa1edcaa54b1edc
2014-03-08imx233: add function to change cpu/hbus frequency safelyAmaury Pouly1-0/+32
Change-Id: I88e9ad54ba65846ae4d94ae03009b3656f2489f2
2013-06-17imx233: fix clkctrl for stmp3600 and stmp3700Amaury Pouly1-3/+55
Change-Id: I7596e41c0d0b7fdcc18f7d328a0927c2c78dc4cb
2013-06-17imx233: normalise clkctrlAmaury Pouly1-83/+68
The clkctrl functions were becoming a mess. Normalise the names, get rid of the xtal derived as special case and use the same interface. Change-Id: Ib954a8d30a6bd691914b5e0d97774ec9fc560c50
2013-06-16imx233: rewrite clkctrl using new register headersAmaury Pouly1-125/+78
Change-Id: I6c79e99ed4ab20e00c3110d870e144a6c8596769
2012-12-26imx233: fix potential hbus dividor settings + docAmaury Pouly1-3/+6
HBUS uses the same field for integer and fractional dividers, the choice is made by a bit. Make sure both are changed together, otherwise this could result in the wrong divider to be used and in HBUS freq to be too low or too high (very bad). Change-Id: I253d8eeee26c5038868b729c4f791511295a39f0
2012-08-31imx233: fix auto slow divisorAmaury Pouly1-2/+5
The divisor must be set only when auto-slow is disabled. Change-Id: I31ed94f43a7c9deb80275dc73f8e3c78463b54c0
2012-08-30imx233: fix clktrl auto slow functionAmaury Pouly1-2/+2
Change-Id: I6c004836562b0605530ac334434b17afa89ebad5
2012-08-30imx233: fix header, add emi functionAmaury Pouly1-1/+6
Change-Id: I1030e94f0dad4b66646cafa20b61df8a5c7f9278
2012-05-21imx233: enable PLL on startupAmaury Pouly1-0/+11
Implement PLL enabling/disable and unconditionally power the PLL on startup. This is needed at least on the Zen X-Fi2. Change-Id: Ib9ddfdeaf973cedded4b3586dd16aa95a61e78ba
2012-05-19imx233: fix clkctrl namingAmaury Pouly1-54/+55
Move to a more consistent naming convention like the other devices Change-Id: I4ddbbee27ee9f5ae775c5776592ec7ce02b30948
2012-02-28imx233: user __FIELD_SET to set the clock divisorsAmaury Pouly1-20/+8
The clock divisors must *NEVER* be 0, first clearing then setting is thus undefined. Change-Id: Iba8e6ba1e668bf746e3f7387f0175f63d81f6b2b
2012-01-21imx233: fix clkctrl code (some registers don't have a SET/CLR variant)Amaury Pouly1-8/+9
Change-Id: I3ce6a77cdc5ea89e1e43bc00c9ec43664e765fdc
2011-12-15imx233: fix to typo and remove a forgotten panicAmaury Pouly1-1/+1
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31269 a1c6a512-1295-4272-9138-f99709370657
2011-12-03imx233: add control for more clocks, add debug clock debug screenAmaury Pouly1-3/+242
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31121 a1c6a512-1295-4272-9138-f99709370657
2011-10-18imx233/fuze+: move to a more generic xtal derived clock enabling function, ↵Amaury Pouly1-3/+3
fix timrot accordingly git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30793 a1c6a512-1295-4272-9138-f99709370657
2011-09-14imx233/fuze+: implement usb enableAmaury Pouly1-0/+8
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30542 a1c6a512-1295-4272-9138-f99709370657
2011-06-30imx233/fuze+: ssp, dma, mmc now work properly, partially implement cpu ↵Amaury Pouly1-2/+14
frequency changing, implement panic waiting git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30104 a1c6a512-1295-4272-9138-f99709370657
2011-06-17fuze+: add more clocking code, add dma code, add ssp code, add stub usb ↵Amaury Pouly1-0/+24
code, update storage to SD + MMC, beginning of the driver git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30010 a1c6a512-1295-4272-9138-f99709370657
2011-05-01Sansa Fuze+: initial commit (bootloader only, LCD basically working)Amaury Pouly1-0/+84
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29808 a1c6a512-1295-4272-9138-f99709370657