From: Cyril Hrubis <chrubis@suse.cz>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH 2/3] epoll_pwait2: Add test for epoll_pwait201
Date: Mon, 12 Jul 2021 14:23:54 +0200 [thread overview]
Message-ID: <YOw0WvldeLvW+gA5@yuki> (raw)
In-Reply-To: <20210628080424.245911-3-xieziyao@huawei.com>
Hi!
> +static void run(void)
> +{
> + TEST(tst_syscall(__NR_epoll_pwait2, efd, &e, 1, NULL, NULL, 0));
It would be better to put the prototype for epoll_pwait2 into
include/lapi/epoll.h.
Also given that the difference between epoll_pwait() and epoll_pwait2()
is only in the timeout parameter type it would make much more sense to
write these tests with two test variants so that we would cover both
epoll_pwait() and epoll_wait2().
I would have put these tests into epoll_wait/ directory and added
epoll_var.h that would make a common wrapper for both of these
functions. We do this for example for select in select/select_var.h but
in this case this would be much easier, I guess that the wrapper would
get timespec structure and convert that to miliseconds for
epoll_pwait().
--
Cyril Hrubis
chrubis@suse.cz
next prev parent reply other threads:[~2021-07-12 12:23 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-28 8:04 [LTP] [PATCH 0/3] epoll_pwait2: Add test for epoll_pwait2 Xie Ziyao
2021-06-28 8:04 ` [LTP] [PATCH 1/3] lapi/syscalls: Add syscall number " Xie Ziyao
2021-06-28 8:04 ` [LTP] [PATCH 2/3] epoll_pwait2: Add test for epoll_pwait201 Xie Ziyao
2021-07-12 12:23 ` Cyril Hrubis [this message]
2021-07-16 10:22 ` [LTP] [PATCH 0/5 v2] epoll_pwait2: Add test for epoll_pwait2 Xie Ziyao
2021-07-16 10:22 ` [LTP] [PATCH 1/5 v2] lapi/syscalls: Add syscall number " Xie Ziyao
2021-07-16 10:22 ` [LTP] [PATCH 2/5 v2] lapi: Add the prototype for epoll_pwait and epoll_pwait2 Xie Ziyao
2021-07-16 10:22 ` [LTP] [PATCH 3/5 v2] epoll_pwait: Add test variants for epoll_pwait Xie Ziyao
2021-07-16 10:22 ` [LTP] [PATCH 4/5 v2] epoll_pwait: Add test for epoll_pwait02 Xie Ziyao
2021-07-16 10:22 ` [LTP] [PATCH 5/5 v2] epoll_pwait: Add test for epoll_pwait03 Xie Ziyao
2021-07-19 13:45 ` [LTP] [PATCH 0/5 v2] epoll_pwait2: Add test for epoll_pwait2 Cyril Hrubis
2021-07-20 6:57 ` Xie Ziyao
2021-06-28 8:04 ` [LTP] [PATCH 3/3] epoll_pwait2: Add test for epoll_pwait202 Xie Ziyao
2021-07-12 12:25 ` Cyril Hrubis
2021-06-28 8:12 ` [LTP] [PATCH 0/3] epoll_pwait2: Add test for epoll_pwait2 Xie Ziyao
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=YOw0WvldeLvW+gA5@yuki \
--to=chrubis@suse.cz \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox