public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH] Re::personality test case build fails
@ 2009-06-25 11:34 Subrata Modak
  2009-06-30  7:41 ` Subrata Modak
  0 siblings, 1 reply; 9+ messages in thread
From: Subrata Modak @ 2009-06-25 11:34 UTC (permalink / raw)
  To: Pradeep K Surisetty; +Cc: ltp-list, James Takahashi

Hi Pradeep,

>On Tue, 2009-06-23 at 18:39 +0530, Pradeep K Surisetty wrote:
>Here is the list of platforms on which "personality test case" fails.
> 
> Platforms:
> e326,x366
> 
> kernel:
> 2.6.16.60-0.46.6-smp
> 
> Build Failure:
> 
> cc -I../../../../include -Wall    personality01.c  -L../../../../lib -lltp
> -o personality01
> /tmp/cc2aVCsG.o: In function `main':
> personality01.c:(.text+0x58): undefined reference to `personality'
> personality01.c:(.text+0xb6): undefined reference to `personality'
> personality01.c:(.text+0x1a5): undefined reference to `personality'
> collect2: ld returned 1 exit status
> make: *** [personality01] Error 1
> 
> Subrata,
> Can you point me, if any work around exists for this.

The following patch will probably fix the issue on your system. Please
test this patch and let me know.

Signed-off-by: Subrata Modak <subrata@linux.vnet.ibm.com>,
---

--- ltp-intermediate-20090622/testcases/kernel/syscalls/personality/personality01.c.orig	2009-06-25 16:45:55.000000000 +0530
+++ ltp-intermediate-20090622/testcases/kernel/syscalls/personality/personality01.c	2009-06-25 16:59:15.000000000 +0530
@@ -58,7 +58,7 @@
 #include "usctest.h"
 
 #include <errno.h>
-#include <linux/personality.h>
+#include <sys/personality.h>
 #undef personality
 
 extern int personality(unsigned long);
@@ -75,6 +75,7 @@ int pers[] = { PER_LINUX, PER_LINUX_32BI
 	PER_IRIX32, PER_IRIXN32, PER_IRIX64
 };
 
+#ifdef __NR_personality
 int main(int ac, char **av)
 {
 	int lc;			/* loop counter */
@@ -146,6 +147,13 @@ int main(int ac, char **av)
 
 	 /*NOTREACHED*/ return 0;
 }
+#else
+int main(int ac, char **av)
+{
+	tst_resm(TCONF, "personality() not defined in your system");
+	tst_exit();
+}
+#endif
 
 /*
  * setup() - performs all the ONE TIME setup for this test.
--- ltp-intermediate-20090622/testcases/kernel/syscalls/personality/personality02.c.orig	2009-06-25 16:46:02.000000000 +0530
+++ ltp-intermediate-20090622/testcases/kernel/syscalls/personality/personality02.c	2009-06-25 16:59:25.000000000 +0530
@@ -79,6 +79,7 @@ extern int Tst_count;
 
 #define	PER_BAD	0x00dd		/* A non-existent personality type */
 
+#ifdef __NR_personality
 int main(int ac, char **av)
 {
 	int lc;			/* loop counter */
@@ -128,6 +129,14 @@ int main(int ac, char **av)
 
 	 /*NOTREACHED*/ return 0;
 }
+#else
+int main(int ac, char **av)
+{
+	tst_resm(TCONF, "personality() not defined in your system");
+	tst_exit();
+}
+#endif
+
 
 /*
  * setup() - performs all the ONE TIME setup for this test.

---
Regards--
Subrata

> 
> -Pradeep
> 
> 

------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [LTP] [PATCH] Re::personality test case build fails
@ 2009-06-25 12:17 naresh kamboju
  2009-06-26 11:33 ` Subrata Modak
  0 siblings, 1 reply; 9+ messages in thread
From: naresh kamboju @ 2009-06-25 12:17 UTC (permalink / raw)
  To: Subrata Modak, Jiri Palecek, Pradeep K Surisetty; +Cc: ltp-list

Hi,

