From: Vineeth Pillai Date: Fri, 15 May 2026 14:01:21 +0000 (-0400) Subject: cpufreq: amd-pstate: Use trace_call__##name() at guarded tracepoint call site X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2dad375e5f21223c5ed51dabd9ae22e35db1ab79;p=thirdparty%2Fkernel%2Flinux.git cpufreq: amd-pstate: Use trace_call__##name() at guarded tracepoint call site Replace trace_foo() with the new trace_call__foo() at sites already guarded by trace_foo_enabled(), avoiding a redundant static_branch_unlikely() re-evaluation inside the tracepoint. trace_call__foo() calls the tracepoint callbacks directly without utilizing the static branch again. Cc: Huang Rui Cc: "Rafael J. Wysocki" Cc: Viresh Kumar Link: https://patch.msgid.link/20260515140121.2239414-1-vineeth@bitbyteword.org Suggested-by: Steven Rostedt Suggested-by: Peter Zijlstra Assisted-by: Claude:claude-sonnet-4-6 Reviewed-by: Mario Limonciello Signed-off-by: Vineeth Pillai (Google) Signed-off-by: Steven Rostedt --- diff --git a/drivers/cpufreq/amd-pstate.c b/drivers/cpufreq/amd-pstate.c index 453084c67327..4722de25149b 100644 --- a/drivers/cpufreq/amd-pstate.c +++ b/drivers/cpufreq/amd-pstate.c @@ -368,7 +368,8 @@ static int amd_pstate_set_floor_perf(struct cpufreq_policy *policy, u8 perf) out_trace: if (trace_amd_pstate_cppc_req2_enabled()) - trace_amd_pstate_cppc_req2(cpudata->cpu, perf, changed, ret); + trace_call__amd_pstate_cppc_req2(cpudata->cpu, perf, changed, + ret); return ret; }