Re: [PATCH] ARM: S5PV310: Implement kernel timers using MCT

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Dec 23, 2010 at 07:24:48PM +0900, Kukjin Kim wrote:
> Jamie Iles wrote:
> > > +irqreturn_t s5pv310_mct0_event_isr(int irq, void *dev_id)
> > > +{
> > > +	struct clock_event_device *evt;
> > > +
> > > +	/* Clear the MCT tick interrupt */
> > > +
> > > +	evt = &mct_tick0_device;
> > > +	if (evt->mode != CLOCK_EVT_MODE_PERIODIC)
> > > +		s5pv310_mct_tick_stop(MCT_TICK0);
> > 
> > I don't think you need to stop the timer here, the clockevents layer
> > will handle this for you.
> > 
> This is to support One-shot mode using MCT. Because basically MCT local
> timer only supports periodic mode.
> But will be added comment.

Actually I think you can simply remove the s5pv310_mct_tick_stop() 
altogether. The onestop event handlers should schedule the next expiry 
and will respect the min and max deltas so after the event the timer 
will be correctly programmed for the next event.

I had to try this on hardware to convince myself (the timers on my 
platform have the same behaviour) but it does work!

Jamie
--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux SoC Development]     [Linux Rockchip Development]     [Linux USB Development]     [Video for Linux]     [Linux Audio Users]     [Linux SCSI]     [Yosemite News]

  Powered by Linux