]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[NDS32] Refine force unwind. Linux kernel only uses RT_SIGRETURN.
authorjasonwucj <jasonwucj@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 15 Apr 2019 08:19:23 +0000 (08:19 +0000)
committerjasonwucj <jasonwucj@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 15 Apr 2019 08:19:23 +0000 (08:19 +0000)
libgcc/
* config/nds32/linux-unwind.h (SIGRETURN): Remove.
(RT_SIGRETURN): Update.
(nds32_fallback_frame_state): Update.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@270363 138bc75d-0d04-0410-961f-82ee72b054a4

libgcc/ChangeLog
libgcc/config/nds32/linux-unwind.h

index 950eeabb0613f475c379c99423d0f44a4a2d1094..de8d56a2ee759caa6138c4aff822dbaf8a318291 100644 (file)
@@ -1,3 +1,9 @@
+2019-04-15  Monk Chiang  <sh.chiang04@gmail.com>
+
+       * config/nds32/linux-unwind.h (SIGRETURN): Remove.
+       (RT_SIGRETURN): Update.
+       (nds32_fallback_frame_state): Update.
+
 2019-02-21  Martin Sebor  <msebor@redhat.com>
 
        * libgcc2.h (__clear_cache): Correct signature.
index 0c4df4dde8195c7bbdcfed360f42642f9869d700..adb6f9f450ba7fb13463d69ad8a26eb0a5273fb8 100644 (file)
@@ -42,8 +42,7 @@ struct _rt_sigframe {
   struct ucontext_t uc;
 };
 
-#define SIGRETURN 0xeb0e0a64
-#define RT_SIGRETURN 0xab150a64
+#define RT_SIGRETURN 0x8b00f044
 
 #define MD_FALLBACK_FRAME_STATE_FOR nds32_fallback_frame_state
 
@@ -74,16 +73,14 @@ nds32_fallback_frame_state (struct _Unwind_Context *context,
 
   /* Check if we are going through a signal handler.
      See arch/nds32/kernel/signal.c implementation.
-       SWI_SYS_SIGRETURN    -> (0xeb0e0a64)
-       SWI_SYS_RT_SIGRETURN -> (0xab150a64)
      FIXME: Currently we only handle little endian (EL) case.  */
-  if (pc[0] == SIGRETURN || pc[0] == RT_SIGRETURN)
+  if (pc[0] == RT_SIGRETURN)
     {
       /* Using '_sigfame' memory address to locate kernal's sigcontext.
         The sigcontext structures in arch/nds32/include/asm/sigcontext.h.  */
       struct _rt_sigframe *rt_;
       rt_ = context->cfa;
-      sc_ = &rt_->sig.uc.uc_mcontext;
+      sc_ = &rt_->uc.uc_mcontext;
     }
   else
     return _URC_END_OF_STACK;