From: linuxtestproject.agent@gmail.com
To: Cyril Hrubis <chrubis@suse.cz>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] syscalls: Add epoll_create03
Date: Thu, 9 Jul 2026 10:44:03 +0000 [thread overview]
Message-ID: <20260709104403.4345-1-linuxtestproject.agent@gmail.com> (raw)
In-Reply-To: <20260709085353.345957-2-chrubis@suse.cz>
Hi Cyril,
On Thu, 09 Jul 2026 10:53:45 +0200, Cyril Hrubis wrote:
> syscalls: Add epoll_create03
--- [PATCH 1/9] ---
> /*\
> * Verify that :manpage:epoll_create() fails with EMFILE when the per-process
> * limit on the number of open file descriptors has been reached.
> */
The :manpage: role is missing backticks and the section number. Should
be :manpage:`epoll_create(2)`.
--- [PATCH 2/9] ---
> /*\
> * Verify that :manpage:epoll_wait() fails with EINTR when a signal arrives
> * while waiting for events.
> *
> * [Algorithm]
> *
> * - Create an epoll instance
> * - Fork a child that waits in the :manpage:epoll_wait(), parents sends
> * SIGUSR1 to interrupt it.
> * - Verify that :manpage:epoll_wait() returns -1 with errno set to EINTR.
> */
Three occurrences of :manpage:epoll_wait() are missing backticks and
the section number. Each should be :manpage:`epoll_wait(2)`.
"parents sends" should be "parent sends".
> TST_EXP_FAIL(epoll_wait(efd, &ev, 1, -1), EINTR,
> "epoll_wait() interrupted by signal");
TST_EXP_FAIL is for syscalls that return 0 on success. epoll_wait()
returns a non-negative event count on success, so TST_EXP_FAIL2 is
the appropriate macro here.
In this particular setup it makes no practical difference (no fds
registered, infinite timeout), but using the wrong variant produces a
misleading error message if the expectation is ever violated.
--- [PATCH 3/9] ---
> /*\
> * Verify that :manpage:epoll_wait() works with nested epoll instances up to
> * the maximum nesting depth of 5 allowed by the kernel (EP_MAX_NESTS).
> *
> * [Algorithm]
> *
> * ...
> * - Call :manpage:epoll_wait() on the outermost epoll instance and verify it
Two occurrences of :manpage:epoll_wait() are missing backticks and the
section number. Should be :manpage:`epoll_wait(2)`.
--- [PATCH 4/9] ---
> /*\
> * Verify :manpage:epoll_ctl() EPOLL_CTL_ADD behavior across all file
> * descriptor types.
The :manpage: role is missing backticks and the section number. Should
be :manpage:`epoll_ctl(2)`.
--- [PATCH 5/9] ---
> /*\
> * Verify that :manpage:epoll_wait() with EPOLLPRI detects changes to
> * /proc/mounts.
The :manpage: role is missing backticks and the section number. Should
be :manpage:`epoll_wait(2)`.
--- [PATCH 6/9] ---
> /*\
> * Verify that :manpage:epoll_wait() reports EPOLLHUP when the write end of a
> * pipe is closed while a child process is blocked in epoll_wait.
> *
> * [Algorithm]
> *
> * ...
> * - The child's :manpage:epoll_wait() should return with EPOLLHUP.
Two occurrences of :manpage:epoll_wait() are missing backticks and the
section number. Should be :manpage:`epoll_wait(2)`.
--- [PATCH 7/9] ---
> rval = poll(fds, nfds, timeout);
> if (rval == -1) {
> tst_brk_(file, lineno, TBROK | TERRNO,
> "poll(%p, %li, %i) failed", fds, (long)nfds, timeout);
> } else if (rval < -1) {
> tst_brk_(file, lineno, TBROK | TERRNO,
> "Invalid poll(%p, %li, %i) return value %i",
> fds, (long)nfds, timeout, rval);
> }
poll() returns -1 on error or >= 0 on success; it cannot return a
value less than -1. The else-if branch is dead code.
The nearby safe_statvfs() uses "else if (rval)" to catch unexpected
non-zero returns for a function that is 0 on success. poll() returns
0 (timeout) and positive values (events ready) as normal outcomes, so
no such secondary check applies here. The body should just have the
rval == -1 guard and return rval.
> int safe_poll(const char *const file, const int lineno, struct pollfd *fds,
> nfds_t nfds, int timeout);
> #define SAFE_POLL(fds, nfds, timeout) \
> safe_poll(__FILE__, __LINE__, (fds), (nfds), (timeout))
New public functions in include/ must be documented with kernel-doc
syntax. A /** ... */ block covering the parameters and return value
is required.
--- [PATCH 8/9] ---
> /*\
> * Verify that :manpage:epoll_wait() reports EPOLLERR when the read end of a
> * pipe is closed while a child process is blocked in epoll_wait on the write
> * end.
> *
> * [Algorithm]
> *
> * ...
> * - The child's :manpage:epoll_wait() should return with EPOLLERR set.
Two occurrences of :manpage:epoll_wait() are missing backticks and the
section number. Should be :manpage:`epoll_wait(2)`.
--- [PATCH 9/9] ---
> Now that the epoll coverate is greater than it ever was we can remove
"coverate" should be "coverage".
> Fixes: https://github.com/linux-test-project/ltp/issues/860
The Fixes: tag must reference a commit hash in the local git history,
not a URL. For a GitHub issue reference use Closes: instead.
Verdict - Needs revision
---
Note:
The agent can sometimes produce false positives although often its
findings are genuine. If you find issues with the review, please
comment this email or ignore the suggestions.
Regards,
LTP AI Reviewer
--
Mailing list info: https://lists.linux.it/listinfo/ltp
next prev parent reply other threads:[~2026-07-09 10:44 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-09 8:53 [LTP] [PATCH v3 0/9] Add more epoll tests Cyril Hrubis
2026-07-09 8:53 ` [LTP] [PATCH v3 1/9] syscalls: Add epoll_create03 Cyril Hrubis
2026-07-09 10:44 ` linuxtestproject.agent [this message]
2026-07-09 14:03 ` [LTP] " Cyril Hrubis
2026-07-09 10:51 ` [LTP] [PATCH v3 1/9] " Petr Vorel
2026-07-09 11:17 ` Petr Vorel
2026-07-09 12:54 ` Cyril Hrubis
2026-07-09 13:40 ` Cyril Hrubis
2026-07-09 14:56 ` Petr Vorel
2026-07-14 9:20 ` Cyril Hrubis
2026-07-09 8:53 ` [LTP] [PATCH v3 2/9] syscalls: Add epoll_wait08 Cyril Hrubis
2026-07-10 6:15 ` Petr Vorel
2026-07-14 9:24 ` Cyril Hrubis
2026-07-09 8:53 ` [LTP] [PATCH v3 3/9] syscalls: Add epoll_wait09 Cyril Hrubis
2026-07-10 6:41 ` Petr Vorel
2026-07-14 9:35 ` Cyril Hrubis
2026-07-09 8:53 ` [LTP] [PATCH v3 4/9] syscalls: Add epoll_ctl06 Cyril Hrubis
2026-07-10 6:25 ` Petr Vorel
2026-07-14 9:44 ` Cyril Hrubis
2026-07-09 8:53 ` [LTP] [PATCH v3 5/9] syscalls: Add epoll_wait10 Cyril Hrubis
2026-07-10 6:55 ` Petr Vorel
2026-07-14 10:11 ` Cyril Hrubis
2026-07-09 8:53 ` [LTP] [PATCH v3 6/9] syscalls: Add epoll_wait11 Cyril Hrubis
2026-07-10 7:01 ` Petr Vorel
2026-07-14 10:16 ` Cyril Hrubis
2026-07-09 8:53 ` [LTP] [PATCH v3 7/9] SAFE_MACROS: Add SAFE_POLL() Cyril Hrubis
2026-07-10 7:05 ` Petr Vorel
2026-07-14 8:07 ` Andrea Cervesato via ltp
2026-07-14 8:33 ` Andrea Cervesato via ltp
2026-07-14 10:34 ` Cyril Hrubis
2026-07-09 8:53 ` [LTP] [PATCH v3 8/9] syscalls: Add epoll_wait12 Cyril Hrubis
2026-07-10 7:27 ` Petr Vorel
2026-07-14 11:47 ` Cyril Hrubis
2026-07-09 8:53 ` [LTP] [PATCH v3 9/9] syscalls: Remove old epoll-ltp test Cyril Hrubis
2026-07-10 7:30 ` Petr Vorel
2026-07-14 11:48 ` Cyril Hrubis
-- strict thread matches above, loose matches on Subject: below --
2026-04-23 12:03 [LTP] [PATCH v2 1/8] syscalls: Add epoll_create03 Cyril Hrubis
2026-04-23 13:43 ` [LTP] " linuxtestproject.agent
2026-04-23 9:58 [LTP] [PATCH 1/8] " Cyril Hrubis
2026-04-23 11:17 ` [LTP] " linuxtestproject.agent
2026-04-23 11:47 ` 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=20260709104403.4345-1-linuxtestproject.agent@gmail.com \
--to=linuxtestproject.agent@gmail.com \
--cc=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