* Re: [PATCH bpf] bpf: fix selftest/xsk single test selection
2026-02-17 8:03 [PATCH bpf] bpf: fix selftest/xsk single test selection Mahdi Faramarzpour
@ 2026-02-17 8:40 ` bot+bpf-ci
2026-02-17 8:41 ` Mahdi Faramarzpour
2026-02-17 13:03 ` Maciej Fijalkowski
2 siblings, 0 replies; 4+ messages in thread
From: bot+bpf-ci @ 2026-02-17 8:40 UTC (permalink / raw)
To: mahdifrmx, bpf
Cc: magnus.karlsson, maciej.fijalkowski, sdf, andrii, eddyz87, ast,
daniel, martin.lau, song, yonghong.song, john.fastabend, kpsingh,
haoluo, jolsa, shuah, netdev, linux-kselftest, linux-kernel,
mahdifrmx, ast, andrii, daniel, martin.lau, eddyz87,
yonghong.song, clm, ihor.solodrai
[-- Attachment #1: Type: text/plain, Size: 747 bytes --]
> Signd-off-by: Mahdi Faramarzpour <mahdifrmx@gmail.com>
Should this be "Signed-off-by"?
---
AI reviewed your patch. Please fix the bug or email reply why it's not a bug.
See: https://github.com/kernel-patches/vmtest/blob/master/ci/claude/README.md
CI run summary: https://github.com/kernel-patches/bpf/actions/runs/22090844124
AI-authorship-score: low
AI-authorship-explanation: Natural writing style with human uncertainty markers and specific manpage citation suggest human authorship; the Signed-off-by typo is consistent with human error.
issues-found: 1
issue-severity-score: low
issue-severity-explanation: Misspelled Signed-off-by tag (Signd-off-by) breaks the Developer Certificate of Origin chain and automated tooling recognition.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH bpf] bpf: fix selftest/xsk single test selection
2026-02-17 8:03 [PATCH bpf] bpf: fix selftest/xsk single test selection Mahdi Faramarzpour
2026-02-17 8:40 ` bot+bpf-ci
@ 2026-02-17 8:41 ` Mahdi Faramarzpour
2026-02-17 13:03 ` Maciej Fijalkowski
2 siblings, 0 replies; 4+ messages in thread
From: Mahdi Faramarzpour @ 2026-02-17 8:41 UTC (permalink / raw)
To: bpf
Cc: Magnus Karlsson, Maciej Fijalkowski, Stanislav Fomichev,
Andrii Nakryiko, Eduard Zingerman, Alexei Starovoitov,
Daniel Borkmann, Martin KaFai Lau, Song Liu, Yonghong Song,
John Fastabend, KP Singh, Hao Luo, Jiri Olsa, Shuah Khan, netdev,
linux-kselftest, linux-kernel
On Tue, Feb 17, 2026 at 11:34 AM Mahdi Faramarzpour <mahdifrmx@gmail.com> wrote:
>
> From: Mahdi Faramarzpour <mahdifrmx@gmail.com>
>
> This commit fixes the integer parsing of -t option. The cli parser
> only relies on errno to detect parsing errors. The manpage for
> strtol (https://man7.org/linux/man-pages/man3/strtol.3.html)
> states that the said function "MAY" set errno to EINVAL in case the
> conversion fails. Currently on some systems, this leads to a silent
> failure with return value not being exactly documented in the
> manpages (probably zero). The reliable way to validate the input is
> to check whether the endptr has been bumped all the way to the end
> of the string or not.
>
> Signd-off-by: Mahdi Faramarzpour <mahdifrmx@gmail.com>
> Fixes: 146e30554a53 ("selftests/xsk: add option to run single test")
> ---
> tools/testing/selftests/bpf/xskxceiver.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/tools/testing/selftests/bpf/xskxceiver.c b/tools/testing/selftests/bpf/xskxceiver.c
> index 05b3cebc5..f2d5c4dd2 100644
> --- a/tools/testing/selftests/bpf/xskxceiver.c
> +++ b/tools/testing/selftests/bpf/xskxceiver.c
> @@ -247,9 +247,10 @@ static void parse_command_line(struct ifobject *ifobj_tx, struct ifobject *ifobj
> opt_print_tests = true;
> break;
> case 't':
> + char *eptr;
> errno = 0;
> - opt_run_test = strtol(optarg, NULL, 0);
> - if (errno)
> + opt_run_test = strtol(optarg, &eptr, 0);
> + if (errno || *eptr)
> print_usage(argv);
> break;
> case 'h':
> --
> 2.34.1
>
Some style issues and typos, will send the follow up tomorrow.
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH bpf] bpf: fix selftest/xsk single test selection
2026-02-17 8:03 [PATCH bpf] bpf: fix selftest/xsk single test selection Mahdi Faramarzpour
2026-02-17 8:40 ` bot+bpf-ci
2026-02-17 8:41 ` Mahdi Faramarzpour
@ 2026-02-17 13:03 ` Maciej Fijalkowski
2 siblings, 0 replies; 4+ messages in thread
From: Maciej Fijalkowski @ 2026-02-17 13:03 UTC (permalink / raw)
To: Mahdi Faramarzpour
Cc: bpf, Magnus Karlsson, Stanislav Fomichev, Andrii Nakryiko,
Eduard Zingerman, Alexei Starovoitov, Daniel Borkmann,
Martin KaFai Lau, Song Liu, Yonghong Song, John Fastabend,
KP Singh, Hao Luo, Jiri Olsa, Shuah Khan, netdev, linux-kselftest,
linux-kernel
On Tue, Feb 17, 2026 at 11:33:26AM +0330, Mahdi Faramarzpour wrote:
> From: Mahdi Faramarzpour <mahdifrmx@gmail.com>
>
> This commit fixes the integer parsing of -t option. The cli parser
> only relies on errno to detect parsing errors. The manpage for
> strtol (https://man7.org/linux/man-pages/man3/strtol.3.html)
> states that the said function "MAY" set errno to EINVAL in case the
> conversion fails. Currently on some systems, this leads to a silent
> failure with return value not being exactly documented in the
> manpages (probably zero). The reliable way to validate the input is
> to check whether the endptr has been bumped all the way to the end
> of the string or not.
>
> Signd-off-by: Mahdi Faramarzpour <mahdifrmx@gmail.com>
> Fixes: 146e30554a53 ("selftests/xsk: add option to run single test")
Hi Mahdi, selftests related patches are supposed to be routed via
bpf-next tree. Also your SoB line should be last in the set of tags.
> ---
> tools/testing/selftests/bpf/xskxceiver.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/tools/testing/selftests/bpf/xskxceiver.c b/tools/testing/selftests/bpf/xskxceiver.c
> index 05b3cebc5..f2d5c4dd2 100644
> --- a/tools/testing/selftests/bpf/xskxceiver.c
> +++ b/tools/testing/selftests/bpf/xskxceiver.c
> @@ -247,9 +247,10 @@ static void parse_command_line(struct ifobject *ifobj_tx, struct ifobject *ifobj
> opt_print_tests = true;
> break;
> case 't':
> + char *eptr;
> errno = 0;
> - opt_run_test = strtol(optarg, NULL, 0);
> - if (errno)
> + opt_run_test = strtol(optarg, &eptr, 0);
> + if (errno || *eptr)
> print_usage(argv);
> break;
> case 'h':
> --
> 2.34.1
>
^ permalink raw reply [flat|nested] 4+ messages in thread