>+#ifdef __NR_personality
 >int main(int ac, char **av)
 >{

>+#else
>+int main(int ac, char **av)
>+{
>+       tst_resm(TCONF, "personality() not defined in your system");
>+       tst_exit();
>+}
>+#endif


Instead of using
#ifdef __NR_personality
 in test code, Better we will add these this syscall numbers in the
ltp/testcases/kernel/include/ARCHXXX.in files.
This can be Multi ARCH support.

Jiri,
I think you are doing Multi ARCH support right?

Your suggestions are welcome :)

Best regards
Naresh Kamboju

------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [LTP] [PATCH] Re::personality test case build fails
  2009-06-25 12:17 naresh kamboju
@ 2009-06-26 11:33 ` Subrata Modak
  2009-06-30  7:41   ` Subrata Modak
  0 siblings, 1 reply; 9+ messages in thread
From: Subrata Modak @ 2009-06-26 11:33 UTC (permalink / raw)
  To: naresh kamboju; +Cc: Jiri Palecek, Pradeep K Surisetty, ltp-list

On Thu, 2009-06-25 at 17:47 +0530, naresh kamboju wrote: 
> Hi,
> 
> >+#ifdef __NR_personality
>  >int main(int ac, char **av)
>  >{
> 
> >+#else
> >+int main(int ac, char **av)
> >+{
> >+       tst_resm(TCONF, "personality() not defined in your system");
> >+       tst_exit();
> >+}
> >+#endif
> 
> 
> Instead of using
> #ifdef __NR_personality
>  in test code, Better we will add these this syscall numbers in the
> ltp/testcases/kernel/include/ARCHXXX.in files.
> This can be Multi ARCH support.

Great. Send me a patch to update them all ;-)

Regards--
Subrata

> 
> Jiri,
> I think you are doing Multi ARCH support right?
> 
> Your suggestions are welcome :)
> 
> Best regards
> Naresh Kamboju


------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [LTP] [PATCH] Re::personality test case build fails
  2009-06-25 11:34 [LTP] [PATCH] Re::personality test case build fails Subrata Modak
@ 2009-06-30  7:41 ` Subrata Modak
  0 siblings, 0 replies; 9+ messages in thread
From: Subrata Modak @ 2009-06-30  7:41 UTC (permalink / raw)
  To: Pradeep K Surisetty; +Cc: ltp-list

On Thu, 2009-06-25 at 17:04 +0530, Subrata Modak wrote: 
> Hi Pradeep,
> 
> >On Tue, 2009-06-23 at 18:39 +0530, Pradeep K Surisetty wrote:
> >Here is the list of platforms on which "personality test case" fails.
> > 
> > Platforms:
> > e326,x366
> > 
> > kernel:
> > 2.6.16.60-0.46.6-smp
> > 
> > Build Failure:
> > 
> > cc -I../../../../include -Wall    personality01.c  -L../../../../lib -lltp
> > -o personality01
> > /tmp/cc2aVCsG.o: In function `main':
> > personality01.c:(.text+0x58): undefined reference to `personality'
> > personality01.c:(.text+0xb6): undefined reference to `personality'
> > personality01.c:(.text+0x1a5): undefined reference to `personality'
> > collect2: ld returned 1 exit status
> > make: *** [personality01] Error 1
> > 
> > Subrata,
> > Can you point me, if any work around exists for this.
> 
> The following patch will probably fix the issue on your system. Please
> test this patch and let me know.
> 
> Signed-off-by: Subrata Modak <subrata@linux.vnet.ibm.com>,

I checked in this.

Regards--
Subrata

> ---
> 
> --- ltp-intermediate-20090622/testcases/kernel/syscalls/personality/personality01.c.orig	2009-06-25 16:45:55.000000000 +0530
> +++ ltp-intermediate-20090622/testcases/kernel/syscalls/personality/personality01.c	2009-06-25 16:59:15.000000000 +0530
> @@ -58,7 +58,7 @@
>  #include "usctest.h"
> 
>  #include <errno.h>
> -#include <linux/personality.h>
> +#include <sys/personality.h>
>  #undef personality
> 
>  extern int personality(unsigned long);
> @@ -75,6 +75,7 @@ int pers[] = { PER_LINUX, PER_LINUX_32BI
>  	PER_IRIX32, PER_IRIXN32, PER_IRIX64
>  };
> 
> +#ifdef __NR_personality
>  int main(int ac, char **av)
>  {
>  	int lc;			/* loop counter */
> @@ -146,6 +147,13 @@ int main(int ac, char **av)
> 
>  	 /*NOTREACHED*/ return 0;
>  }
> +#else
> +int main(int ac, char **av)
> +{
> +	tst_resm(TCONF, "personality() not defined in your system");
> +	tst_exit();
> +}
> +#endif
> 
>  /*
>   * setup() - performs all the ONE TIME setup for this test.
> --- ltp-intermediate-20090622/testcases/kernel/syscalls/personality/personality02.c.orig	2009-06-25 16:46:02.000000000 +0530
> +++ ltp-intermediate-20090622/testcases/kernel/syscalls/personality/personality02.c	2009-06-25 16:59:25.000000000 +0530
> @@ -79,6 +79,7 @@ extern int Tst_count;
> 
>  #define	PER_BAD	0x00dd		/* A non-existent personality type */
> 
> +#ifdef __NR_personality
>  int main(int ac, char **av)
>  {
>  	int lc;			/* loop counter */
> @@ -128,6 +129,14 @@ int main(int ac, char **av)
> 
>  	 /*NOTREACHED*/ return 0;
>  }
> +#else
> +int main(int ac, char **av)
> +{
> +	tst_resm(TCONF, "personality() not defined in your system");
> +	tst_exit();
> +}
> +#endif
> +
> 
>  /*
>   * setup() - performs all the ONE TIME setup for this test.
> 
> ---
> Regards--
> Subrata
> 
> > 
> > -Pradeep
> > 
> > 


------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [LTP] [PATCH] Re::personality test case build fails
  2009-06-26 11:33 ` Subrata Modak
