* [LTP] [PATCH 1/1] checkpatch: Pass git root
@ 2026-05-13 13:49 Petr Vorel
2026-05-13 16:22 ` [LTP] " linuxtestproject.agent
0 siblings, 1 reply; 2+ messages in thread
From: Petr Vorel @ 2026-05-13 13:49 UTC (permalink / raw)
To: ltp
checkpatch.pl --strict parameter added in 1908cd77c2 expects --root
parameter when running with --no-tree due searching in $root/include/
directory.
This fixes warning on files with CAMELCASE check (corner case):
$ cd testcases/kernel/syscalls/statx; make check-statx02
CHECK testcases/kernel/syscalls/statx/statx02.c
Use of uninitialized value $root in concatenation (.) or string at
scripts/checkpatch.pl line 1213.
find: ‘/include’: No such file or directory
statx02.c:52: CHECK: Avoid CamelCase: <PRIu64>
...
Fixes: 1908cd77c2 ("make check: b4: Use --strict when run checkpatch.pl")
Signed-off-by: Petr Vorel <pvorel@suse.cz>
---
NOTE: I'll verify the usage with kernel checkpatch.pl maintainers.
Kind regards,
Petr
include/mk/env_post.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/mk/env_post.mk b/include/mk/env_post.mk
index 1b0d3a2a8e..726b9a9e75 100644
--- a/include/mk/env_post.mk
+++ b/include/mk/env_post.mk
@@ -73,7 +73,7 @@ CHECK_TARGETS ?= $(addprefix check-,$(notdir $(patsubst %.c,%,$(sort $(wildcar
CHECK_TARGETS := $(filter-out $(addprefix check-, $(FILTER_OUT_MAKE_TARGETS)), $(CHECK_TARGETS))
CHECK_HEADER_TARGETS ?= $(addprefix check-,$(notdir $(sort $(wildcard $(abs_srcdir)/*.h))))
CHECK ?= $(abs_top_srcdir)/tools/sparse/sparse-ltp
-CHECK_NOFLAGS ?= CHECKPATCH_CONFIG_DIR="$(abs_top_srcdir)" $(abs_top_srcdir)/scripts/checkpatch.pl -f
+CHECK_NOFLAGS ?= CHECKPATCH_CONFIG_DIR="$(abs_top_srcdir)" $(abs_top_srcdir)/scripts/checkpatch.pl -f --root $(abs_top_srcdir)
SHELL_CHECK ?= $(abs_top_srcdir)/scripts/checkbashisms.pl --force --extra
SHELL_CHECK_TARGETS ?= $(addprefix check-,$(notdir $(sort $(wildcard $(abs_srcdir)/*.sh))))
--
2.54.0
--
Mailing list info: https://lists.linux.it/listinfo/ltp
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [LTP] checkpatch: Pass git root
2026-05-13 13:49 [LTP] [PATCH 1/1] checkpatch: Pass git root Petr Vorel
@ 2026-05-13 16:22 ` linuxtestproject.agent
0 siblings, 0 replies; 2+ messages in thread
From: linuxtestproject.agent @ 2026-05-13 16:22 UTC (permalink / raw)
To: Petr Vorel; +Cc: ltp, LTP AI Reviewer
Hi Petr,
On Wed, 13 May 2026, Petr Vorel wrote:
> checkpatch: Pass git root
> -CHECK_NOFLAGS ?= CHECKPATCH_CONFIG_DIR="$(abs_top_srcdir)" $(abs_top_srcdir)/scripts/checkpatch.pl -f
> +CHECK_NOFLAGS ?= CHECKPATCH_CONFIG_DIR="$(abs_top_srcdir)" $(abs_top_srcdir)/scripts/checkpatch.pl -f --root $(abs_top_srcdir)
Note: there is a double space between `-f` and `--root`; consider collapsing
to a single space for consistency.
Reviewed-by: LTP AI Reviewer <ltp-ai@noreply.github.com>
---
Note:
Our agent completed the review of the patch.
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
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-05-13 16:23 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-13 13:49 [LTP] [PATCH 1/1] checkpatch: Pass git root Petr Vorel
2026-05-13 16:22 ` [LTP] " linuxtestproject.agent
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox