All of lore.kernel.org
 help / color / mirror / Atom feed
From: Romain Lenglet <rlenglet@domain.hid>
To: xenomai@xenomai.org
Subject: Re: [Xenomai-core] [patch] fix xeno-test for busybox
Date: Wed, 13 Sep 2006 15:59:28 +0900	[thread overview]
Message-ID: <200609131559.28562.rlenglet@domain.hid> (raw)
In-Reply-To: <200609131555.08997.rlenglet@domain.hid>

[-- Attachment #1: Type: text/plain, Size: 1536 bytes --]

Romain Lenglet wrote:
> Romain Lenglet wrote:
> > Gilles Chanteperdrix wrote:
> > > Jan Kiszka wrote:
> > >  > Jan Kiszka wrote:
> > >  > > Hi,
> > >  > >
> > >  > > I just tried to fire up xeno-test on a busybox system
> > >  > > - without success. Reason: missing getopts. But
> > >  > > busybox initial test checks for something else,
> > >  > > namely getopt. The attached patch should fix this it,
> > >  > > also taking into account that getopts in a shell
> > >  > > built-in, not an applet.
> > >  >
> > >  > Another quirk: switchtest runs with hard-wired -T
> > >  > 120...
> > >
> > > Could you try the attached patch ?
> >
> > Dumb question about your patch...
> > Shouldn't you keep the -T option in the $pass variable, to
> > pass it to latency?
> >
> >         T) timeout=$OPTARG
> >             pass="$pass -T $timeout" ;;
>
> The problem is that, if you don't put it in $pass, you must
> re-pass the latency option explicitly when logging, since it
> is no more in $pass, and is not in $loadpass. Otherwise,
>
> script -c "`dirname $0`/xeno-test $loadpass $pass $*" $wfile
>
> should become:
>
> script -c "`dirname $0`/xeno-test $loadpass $pass -T $latency
> $*" $wfile
>
>
> Therefore, I propose a slightly different patch. The -T option
> may be duplicated in $opts, but hopefully this is not a
> problem with the latency command?

A patch that avoid duplicating the -T option.

-- 
Romain LENGLET

-- 
Romain LENGLET
Pr. Chiba Shigeru Group
Dept. of Mathematical and Computing Sciences
Tokyo Institute of Technology

[-- Attachment #2: xeno-test-timeout.diff --]
[-- Type: text/x-diff, Size: 1717 bytes --]

--- xeno-test.in.orig	2006-09-13 15:49:31.000000000 +0900
+++ xeno-test.in	2006-09-13 15:58:13.000000000 +0900
@@ -24,6 +24,8 @@
   -v		verbose
   -M <email>	sends output to given addr
   -m		sends output to xenomai-data@domain.hid
+  -T <sec test> do not run each test for more than <sec test> seconds (defaults
+		to 120 seconds)
   -U <url>	uploads output to given URL
   -D <datefmt>	alternate options to date, for timestamp (dflt: 
 
@@ -31,7 +33,6 @@
   -s	print statistics of sampled data (default on)
   -h	print histogram of sampled data (default on, implies -s)
   -q	quiet, dont print 1 sec sampled data (default on, off if !-T)
-  -T <sec test>		 (default: 120 sec)
   -l <data/header lines> (default 21)
   -H <bucketcount>	 (default 100)
   -B <bucketsize ns>	 (default 1000 ns)
@@ -186,10 +187,13 @@
     fi
 }
 
+timeoutset=n
+timeout=120
 
 run_w_load() {
     local opts="$*";
-    [ "$opts"  = '' ] && opts='-sh -T 120'
+    [ "$opts"  = '' ] && opts='-sh'
+    [ "$timeoutset" = 'n' ] && opts="$opts -T $timeout"
 
     boxinfo
     loudly generate_loads $workload
@@ -201,7 +205,7 @@
 	loudly ./run -- $XENOT_LATENCY $opts -t2 '# latency'
     )
     (	cd `dirname $0`/../testsuite/switchtest
-	loudly ./run -- -T 120 $XENOT_SWITCHTEST '# switchtest'
+	loudly ./run -- -T $timeout $XENOT_SWITCHTEST '# switchtest'
     )
     (	cd `dirname $0`/../testsuite/switchbench
 	loudly ./run -- -h $XENOT_SWITCHBENCH '# switchbench'
@@ -280,9 +284,13 @@
 	# latency passthrus
 	s|h|q)
 	    pass="$pass -$FOO" ;;
-	T|l|H|B|p)
+	l|H|B|p)
 	    pass="$pass -$FOO $OPTARG" ;;
 
+	T) timeout=$OPTARG 
+	    timeoutset=y
+	    pass="$pass -T $timeout" ;;
+
 	# workload related
 	d) 
 	    device=$OPTARG    

  reply	other threads:[~2006-09-13  6:59 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-12 16:56 [Xenomai-core] [patch] fix xeno-test for busybox Jan Kiszka
2006-09-12 17:00 ` Jan Kiszka
2006-09-13  5:39   ` Gilles Chanteperdrix
2006-09-13  6:35     ` Romain Lenglet
2006-09-13  6:55       ` Romain Lenglet
2006-09-13  6:59         ` Romain Lenglet [this message]
2006-09-13  6:38     ` Gilles Chanteperdrix
2006-09-12 19:05 ` Niklaus Giger
2006-09-12 19:11   ` Jan Kiszka
2006-09-12 19:47     ` Niklaus Giger
2006-09-12 20:58       ` Jan Kiszka

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200609131559.28562.rlenglet@domain.hid \
    --to=rlenglet@domain.hid \
    --cc=xenomai@xenomai.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.