Messages in this thread | | | Date | Thu, 2 May 2013 15:51:47 -0700 | Subject | Re: [PATCH] NOHZ, check to see if tick device is initialized in IRQ handling path | From | Tony Luck <> |
| |
> void tick_nohz_irq_exit(void) > { > struct tick_sched *ts = &__get_cpu_var(tick_cpu_sched); > + struct clock_event_device *dev = > + __get_cpu_var(tick_cpu_device).evtdev; > + > + /* Has the tick been initialized yet? */ > + if (unlikely(!dev || dev->mode == CLOCK_EVT_MODE_UNUSED)) > + return;
Could we have something in the "struct tick_sched" to tell us whether it has been set up? Rather than this somewhat convoluted digging around in the clock_event_device innards?
> + if (unlikely(!dev || dev->mode == CLOCK_EVT_MODE_UNUSED)) > + return;
Ditto here.
-Tony
| |