summaryrefslogtreecommitdiffstats
path: root/firmware/target/coldfire/system-coldfire.c
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2007-02-25 21:43:10 +0000
committerMichael Sevakis <jethead71@rockbox.org>2007-02-25 21:43:10 +0000
commit2c9cbc12e137b1c756721a8fc4df6003032b0b53 (patch)
treea9ac372f2cf28287deaa17a786e4bba9be339263 /firmware/target/coldfire/system-coldfire.c
parentf5184f34bfd794884d18057a594e7acb9aeb00e4 (diff)
downloadrockbox-2c9cbc12e137b1c756721a8fc4df6003032b0b53.tar.gz
rockbox-2c9cbc12e137b1c756721a8fc4df6003032b0b53.zip
Add CPU-model-specific init to newborn threads. Add default %macsr for each thread created on coldfire (EMAC_FRACTIONAL | EMAC_SATURATE).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12483 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/coldfire/system-coldfire.c')
-rw-r--r--firmware/target/coldfire/system-coldfire.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/firmware/target/coldfire/system-coldfire.c b/firmware/target/coldfire/system-coldfire.c
index 9e5db41daa..4094f3875f 100644
--- a/firmware/target/coldfire/system-coldfire.c
+++ b/firmware/target/coldfire/system-coldfire.c
@@ -234,16 +234,13 @@ void (* const vbr[]) (void) __attribute__ ((section (".vectors"))) =
void system_init(void)
{
/* Clear the accumulators. From here on it's the responsibility of
- whoever uses them to clear them after use (use movclr instruction). */
+ whoever uses them to clear them after use and before giving control
+ to "foreign" code (use movclr instruction). */
asm volatile ("movclr.l %%acc0, %%d0\n\t"
"movclr.l %%acc1, %%d0\n\t"
"movclr.l %%acc2, %%d0\n\t"
"movclr.l %%acc3, %%d0\n\t"
: : : "d0");
- /* Set EMAC unit to fractional mode with saturation, since that's
- what'll be the most useful for most things which the main thread
- will do. */
- coldfire_set_macsr(EMAC_FRACTIONAL | EMAC_SATURATE);
/* Set INTBASE and SPURVEC */
INTBASE = 64;