On 6/8/26 17:17, Masami Hiramatsu (Google) wrote:
On Sun, 7 Jun 2026 15:24:31 +0800
Hui Wang <[email protected]> wrote:
[...]
+ for config_file in \
+ /boot/config-$uname_r \
+ /lib/modules/$uname_r/config \
+ /lib/modules/$uname_r/build/.config
Hmm, also I don't like this, because this highly depends on the environment.
Instead, we can add CONFIG_IKCONFIG_PROC=y in
tools/testing/selftests/ftrace/config.
Thank you,
Thanks for the review. I'll address all other comments in v2.
I have a concern about this specific point. On Ubuntu kernels, both
CONFIG_IKCONFIG and CONFIG_IKCONFIG_PROC are disabled by default, so
/proc/config.gz does not exist. If we drop the /boot/config-$(uname -r)
lookup and rely solely on /proc/config.gz, this test would become
unresolved on every Ubuntu kernel — a regression, since it works on
those kernels today.
There is also existing precedent for the /boot/config-$(uname -r)
fallback: tools/testing/selftests/mm/va_high_addr_switch.sh checks
/proc/config.gz first and falls back to /boot/config-$(uname -r).
So how about we keep /boot/config-$(uname -r) as a fallback, but drop
the /lib/modules/... paths you objected to. And add ftrace/config as you
suggested here.
Thanks,
Hui.
+ do
+ if [ -f "$config_file" ]; then
+ grep -Eq "^${config}=(y|m)$" "$config_file"
+ return $?
+ fi
+ done
+
+ return 2
+}
+
LOCALHOST=127.0.0.1
yield() {
--
2.43.0