Hi!
> >> +#if defined __x86_64__ || defined __sparc__
> >> +
> >>   struct kernel_sigaction {
> >>    __sighandler_t k_sa_handler;
> >>    unsigned long sa_flags;
> >> @@ -118,7 +155,7 @@ static inline int sig_initial(int sig)
> >>
> >>   }
> >>
> >> -#endif /* __x86_64__ */
> >> +#endif /* __x86_64__ || __sparc__*/
> >>
> >>   #endif /* LTP_RT_SIG_TEST */
> >>
> >> diff --git a/testcases/kernel/syscalls/rt_sigaction/rt_sigaction01.c 
> >> b/testcases/kernel/syscalls/rt_sigaction/rt_sigaction01.c
> >> index 8f18394..2f8020e 100644
> >> --- a/testcases/kernel/syscalls/rt_sigaction/rt_sigaction01.c
> >> +++ b/testcases/kernel/syscalls/rt_sigaction/rt_sigaction01.c
> >> @@ -1,5 +1,6 @@
> >>   
> >> /******************************************************************************/
> >>   /* Copyright (c) Crackerjack Project., 2007                              
> >>      */
> >> +/* Copyright (c) 2014 Oracle and/or its affiliates. All Rights Reserved.  
> >>     */
> >>   /*                                                                       
> >>      */
> >>   /* This program is free software;  you can redistribute it and/or modify 
> >>      */
> >>   /* it under the terms of the GNU General Public License as published by  
> >>      */
> >> @@ -127,21 +128,42 @@ void handler(int sig)
> >>
> >>   int set_handler(int sig, int sig_to_mask, int mask_flags)
> >>   {
> >> -#ifdef __x86_64__
> >> +#ifdef __sparc__
> >> +  struct sigaction sa;
> >> +  struct kernel_sigaction kact, koact;
> >> +# ifdef __arch64__
> >> +  unsigned long stub = ((unsigned long) &__rt_sigreturn_stub) - 8;
> >> +# else
> >> +  unsigned long stub = ((unsigned long) &__sigreturn_stub) - 8;
> >> +# endif
> >
> > These ifdefs are repeated in the lines below over and over, can we put
> > them in a common header instead?
> >
> 
> Do you mean just 'these ifdefs':
> +# ifdef __arch64__
> +     unsigned long stub = ((unsigned long) &__rt_sigreturn_stub) - 8;
> +# else
> +     unsigned long stub = ((unsigned long) &__sigreturn_stub) - 8;
> +# endif

At least these, ideally all the common syscall preparation should be in
one header included in all tests.

-- 
Cyril Hrubis
chru...@suse.cz

------------------------------------------------------------------------------
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.
Get unparalleled scalability from the best Selenium testing platform available
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to