summaryrefslogtreecommitdiffstats
path: root/sys/powerpc/ofw/rtas.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/powerpc/ofw/rtas.c')
-rw-r--r--sys/powerpc/ofw/rtas.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/powerpc/ofw/rtas.c b/sys/powerpc/ofw/rtas.c
index 15cb58e..5dff8ef 100644
--- a/sys/powerpc/ofw/rtas.c
+++ b/sys/powerpc/ofw/rtas.c
@@ -62,8 +62,6 @@ int rtascall(vm_offset_t callbuffer, uintptr_t rtas_privdat);
extern uintptr_t rtas_entry;
extern register_t rtasmsr;
-int setfault(faultbuf); /* defined in locore.S */
-
/*
* After the VM is up, allocate RTAS memory and instantiate it
*/
@@ -203,7 +201,7 @@ int
rtas_call_method(cell_t token, int nargs, int nreturns, ...)
{
vm_offset_t argsptr;
- faultbuf env, *oldfaultbuf;
+ jmp_buf env, *oldfaultbuf;
va_list ap;
struct {
cell_t token;
@@ -233,7 +231,8 @@ rtas_call_method(cell_t token, int nargs, int nreturns, ...)
/* Get rid of any stale machine checks that have been waiting. */
__asm __volatile ("sync; isync");
oldfaultbuf = curthread->td_pcb->pcb_onfault;
- if (!setfault(env)) {
+ curthread->td_pcb->pcb_onfault = &env;
+ if (!setjmp(env)) {
__asm __volatile ("sync");
result = rtascall(argsptr, rtas_private_data);
__asm __volatile ("sync; isync");
OpenPOWER on IntegriCloud