Skip to content

Commit

Permalink
hrtimers: fix warning in kernel/hrtimer.c
Browse files Browse the repository at this point in the history
this warning:

  kernel/hrtimer.c: In function ‘hrtimer_cpu_notify’:
  kernel/hrtimer.c:1574: warning: unused variable ‘dcpu’

is caused because 'dcpu' is only used in the CONFIG_HOTPLUG_CPU case.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Ingo Molnar committed Dec 18, 2008
1 parent a0a99b2 commit b2e3c0a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion kernel/hrtimer.c
Original file line number Diff line number Diff line change
Expand Up @@ -1571,7 +1571,7 @@ static void tickle_timers(void *arg)
static int __cpuinit hrtimer_cpu_notify(struct notifier_block *self,
unsigned long action, void *hcpu)
{
int dcpu, scpu = (long)hcpu;
int scpu = (long)hcpu;

switch (action) {

Expand All @@ -1583,10 +1583,14 @@ static int __cpuinit hrtimer_cpu_notify(struct notifier_block *self,
#ifdef CONFIG_HOTPLUG_CPU
case CPU_DEAD:
case CPU_DEAD_FROZEN:
{
int dcpu;

clockevents_notify(CLOCK_EVT_NOTIFY_CPU_DEAD, &scpu);
dcpu = migrate_hrtimers(scpu);
smp_call_function_single(dcpu, tickle_timers, NULL, 0);
break;
}
#endif

default:
Expand Down

0 comments on commit b2e3c0a

Please sign in to comment.