]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
perf cs-etm: Add missing variable in cs_etm__process_queues()
authorBen Hutchings <benh@debian.org>
Mon, 24 Feb 2025 15:57:20 +0000 (16:57 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 13 Mar 2025 11:47:45 +0000 (12:47 +0100)
Commit 5afd032961e8 "perf cs-etm: Don't flush when packet_queue fills
up" uses i as a loop counter in cs_etm__process_queues().  It was
backported to the 5.4 and 5.10 stable branches, but the i variable
doesn't exist there as it was only added in 5.15.

Declare i with the expected type.

Fixes: 1ed167325c32 ("perf cs-etm: Don't flush when packet_queue fills up")
Fixes: 26db806fa23e ("perf cs-etm: Don't flush when packet_queue fills up")
Signed-off-by: Ben Hutchings <benh@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
tools/perf/util/cs-etm.c

index e3fa32b83367e87d4c28dc217f00784d0e976087..2055d582a8a433bf2bb54dbd82c2a29a95d8b189 100644 (file)
@@ -2171,7 +2171,7 @@ static int cs_etm__process_timeless_queues(struct cs_etm_auxtrace *etm,
 static int cs_etm__process_queues(struct cs_etm_auxtrace *etm)
 {
        int ret = 0;
-       unsigned int cs_queue_nr, queue_nr;
+       unsigned int cs_queue_nr, queue_nr, i;
        u8 trace_chan_id;
        u64 timestamp;
        struct auxtrace_queue *queue;