summaryrefslogtreecommitdiff
path: root/tools/perf/builtin-sched.c
diff options
context:
space:
mode:
authorNamhyung Kim <namhyung@kernel.org>2025-07-03 04:49:40 +0300
committerNamhyung Kim <namhyung@kernel.org>2025-07-03 21:43:16 +0300
commit7a4002ec9e0fced907179da94f67c3082d7b4162 (patch)
tree41a005db85947a9a755545b1d5c555614f9f2729 /tools/perf/builtin-sched.c
parent117e5c33b1c44037af016d77ce6c0b086d55535f (diff)
downloadlinux-7a4002ec9e0fced907179da94f67c3082d7b4162.tar.xz
perf sched: Use RC_CHK_EQUAL() to compare pointers
So that it can check two pointers to the same object properly when REFCNT_CHECKING is on. Fixes: 78c32f4cb12f9430 ("libperf rc_check: Add RC_CHK_EQUAL") Reviewed-by: Ian Rogers <irogers@google.com> Tested-by: Ian Rogers <irogers@google.com> Link: https://lore.kernel.org/r/20250703014942.1369397-7-namhyung@kernel.org Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Diffstat (limited to 'tools/perf/builtin-sched.c')
-rw-r--r--tools/perf/builtin-sched.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/builtin-sched.c b/tools/perf/builtin-sched.c
index a6eb0462dd5b..087d4eaba5f7 100644
--- a/tools/perf/builtin-sched.c
+++ b/tools/perf/builtin-sched.c
@@ -994,7 +994,7 @@ thread_atoms_search(struct rb_root_cached *root, struct thread *thread,
else if (cmp < 0)
node = node->rb_right;
else {
- BUG_ON(thread != atoms->thread);
+ BUG_ON(!RC_CHK_EQUAL(thread, atoms->thread));
return atoms;
}
}