@ 2009-06-30  7:41   ` Subrata Modak
  2009-06-30  9:50     ` naresh kamboju
  0 siblings, 1 reply; 9+ messages in thread
From: Subrata Modak @ 2009-06-30  7:41 UTC (permalink / raw)
  To: naresh kamboju; +Cc: Jiri Palecek, Pradeep K Surisetty, ltp-list

On Fri, 2009-06-26 at 17:03 +0530, Subrata Modak wrote: 
> On Thu, 2009-06-25 at 17:47 +0530, naresh kamboju wrote: 
> > Hi,
> > 
> > >+#ifdef __NR_personality
> >  >int main(int ac, char **av)
> >  >{
> > 
> > >+#else
> > >+int main(int ac, char **av)
> > >+{
> > >+       tst_resm(TCONF, "personality() not defined in your system");
> > >+       tst_exit();
> > >+}
> > >+#endif
> > 
> > 
> > Instead of using
> > #ifdef __NR_personality
> >  in test code, Better we will add these this syscall numbers in the
> > ltp/testcases/kernel/include/ARCHXXX.in files.
> > This can be Multi ARCH support.
> 
> Great. Send me a patch to update them all ;-)
> 

Naresh ??

> Regards--
> Subrata
> 
> > 
> > Jiri,
> > I think you are doing Multi ARCH support right?
> > 
> > Your suggestions are welcome :)
> > 
> > Best regards
> > Naresh Kamboju
> 
> 
> ------------------------------------------------------------------------------
> _______________________________________________
> Ltp-list mailing list
> Ltp-list@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ltp-list


