* [PATCH] selftests: livepatch: use canonical ftrace path
@ 2025-10-10 12:07 Fushuai Wang
2025-10-13 14:28 ` Petr Mladek
2025-10-15 13:11 ` Petr Mladek
0 siblings, 2 replies; 3+ messages in thread
From: Fushuai Wang @ 2025-10-10 12:07 UTC (permalink / raw)
To: jpoimboe, jikos, mbenes, pmladek, joe.lawrence, shuah
Cc: live-patching, linux-kselftest, linux-kernel, Fushuai Wang
Since v4.1 kernel, a new interface for ftrace called "tracefs" was
introduced, which is usually mounted in /sys/kernel/tracing. Therefore,
tracing files can now be accessed via either the legacy path
/sys/kernel/debug/tracing or the newer path /sys/kernel/tracing.
Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>
---
tools/testing/selftests/livepatch/functions.sh | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/tools/testing/selftests/livepatch/functions.sh b/tools/testing/selftests/livepatch/functions.sh
index 46991a029f7c..8ec0cb64ad94 100644
--- a/tools/testing/selftests/livepatch/functions.sh
+++ b/tools/testing/selftests/livepatch/functions.sh
@@ -10,7 +10,11 @@ SYSFS_KERNEL_DIR="/sys/kernel"
SYSFS_KLP_DIR="$SYSFS_KERNEL_DIR/livepatch"
SYSFS_DEBUG_DIR="$SYSFS_KERNEL_DIR/debug"
SYSFS_KPROBES_DIR="$SYSFS_DEBUG_DIR/kprobes"
-SYSFS_TRACING_DIR="$SYSFS_DEBUG_DIR/tracing"
+if [[ -e /sys/kernel/tracing/trace ]]; then
+ SYSFS_TRACING_DIR="$SYSFS_KERNEL_DIR/tracing"
+else
+ SYSFS_TRACING_DIR="$SYSFS_DEBUG_DIR/tracing"
+fi
# Kselftest framework requirement - SKIP code is 4
ksft_skip=4
--
2.36.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] selftests: livepatch: use canonical ftrace path
2025-10-10 12:07 [PATCH] selftests: livepatch: use canonical ftrace path Fushuai Wang
@ 2025-10-13 14:28 ` Petr Mladek
2025-10-15 13:11 ` Petr Mladek
1 sibling, 0 replies; 3+ messages in thread
From: Petr Mladek @ 2025-10-13 14:28 UTC (permalink / raw)
To: Fushuai Wang
Cc: jpoimboe, jikos, mbenes, joe.lawrence, shuah, live-patching,
linux-kselftest, linux-kernel
On Fri 2025-10-10 20:07:27, Fushuai Wang wrote:
> Since v4.1 kernel, a new interface for ftrace called "tracefs" was
> introduced, which is usually mounted in /sys/kernel/tracing. Therefore,
> tracing files can now be accessed via either the legacy path
> /sys/kernel/debug/tracing or the newer path /sys/kernel/tracing.
>
> Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>
Looks good to me:
Reviewed-by: Petr Mladek <pmladek@suse.com>
Tested-by: Petr Mladek <pmladek@suse.com>
Best Regards,
Petr
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] selftests: livepatch: use canonical ftrace path
2025-10-10 12:07 [PATCH] selftests: livepatch: use canonical ftrace path Fushuai Wang
2025-10-13 14:28 ` Petr Mladek
@ 2025-10-15 13:11 ` Petr Mladek
1 sibling, 0 replies; 3+ messages in thread
From: Petr Mladek @ 2025-10-15 13:11 UTC (permalink / raw)
To: Fushuai Wang
Cc: jpoimboe, jikos, mbenes, joe.lawrence, shuah, live-patching,
linux-kselftest, linux-kernel
On Fri 2025-10-10 20:07:27, Fushuai Wang wrote:
> Since v4.1 kernel, a new interface for ftrace called "tracefs" was
> introduced, which is usually mounted in /sys/kernel/tracing. Therefore,
> tracing files can now be accessed via either the legacy path
> /sys/kernel/debug/tracing or the newer path /sys/kernel/tracing.
>
> Signed-off-by: Fushuai Wang <wangfushuai@baidu.com>
JFYI, the patch has been comitted into livepatching.git,
branch for-6.19/trivial.
Best Regards,
Petr
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-10-15 13:11 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-10 12:07 [PATCH] selftests: livepatch: use canonical ftrace path Fushuai Wang
2025-10-13 14:28 ` Petr Mladek
2025-10-15 13:11 ` Petr Mladek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox