]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
libunwind: refresh ppc32/musl patch
authorRoss Burton <ross.burton@arm.com>
Fri, 25 Apr 2025 11:43:19 +0000 (12:43 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 29 Apr 2025 08:54:15 +0000 (09:54 +0100)
There was a precedence order problem in the patch so update to the latest
version in the pull request.

Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-support/libunwind/libunwind/0005-Handle-musl-on-PPC32.patch

index 7cad7a5b7568f13474db6d85be0e6940a0bb2142..63d3c85de49e50b1c939dfa9271a99e88fbae7f8 100644 (file)
@@ -30,9 +30,9 @@ index 9444cbb8..5e94ed8a 100644
  
 +/* glibc and musl disagree over the layout of this struct */
 +#ifdef __GLIBC__
-+#define _UC_MCONTEXT_REGS(x) x->uc_mcontext.uc_regs
++#define _UCONTEXT_UC_REGS(uc) uc->uc_mcontext.uc_regs
 +#else
-+#define _UC_MCONTEXT_REGS(x) x->uc_regs
++#define _UCONTEXT_UC_REGS(uc) uc->uc_regs
 +#endif
 +
  static void *
@@ -43,7 +43,7 @@ index 9444cbb8..5e94ed8a 100644
    if ((unsigned) (reg - UNW_PPC32_R0) < 32)
  #if defined(__linux__)
 -    addr = &uc->uc_mcontext.uc_regs->gregs[reg - UNW_PPC32_R0];
-+    addr = _UC_MCONTEXT_REGS(&uc)->gregs[reg - UNW_PPC32_R0];
++    addr = &_UCONTEXT_UC_REGS(uc)->gregs[reg - UNW_PPC32_R0];
  #elif defined(__FreeBSD__)
      addr = &uc->uc_mcontext.mc_gpr[reg - UNW_PPC32_R0];
  #endif
@@ -52,7 +52,7 @@ index 9444cbb8..5e94ed8a 100644
         ((unsigned) (reg - UNW_PPC32_F0) >= 0) )
  #if defined(__linux__)
 -    addr = &uc->uc_mcontext.uc_regs->fpregs.fpregs[reg - UNW_PPC32_F0];
-+    addr = _UC_MCONTEXT_REGS(&uc)->fpregs.fpregs[reg - UNW_PPC32_F0];
++    addr = &_UCONTEXT_UC_REGS(uc)->fpregs.fpregs[reg - UNW_PPC32_F0];
   #elif defined(__FreeBSD__)
      addr = &uc->uc_mcontext.mc_fpreg[reg - UNW_PPC32_F0];
  #endif
@@ -61,7 +61,7 @@ index 9444cbb8..5e94ed8a 100644
          }
  #if defined(__linux__)
 -      addr = &uc->uc_mcontext.uc_regs->gregs[gregs_idx];
-+      addr = _UC_MCONTEXT_REGS(&uc)->gregs[gregs_idx];
++      addr = &_UCONTEXT_UC_REGS(uc)->gregs[gregs_idx];
  #elif defined(__FreeBSD__)
        addr = &uc->uc_mcontext.mc_gpr[gregs_idx];
  #endif