init_timer_deferrable conversion

From: Parag Warudkar
Date: Sun Dec 16 2007 - 22:00:47 EST


In my quest to get the wake-ups from idle per second down to bare minimum, I noticed 3 places in the kernel that could benefit from using init_timer_deferrable() instead of init_timer() -

a) drivers/net/sky2.c - watchdog_timer. This was showing up high on Powertop's list of things that cause routine wakeups from idle. After converting to init_timer_deferrable() the wakeups went down and this one no longer shows up in powertop's list. 25% reduction.

b) kernel/time/clocksource.c - watchdog_timer - same story as sky2.c

c) net/core/neighbour.c - gc_timer - Most benefit from deferrable timer.

I am running a kernel with above changes and haven't noticed any immediate problems and the wakeups-from-idle have gone down from 5-7 to mere 1-2 per second.

Is there any reason not to make the above timers deferrable - corner cases, other side effects? If not then I will submit a patch.

Thanks

Parag
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/