tree 7fdfb43dd3a4db112343caccce091c12435210da parent 083bc6b3c9b52b5998cc49d4aa2f8f15c2e84e6b author Ben Dooks <[EMAIL PROTECTED]> Wed, 31 Aug 2005 09:42:14 +0100 committer Russell King <[EMAIL PROTECTED]> Wed, 31 Aug 2005 09:42:14 +0100
[ARM] 2857/2: Dynamic tick - fix OOPS if configured and not provided Patch from Ben Dooks timer_dyn_reprogram() fails with an OOPS if the configuration for CONFIG_NO_IDLE_HZ is enabled, and the system has no support for it. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Signed-off-by: Russell King <[EMAIL PROTECTED]> arch/arm/kernel/time.c | 10 ++++++---- 1 files changed, 6 insertions(+), 4 deletions(-) diff --git a/arch/arm/kernel/time.c b/arch/arm/kernel/time.c --- a/arch/arm/kernel/time.c +++ b/arch/arm/kernel/time.c @@ -433,10 +433,12 @@ void timer_dyn_reprogram(void) { struct dyn_tick_timer *dyn_tick = system_timer->dyn_tick; - write_seqlock(&xtime_lock); - if (dyn_tick->state & DYN_TICK_ENABLED) - dyn_tick->reprogram(next_timer_interrupt() - jiffies); - write_sequnlock(&xtime_lock); + if (dyn_tick) { + write_seqlock(&xtime_lock); + if (dyn_tick->state & DYN_TICK_ENABLED) + dyn_tick->reprogram(next_timer_interrupt() - jiffies); + write_sequnlock(&xtime_lock); + } } static ssize_t timer_show_dyn_tick(struct sys_device *dev, char *buf) - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html