------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [LTP] [PATCH] Re::personality test case build fails
  2009-06-30  7:41   ` Subrata Modak
@ 2009-06-30  9:50     ` naresh kamboju
  2009-06-30 10:04       ` Subrata Modak
  0 siblings, 1 reply; 9+ messages in thread
From: naresh kamboju @ 2009-06-30  9:50 UTC (permalink / raw)
  To: subrata; +Cc: Jiri Palecek, Pradeep K Surisetty, ltp-list

On Tue, Jun 30, 2009 at 1:11 PM, Subrata
Modak<subrata@linux.vnet.ibm.com> wrote:
> On Fri, 2009-06-26 at 17:03 +0530, Subrata Modak wrote:
>> > >+#ifdef __NR_personality
>> >
>> > Instead of using
>> > #ifdef __NR_personality
>> >  in test code, Better we will add these this syscall numbers in the
>> > ltp/testcases/kernel/include/ARCHXXX.in files.
>> > This can be Multi ARCH support.
>> Great. Send me a patch to update them all ;-)
>>
>
> Naresh ??

Hi Subrata,

I have noticed some issue with personality01.c and personality02.c
test cases in design.
Currently I am investigating and get back to in short.

Best Regards
Naresh Kamboju

>
>> Regards--
>> Subrata
>>
>> > Jiri,
>> > I think you are doing Multi ARCH support right?
>> >
>> > Your suggestions are welcome :)
>> >
>> > Best regards
>> > Naresh Kamboju

>> ------------------------------------------------------------------------------
>> _______________________________________________
>> Ltp-list mailing list
>> Ltp-list@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/ltp-list
>
>

------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [LTP] [PATCH] Re::personality test case build fails
  2009-06-30  9:50     ` naresh kamboju
@ 2009-06-30 10:04       ` Subrata Modak
  2009-06-30 12:59         ` naresh kamboju
  0 siblings, 1 reply; 9+ messages in thread
From: Subrata Modak @ 2009-06-30 10:04 UTC (permalink / raw)
  To: naresh kamboju; +Cc: Jiri Palecek, Pradeep K Surisetty, ltp-list

On Tue, 2009-06-30 at 15:20 +0530, naresh kamboju wrote:
> On Tue, Jun 30, 2009 at 1:11 PM, Subrata
> Modak<subrata@linux.vnet.ibm.com> wrote:
> > On Fri, 2009-06-26 at 17:03 +0530, Subrata Modak wrote:
> >> > >+#ifdef __NR_personality
> >> >
> >> > Instead of using
> >> > #ifdef __NR_personality
> >> >  in test code, Better we will add these this syscall numbers in the
> >> > ltp/testcases/kernel/include/ARCHXXX.in files.
> >> > This can be Multi ARCH support.
> >> Great. Send me a patch to update them all ;-)
> >>
> >
> > Naresh ??
> 
> Hi Subrata,
> 
> I have noticed some issue with personality01.c and personality02.c
> test cases in design.

Great. And what design reviews for the newly ported tests in LTP ?

Regards--
Subrata

> Currently I am investigating and get back to in short.
> 
> Best Regards
> Naresh Kamboju
> 
> >
> >> Regards--
> >> Subrata
> >>
> >> > Jiri,
> >> > I think you are doing Multi ARCH support right?
> >> >
> >> > Your suggestions are welcome :)
> >> >
> >> > Best regards
> >> > Naresh Kamboju
> 
> >> ------------------------------------------------------------------------------
> >> _______________________________________________
> >> Ltp-list mailing list
> >> Ltp-list@lists.sourceforge.net
> >> https://lists.sourceforge.net/lists/listinfo/ltp-list
> >
> >


------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [LTP] [PATCH] Re::personality test case build fails
  2009-06-30 10:04       ` Subrata Modak
@ 2009-06-30 12:59         ` naresh kamboju
  2009-06-30 13:18           ` Subrata Modak
  0 siblings, 1 reply; 9+ messages in thread
From: naresh kamboju @ 2009-06-30 12:59 UTC (permalink / raw)
  To: subrata; +Cc: Jiri Palecek, Pradeep K Surisetty, ltp-list

>> >
>> > Naresh ??
>>
>> Hi Subrata,
>>
>> I have noticed some issue with personality01.c and personality02.c
>> test cases in design.
>
> Great. And what design reviews for the newly ported tests in LTP ?


The personality is different for diff ARCH and there are 23
personalities are available. present test case is design to support
X86 ARCH .Currently checking applicability and making the test cases
as generic to support most of the ARCH.

This is commented test cases under syscalls on ver 1.154

http://ltp.cvs.sourceforge.net/viewvc/ltp/ltp/runtest/syscalls?view=log


#  The personality() system call is poorly documented
#  and difficult to figure out how to use by looking
#  at the different architecture specific kernel files.
#personality01 personality01
#personality02 personality02

Subrata,

Do you want to include these test cases in this release?

If you have issues please let me know.

Best regards,
Naresh Kamboju

>
> Regards--
> Subrata
>
>> Currently I am investigating and get back to in short.
>>
>> Best Regards
>> Naresh Kamboju
>>
>> >
>> >> Regards--
>> >> Subrata
>> >>
>> >> > Jiri,
>> >> > I think you are doing Multi ARCH support right?
>> >> >
>> >> > Your suggestions are welcome :)
>> >> >
>> >> > Best regards
>> >> > Naresh Kamboju
>>
>> >> ------------------------------------------------------------------------------
>> >> _______________________________________________
>> >> Ltp-list mailing list
>> >> Ltp-list@lists.sourceforge.net
>> >> https://lists.sourceforge.net/lists/listinfo/ltp-list
>> >
>> >
>
>

------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [LTP] [PATCH] Re::personality test case build fails
  2009-06-30 12:59         ` naresh kamboju
