| To: | Ralf Baechle <ralf@linux-mips.org> |
|---|---|
| Subject: | [PATCH][MIPS][1/2] vr41xx: add default restart routine |
| From: | Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp> |
| Date: | Thu, 16 Aug 2007 22:20:11 +0900 |
| Cc: | yoichi_yuasa@tripeaks.co.jp, linux-mips <linux-mips@linux-mips.org> |
| Organization: | TriPeaks Corporation |
| Original-recipient: | rfc822;linux-mips@linux-mips.org |
| Sender: | linux-mips-bounce@linux-mips.org |
Add vr41xx default restart routine.
Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
diff -pruN -X mips/Documentation/dontdiff
mips-orig/arch/mips/vr41xx/common/pmu.c mips/arch/mips/vr41xx/common/pmu.c
--- mips-orig/arch/mips/vr41xx/common/pmu.c 2007-08-06 13:07:41.877342750
+0900
+++ mips/arch/mips/vr41xx/common/pmu.c 2007-08-06 13:16:26.430125250 +0900
@@ -25,6 +25,7 @@
#include <linux/sched.h>
#include <linux/types.h>
+#include <asm/cacheflush.h>
#include <asm/cpu.h>
#include <asm/io.h>
#include <asm/processor.h>
@@ -70,6 +71,11 @@ static inline void software_reset(void)
pmu_write(PMUCNT2REG, pmucnt2);
break;
default:
+ set_c0_status(ST0_BEV | ST0_ERL);
+ change_c0_config(CONF_CM_CMASK, CONF_CM_UNCACHED);
+ flush_cache_all();
+ write_c0_wired(0);
+ __asm__("jr %0"::"r"(0xbfc00000));
break;
}
}
@@ -78,7 +84,6 @@ static void vr41xx_restart(char *command
{
local_irq_disable();
software_reset();
- printk(KERN_NOTICE "\nYou can reset your system\n");
while (1) ;
}
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [PATCH 1/6] mips: irix_getcontext will always fail EFAULT, Andy Whitcroft |
|---|---|
| Next by Date: | [PATCH][MIPS][2/2] vr41xx: replace infinite loop with hibernate, Yoichi Yuasa |
| Previous by Thread: | [PATCH 1/6] mips: irix_getcontext will always fail EFAULT, Andy Whitcroft |
| Next by Thread: | [PATCH][MIPS][2/2] vr41xx: replace infinite loop with hibernate, Yoichi Yuasa |
| Indexes: | [Date] [Thread] [Top] [All Lists] |