diff options
| author | Michael Sevakis <jethead71@rockbox.org> | 2007-10-16 22:00:51 +0000 |
|---|---|---|
| committer | Michael Sevakis <jethead71@rockbox.org> | 2007-10-16 22:00:51 +0000 |
| commit | 84f5c5c3e3590cb993f4cf2a7eba5979e3bc825b (patch) | |
| tree | b082d38196667f747bbcb9325dc65339d61b67b2 /firmware/thread.c | |
| parent | 28936603be8ab9c8c3e2284d835c3961b4033bfd (diff) | |
| download | rockbox-84f5c5c3e3590cb993f4cf2a7eba5979e3bc825b.zip rockbox-84f5c5c3e3590cb993f4cf2a7eba5979e3bc825b.tar.gz rockbox-84f5c5c3e3590cb993f4cf2a7eba5979e3bc825b.tar.bz2 rockbox-84f5c5c3e3590cb993f4cf2a7eba5979e3bc825b.tar.xz | |
Take out some NOCACHEBSS_ATTR's that were accidentally left. Put some threading code in IRAM that should be there on PP502x.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15155 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/thread.c')
| -rw-r--r-- | firmware/thread.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/firmware/thread.c b/firmware/thread.c index c9ce049..6ba99dd 100644 --- a/firmware/thread.c +++ b/firmware/thread.c @@ -387,6 +387,13 @@ void corelock_unlock(struct corelock *cl) #endif /* CONFIG_CORELOCK == SW_CORELOCK */ +#ifdef CPU_PP502x +/* Some code relies on timing */ +void switch_thread(struct thread_entry *old) ICODE_ATTR; +void core_wake(IF_COP_VOID(unsigned int othercore)) ICODE_ATTR; +void core_idle(void) ICODE_ATTR; +#endif + /*--------------------------------------------------------------------------- * Put core in a power-saving state if waking list wasn't repopulated and if * no other core requested a wakeup for it to perform a task. @@ -405,7 +412,7 @@ static inline void core_sleep(IF_COP(unsigned int core,) struct thread_entry **w "ldr r0, [%[w]] \n" /* Check *waking */ "cmp r0, #0 \n" /* != NULL -> exit */ "bne 1f \n" - /* ------ fixed-time sequence ----- */ + /* ------ fixed-time sequence ----- */ /* Can this be relied upon? */ "ldr r0, [%[ms], %[oc], lsl #2] \n" /* Stay-awake requested? */ "mov r1, #0x80000000 \n" "tst r0, #1 \n" @@ -453,7 +460,7 @@ void core_wake(IF_COP_VOID(unsigned int othercore)) "orr r1, r2, #0xc0 \n" "msr cpsr_c, r1 \n" "mov r1, #1 \n" - /* ------ fixed-time sequence ----- */ + /* ------ fixed-time sequence ----- */ /* Can this be relied upon? */ "str r1, [%[ms], %[oc], lsl #2] \n" /* Send stay-awake message */ "nop \n" "nop \n" |