The patch titled hrtimers: clean up callback tracking has been added to the -mm tree. Its filename is hrtimers-clean-up-callback-tracking.patch See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this ------------------------------------------------------ Subject: hrtimers: clean up callback tracking From: Thomas Gleixner <tglx@xxxxxxxxxxxxx> Reintroduce ktimers feature "optimized away" by the ktimers review process: remove the curr_timer pointer from the cpu-base and use the hrtimer state. No functional changes. Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxxxxx> Signed-off-by: Ingo Molnar <mingo@xxxxxxx> Cc: Roman Zippel <zippel@xxxxxxxxxxxxxx> Cc: john stultz <johnstul@xxxxxxxxxx> Cc: Andi Kleen <ak@xxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxx> --- include/linux/hrtimer.h | 1 - kernel/hrtimer.c | 10 +--------- 2 files changed, 1 insertion(+), 10 deletions(-) diff -puN include/linux/hrtimer.h~hrtimers-clean-up-callback-tracking include/linux/hrtimer.h --- a/include/linux/hrtimer.h~hrtimers-clean-up-callback-tracking +++ a/include/linux/hrtimer.h @@ -136,7 +136,6 @@ struct hrtimer_cpu_base { spinlock_t lock; struct lock_class_key lock_key; struct hrtimer_clock_base clock_base[HRTIMER_MAX_CLOCK_BASES]; - struct hrtimer *curr_timer; }; /* diff -puN kernel/hrtimer.c~hrtimers-clean-up-callback-tracking kernel/hrtimer.c --- a/kernel/hrtimer.c~hrtimers-clean-up-callback-tracking +++ a/kernel/hrtimer.c @@ -167,8 +167,6 @@ static inline int hrtimer_callback_runni */ #ifdef CONFIG_SMP -#define set_curr_timer(b, t) do { (b)->curr_timer = (t); } while (0) - /* * We are using hashed locking: holding per_cpu(hrtimer_bases)[n].lock * means that all timers which are tied to this base via timer->base are @@ -222,7 +220,7 @@ switch_hrtimer_base(struct hrtimer *time * completed. There is no conflict as we hold the lock until * the timer is enqueued. */ - if (unlikely(base->cpu_base->curr_timer == timer)) + if (unlikely(timer->state & HRTIMER_STATE_CALLBACK)) return base; /* See the comment in lock_timer_base() */ @@ -236,8 +234,6 @@ switch_hrtimer_base(struct hrtimer *time #else /* CONFIG_SMP */ -#define set_curr_timer(b, t) do { } while (0) - static inline struct hrtimer_clock_base * lock_hrtimer_base(const struct hrtimer *timer, unsigned long *flags) { @@ -665,7 +661,6 @@ static inline void run_hrtimer_queue(str break; fn = timer->function; - set_curr_timer(cpu_base, timer); __remove_hrtimer(timer, base, HRTIMER_STATE_CALLBACK); spin_unlock_irq(&cpu_base->lock); @@ -679,7 +674,6 @@ static inline void run_hrtimer_queue(str enqueue_hrtimer(timer, base); } } - set_curr_timer(cpu_base, NULL); spin_unlock_irq(&cpu_base->lock); } @@ -866,8 +860,6 @@ static void migrate_hrtimers(int cpu) spin_lock(&old_base->lock); for (i = 0; i < HRTIMER_MAX_CLOCK_BASES; i++) { - BUG_ON(old_base->curr_timer); - migrate_hrtimer_list(&old_base->clock_base[i], &new_base->clock_base[i]); } _ Patches currently in -mm which might be from tglx@xxxxxxxxxxxxx are origin.patch git-mtd.patch gtod-uninline-jiffiesh.patch gtod-fix-multiple-conversion-bugs-in-msecs_to_jiffies.patch gtod-fix-timeout-overflow.patch gtod-persistent-clock-support-core.patch gtod-persistent-clock-support-i386.patch dynticks-uninline-irq_enter.patch dynticks-extend-next_timer_interrupt-to-use-a-reference-jiffie.patch hrtimers-namespace-and-enum-cleanup.patch hrtimers-clean-up-locking.patch hrtimers-add-state-tracking.patch hrtimers-clean-up-callback-tracking.patch hrtimers-move-and-add-documentation.patch acpi-include-fix.patch acpi-keep-track-of-timer-broadcast.patch acpi-add-state-propagation-for-dynamic-broadcasting.patch acpi-cleanups-allow-early-access-to-pmtimer.patch i386-apic-clean-up-the-apic-code.patch clockevents-core.patch clockevents-i386-drivers.patch clockevents-i386-hpet-driver.patch i386-apic-rework-and-fix-local-apic-calibration.patch high-res-timers-core.patch high-res-timers-core-do-itimer-rearming-in-process-context.patch high-res-timers-allow-tsc-clocksource-if-pmtimer-present.patch dynticks-core.patch dynticks-add-nohz-stats-to-proc-stat.patch dynticks-i386-support-idle-handler-callbacks.patch dynticks-i386-prepare-nmi-watchdog.patch high-res-timers-dynticks-i386-support-enable-in-kconfig.patch debugging-feature-add-proc-timer_stat.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html