From: Cyril Hrubis <chrubis@suse.cz>
To: Vasileios Almpanis <vasileios.almpanis@virtuozzo.com>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] [PATCH 2/2] memcg: scale memcontrol03 checkpoint timeouts for slow kernels
Date: Wed, 1 Apr 2026 12:44:11 +0200 [thread overview]
Message-ID: <acz2-zdwe7K58lzW@yuki.lan> (raw)
In-Reply-To: <acz1ZwkNHRFjnJ1_@yuki.lan>
Hi!
> > +#define CHECKPOINT_TIMEOUT_MS (tst_multiply_timeout(10) * 1000)
>
> Wouldn't it make more sense to use the tst_multiply_timeout() directly
> in the checkpoint library and hide that complexity from the tests?
If I'm not missing something it should be as easy as:
diff --git a/lib/tst_checkpoint.c b/lib/tst_checkpoint.c
index f2faf6563..82f6ab87c 100644
--- a/lib/tst_checkpoint.c
+++ b/lib/tst_checkpoint.c
@@ -37,6 +37,8 @@ int tst_checkpoint_wait(unsigned int id, unsigned int msec_timeout)
return -1;
}
+ msec_timeout = tst_multiply_timeout(msec_timeout);
+
timeout.tv_sec = msec_timeout/1000;
timeout.tv_nsec = (msec_timeout%1000) * 1000000;
@@ -61,6 +63,8 @@ int tst_checkpoint_wake(unsigned int id, unsigned int nr_wake,
return -1;
}
+ msec_timeout = tst_multiply_timeout(msec_timeout);
+
for (;;) {
waked += syscall(SYS_futex, &tst_futexes[id], FUTEX_WAKE,
INT_MAX, NULL);
And with that ALL checkpoints timeouts will be increased on slow
machines.
--
Cyril Hrubis
chrubis@suse.cz
--
Mailing list info: https://lists.linux.it/listinfo/ltp
prev parent reply other threads:[~2026-04-01 10:44 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-30 10:20 [LTP] [PATCH 0/2] configurable wake timeout and memcontrol03 fixes Vasileios Almpanis via ltp
2026-03-30 10:20 ` [LTP] [PATCH 1/2] lib/checkpoint: add configurable timeout for checkpoint wake Vasileios Almpanis via ltp
2026-04-02 9:57 ` [LTP] [PATCH v2 1/1] lib: scale checkpoint wait/wake timeouts with tst_multiply_timeout() Vasileios Almpanis via ltp
2026-04-02 12:52 ` Cyril Hrubis
2026-04-02 20:11 ` Petr Vorel
2026-04-08 8:44 ` Li Wang via ltp
2026-03-30 10:20 ` [LTP] [PATCH 2/2] memcg: scale memcontrol03 checkpoint timeouts for slow kernels Vasileios Almpanis via ltp
2026-04-01 10:37 ` Cyril Hrubis
2026-04-01 10:44 ` Cyril Hrubis [this message]
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=acz2-zdwe7K58lzW@yuki.lan \
--to=chrubis@suse.cz \
--cc=ltp@lists.linux.it \
--cc=vasileios.almpanis@virtuozzo.com \
/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.