Fix generic JNI stubs to not discard the Java native frame.

Change-Id: Ic856b442fdde5ce91673fc5856eb0dfc84c75d28
diff --git a/runtime/arch/mips64/quick_entrypoints_mips64.S b/runtime/arch/mips64/quick_entrypoints_mips64.S
index 60e692b..6f1b826 100644
--- a/runtime/arch/mips64/quick_entrypoints_mips64.S
+++ b/runtime/arch/mips64/quick_entrypoints_mips64.S
@@ -849,7 +849,7 @@
     dmfc1   $a2, $f0
 
     ld      $t0, THREAD_EXCEPTION_OFFSET(rSELF) # load Thread::Current()->exception_
-    bne     $t0, $zero, 2f         # check for pending exceptions
+    bne     $t0, $zero, 1f         # check for pending exceptions
     move    $sp, $s8               # tear down the alloca
 
     # tear dpown the callee-save frame
@@ -859,9 +859,8 @@
     dmtc1   $v0, $f0               # place return value to FP return value
 
 1:
-    move    $sp, $s8               # tear down the alloca
-2:
-    RESTORE_REFS_AND_ARGS_CALLEE_SAVE_FRAME
+    ld      $sp, THREAD_TOP_QUICK_FRAME_OFFSET(rSELF)
+    # This will create a new save-all frame, required by the runtime.
     DELIVER_PENDING_EXCEPTION
 END art_quick_generic_jni_trampoline