@ 2009-06-30 13:18           ` Subrata Modak
  0 siblings, 0 replies; 9+ messages in thread
From: Subrata Modak @ 2009-06-30 13:18 UTC (permalink / raw)
  To: naresh kamboju; +Cc: Jiri Palecek, Pradeep K Surisetty, ltp-list

On Tue, Jun 30, 2009 at 6:29 PM, naresh kamboju<naresh.kernel@gmail.com> wrote:
>>> >
>>> > Naresh ??
>>>
>>> Hi Subrata,
>>>
>>> I have noticed some issue with personality01.c and personality02.c
>>> test cases in design.
>>
>> Great. And what design reviews for the newly ported tests in LTP ?
>
>
> The personality is different for diff ARCH and there are 23
> personalities are available. present test case is design to support
> X86 ARCH .Currently checking applicability and making the test cases
> as generic to support most of the ARCH.
>
> This is commented test cases under syscalls on ver 1.154
>
> http://ltp.cvs.sourceforge.net/viewvc/ltp/ltp/runtest/syscalls?view=log
>
>
> #  The personality() system call is poorly documented
> #  and difficult to figure out how to use by looking
> #  at the different architecture specific kernel files.
> #personality01 personality01
> #personality02 personality02
>
> Subrata,
>
> Do you want to include these test cases in this release?

Nope. Until they are fixed properly. Seems Robbie commented them long
back. But, these tests have been building fine for quite long time
without our knowledge, though they were not running.

Regards--
Subrata

>
> If you have issues please let me know.
>
> Best regards,
> Naresh Kamboju
>
>>
>> Regards--
>> Subrata
>>
>>> Currently I am investigating and get back to in short.
>>>
>>> Best Regards
>>> Naresh Kamboju
>>>
>>> >
>>> >> Regards--
>>> >> Subrata
>>> >>
>>> >> > Jiri,
>>> >> > I think you are doing Multi ARCH support right?
>>> >> >
>>> >> > Your suggestions are welcome :)
>>> >> >
>>> >> > Best regards
>>> >> > Naresh Kamboju
>>>
>>> >> ------------------------------------------------------------------------------
>>> >> _______________________________________________
>>> >> Ltp-list mailing list
>>> >> Ltp-list@lists.sourceforge.net
>>> >> https://lists.sourceforge.net/lists/listinfo/ltp-list
>>> >
>>> >
>>
>>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Ltp-list mailing list
> Ltp-list@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ltp-list
>



-- 
Regards & Thanks--
Subrata

------------------------------------------------------------------------------
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2009-06-30 13:19 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-25 11:34 [LTP] [PATCH] Re::personality test case build fails Subrata Modak
2009-06-30  7:41 ` Subrata Modak
  -- strict thread matches above, loose matches on Subject: below --
2009-06-25 12:17 naresh kamboju
2009-06-26 11:33 ` Subrata Modak
2009-06-30  7:41   ` Subrata Modak
2009-06-30  9:50     ` naresh kamboju
2009-06-30 10:04       ` Subrata Modak
2009-06-30 12:59         ` naresh kamboju
2009-06-30 13:18           ` Subrata Modak

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox