From: Petr Vorel <pvorel@suse.cz>
To: Li Wang <liwang@redhat.com>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] [PATCH] shell: Add support for runtime
Date: Thu, 20 Nov 2025 14:33:13 +0100 [thread overview]
Message-ID: <20251120133313.GA318945@pevik> (raw)
In-Reply-To: <CAEemH2f87qUSNZ0u5uFBPeZ=DrZLjcvtGFGZGzvpgwhzeaVuSA@mail.gmail.com>
Hi Cyril, Li,
LGTM
Reviewed-by: Petr Vorel <pvorel@suse.cz>
> > +++ b/testcases/lib/tests/shell_loader_filesystems.sh
> > @@ -6,6 +6,7 @@
> > # env
> > # {
> > # "mount_device": true,
> > +# "runtime": 10,
> > # "mntpoint": "ltp_mntpoint",
> > # "filesystems": [
> > # {
> > @@ -38,6 +39,14 @@ tst_test()
> > else
> > tst_res TFAIL "Device not mounted!"
> > fi
> > +
> > + RUNTIME=$(tst_remaining_runtime)
> > +
> > + if [ "$RUNTIME" -ge 9 ]; then
> > + tst_res TPASS "Remaining runtime $RUNTIME"
> > + else
> > + tst_res TFAIL "Remaning runtime $RUNTIME"
> Typo -> s/Remaning/Remaining
+1
> > + fi
> > }
..
> > +++ b/testcases/lib/tst_run_shell.c
> > @@ -60,6 +60,7 @@ enum test_attr_ids {
> > MIN_CPUS,
> > MIN_MEM_AVAIL,
> > MIN_KVER,
> > + MIN_RUNTIME,
> > MIN_SWAP_AVAIL,
> > MNTPOINT,
> > MOUNT_DEVICE,
> > @@ -74,6 +75,7 @@ enum test_attr_ids {
> > NEEDS_ROOT,
> > NEEDS_TMPDIR,
> > RESTORE_WALLCLOCK,
> > + RUNTIME,
> Do we need to add a flexible TIMEOUT in shell support as well?
> The default TST_TIMEOUT in SHELL is 300, which is not consistent with C
300 s (5 min) is for tst_test.sh API. C API has 120 s (2 min), therefore that's
the default also for the shell loader API (the newest shell API).
And this specific test has 2 min 10 sec (due runtime 10).
The longer timeout is due Tumbleweed having CONFIG_FAULT_INJECTION, otherwise
it'd be 30 s (or 40 s for the test). I'm still not convinced that
CONFIG_FAULT_INJECTION itself should give 4x longer timeout for all
Tumbleweed/SLES testing. But that's something else, not relevant to the patch.
Kind regards,
Petr
> method (DEFAULT_TIMEOUT + tst_test->timeout).
> Anyway, this patch itself looks good:
> Reviewed-by: Li Wang <liwang@redhat.com>
--
Mailing list info: https://lists.linux.it/listinfo/ltp
next prev parent reply other threads:[~2025-11-20 13:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-19 9:31 [LTP] [PATCH] shell: Add support for runtime Cyril Hrubis
2025-11-20 7:32 ` Li Wang via ltp
2025-11-20 13:33 ` Petr Vorel [this message]
2025-11-24 12:23 ` Cyril Hrubis
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=20251120133313.GA318945@pevik \
--to=pvorel@suse.cz \
--cc=liwang@redhat.com \
--cc=ltp@lists.linux.it \
/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.