This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH 07/12] tapset: fix build if arch does not define SA_RESTORER


Signed-off-by: Marcin Nowakowski <marcin.nowakowski@imgtec.com>
---
 tapset/linux/aux_syscalls.stp | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/tapset/linux/aux_syscalls.stp b/tapset/linux/aux_syscalls.stp
index c49e804..527b43b 100644
--- a/tapset/linux/aux_syscalls.stp
+++ b/tapset/linux/aux_syscalls.stp
@@ -3405,7 +3405,9 @@ static void _stp_sigaction_str(struct sigaction *act, char *ptr, int len)
     V(SA_RESTART),
     V(SA_NODEFER),
     V(SA_SIGINFO),
+#ifdef SA_RESTORER
     V(SA_RESTORER),
+#endif
     {0, NULL}
   };
   
@@ -3417,7 +3419,7 @@ static void _stp_sigaction_str(struct sigaction *act, char *ptr, int len)
       strlcat (ptr, ", ", len);
       _stp_lookup_or_str(_stp_sa_flags_list, act->sa_flags, ptr, len);
       strlcat (ptr, ", ", len);
-#if !defined (__ia64__)
+#if !defined (__ia64__) && !defined (__mips__)
       slen = strlen(ptr);
       _stp_snprintf(ptr + slen, len - slen,
 		    "0x%lx, ", (long)act->sa_restorer);
@@ -3487,8 +3489,9 @@ function _struct_sigaction32_u:string(uaddr:long)
 
 	  act.sa_handler = (void *)compat_ptr(act32.sa_handler);
 	  act.sa_flags = (unsigned long)act32.sa_flags;
+#ifdef SA_RESTORER
 	  act.sa_restorer = (void *)compat_ptr(act32.sa_restorer);
-
+#endif
 	  /* swap words around to get right endian order. */
 	  switch (_NSIG_WORDS)
 	    {
@@ -3541,7 +3544,9 @@ function _struct_old_sigaction32_u:string(uaddr:long)
 	  struct sigaction act;
 
 	  act.sa_handler = (void *)compat_ptr(act32.sa_handler);
+#ifdef SA_RESTORER
 	  act.sa_restorer = (void *)compat_ptr(act32.sa_restorer);
+#endif
 	  act.sa_flags = (unsigned long)act32.sa_flags;
 	  siginitset(&act.sa_mask, act32.sa_mask);
 	  _stp_sigaction_str(&act, STAP_RETVALUE, MAXSTRINGLEN);	  
-- 
2.7.4


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]