Skip to contentSkip to conversation

perf: delete unused variable tmp to fix new build warning

PATCH In review Paul Gortmaker 3 participants 4 messages May 21, 2014 – May 22, 2014

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 perf: delete unused variable tmp to fix new build warning

commit 3a497f48637e2aac17eabb84a17f8ac5216028fc [tip:perf/core] ("perf: Simplify perf_event_exit_task_context()") deleted the code that was using tmp but not the declaration of it, causing:

kernel/events/core.c:7434:35: warning: unused variable ‘tmp’ [-Wunused-variable]

Cc Peter Zijlstra <[email protected]>
Cc Arnaldo Carvalho de Melo <[email protected]>
Cc Paul Mackerras <[email protected]>
Cc Ingo Molnar <[email protected]>
---
 kernel/events/core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/events/core.c +1 -1
index 49ac18c..244d70a 100644
@@ -7432,7 +7432,7 @@ __perf_event_exit_task(struct perf_event *child_event,
 
 static void perf_event_exit_task_context(struct task_struct *child, int ctxn)
 {
-	struct perf_event *child_event, *tmp;
+	struct perf_event *child_event;
 	struct perf_event_context *child_ctx;
 	unsigned long flags;
 
Signature · 1 line
1.8.2.3
#1 lore raw
Quoted 5 lines · Paul Gortmaker

commit 3a497f48637e2aac17eabb84a17f8ac5216028fc [tip:perf/core] ("perf: Simplify perf_event_exit_task_context()") deleted the code that was using tmp but not the declaration of it, causing:

kernel/events/core.c:7434:35: warning: unused variable ‘tmp’ [-Wunused-variable]

This warning should be addressed by:

12665b35b0b4 perf/events/core: Drop unused variable after cleanup

Thanks,

Ingo

#2 lore raw
Quoted 7 lines · Ingo Molnar
Quoted 4 lines · Paul Gortmaker

commit 3a497f48637e2aac17eabb84a17f8ac5216028fc [tip:perf/core] ("perf: Simplify perf_event_exit_task_context()") deleted the code that was using tmp but not the declaration of it, causing:

Quoted 5 lines
Quoted 1 line

kernel/events/core.c:7434:35: warning: unused variable ‘tmp’ [-Wunused-variable]

This warning should be addressed by:

12665b35b0b4 perf/events/core: Drop unused variable after cleanup

Indeed - and I now see that commit when I switch over to my tip repo.

However 12665b35b0b4 is not present in linux-next of yesterday or today (21/22) for some reason. The tip/auto-latest merged into next has this:

commit 1974363f7e899dc1b9e6e774dc885c7980a7159b
Merge: 67367e2c3f76 7fd44dacdd80
Author: Ingo Molnar <[email protected]>
Date: Thu May 8 12:40:28 2014 +0200

    Merge branch 'x86/x32'

as its top commit. Today's auto-latest in tip shows a similar merge, but with today's date (and it contains Boris' warning fix too.) Adding Stephen to CC in case it is something related to linux-next infrastructure.

Thanks,
Paul.

#3 lore raw

Hi Paul,

Quoted 11 lines · On Thu, 22 May 2014 09:44:46 -0400 Paul Gortmaker…

Indeed - and I now see that commit when I switch over to my tip repo.

However 12665b35b0b4 is not present in linux-next of yesterday or today (21/22) for some reason. The tip/auto-latest merged into next has this:

commit 1974363f7e899dc1b9e6e774dc885c7980a7159b
Merge: 67367e2c3f76 7fd44dacdd80
Author: Ingo Molnar <[email protected]>
Date: Thu May 8 12:40:28 2014 +0200

Quoted 5 lines
    Merge branch 'x86/x32'

as its top commit. Today's auto-latest in tip shows a similar merge, but with today's date (and it contains Boris' warning fix too.) Adding Stephen to CC in case it is something related to linux-next infrastructure.

Ingo and co like to give the tip tree components some pretty good testing before they expose it to linux-next, though usually there is not this long a break between updates. The auto-latest branch has been updated for today's linux-next.

Signature · 2 lines
Cheers,
Stephen Rothwell                    [email protected]