Skip to content

Commit 04ac7f9

Browse files
Ruidong TianSuzuki K Poulose
authored andcommitted
coresight: perf: Release Coresight path when alloc trace id failed
Error handler for etm_setup_aux can not release coresight path because cpu mask was cleared when coresight_trace_id_get_cpu_id failed. Call coresight_release_path function explicitly when alloc trace id filed. Fixes: 4ff1fdb ("coresight: perf: traceid: Add perf ID allocation and notifiers") Signed-off-by: Ruidong Tian <tianruidong@linux.alibaba.com> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Link: https://lore.kernel.org/r/20230425032416.125542-1-tianruidong@linux.alibaba.com
1 parent f67bc15 commit 04ac7f9

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/hwtracing/coresight/coresight-etm-perf.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -402,6 +402,7 @@ static void *etm_setup_aux(struct perf_event *event, void **pages,
402402
trace_id = coresight_trace_id_get_cpu_id(cpu);
403403
if (!IS_VALID_CS_TRACE_ID(trace_id)) {
404404
cpumask_clear_cpu(cpu, mask);
405+
coresight_release_path(path);
405406
continue;
406407
}
407408

0 commit comments

Comments
 (0)