summaryrefslogtreecommitdiff
path: root/firmware/thread.c
diff options
context:
space:
mode:
authorMaurus Cuelenaere <mcuelenaere@gmail.com>2008-10-07 20:23:56 +0000
committerMaurus Cuelenaere <mcuelenaere@gmail.com>2008-10-07 20:23:56 +0000
commit9003c116ca06e7a11f444dfe026075dd2a2ff8d9 (patch)
tree2ac37ef034b3cf0958de9679eef84fea603b7fa9 /firmware/thread.c
parent6b84f600466ab02f5a671d5004cc5b13f18460af (diff)
downloadrockbox-9003c116ca06e7a11f444dfe026075dd2a2ff8d9.zip
rockbox-9003c116ca06e7a11f444dfe026075dd2a2ff8d9.tar.gz
rockbox-9003c116ca06e7a11f444dfe026075dd2a2ff8d9.tar.bz2
rockbox-9003c116ca06e7a11f444dfe026075dd2a2ff8d9.tar.xz
Fix TABs and get rid of HAVE_BUTTON_HOLD
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@18737 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/thread.c')
-rw-r--r--firmware/thread.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/firmware/thread.c b/firmware/thread.c
index 4e22c51..399f6ef 100644
--- a/firmware/thread.c
+++ b/firmware/thread.c
@@ -989,7 +989,6 @@ static inline void core_sleep(void)
void start_thread(void); /* Provide C access to ASM label */
static void __attribute__((used)) _start_thread(void)
{
-
/* $t1 = context */
asm volatile (
"start_thread: \n"
@@ -1004,7 +1003,6 @@ static void __attribute__((used)) _start_thread(void)
".set reorder \n"
);
thread_exit();
-
}
/* Place context pointer in $s0 slot, function pointer in $s1 slot, and
@@ -1084,10 +1082,9 @@ static inline void load_context(const void* addr)
static inline void core_sleep(void)
{
#if CONFIG_CPU == JZ4732
- REG_CPM_LCR &= ~CPM_LCR_LPM_MASK;
- REG_CPM_LCR |= CPM_LCR_LPM_SLEEP;
+ __cpm_idle_mode();
#endif
- asm volatile(".set mips32r2 \n"
+ asm volatile(".set mips32r2 \n"
"mfc0 $8, $12 \n" /* mfc $t0, $12 */
"move $9, $8 \n" /* move $t1, $t0 */
"la $10, 0x8000000 \n" /* la $t2, 0x8000000 */
@@ -1098,10 +1095,6 @@ static inline void core_sleep(void)
".set mips0 \n"
::: "t0", "t1", "t2"
);
-#if CONFIG_CPU == JZ4732
- REG_CPM_LCR &= ~CPM_LCR_LPM_MASK;
- REG_CPM_LCR |= CPM_LCR_LPM_IDLE;
-#endif
}