Re: [RFC v2] ARM: sched_clock: update epoch_cyc on resume

2012-08-04 Thread Linus Walleij
On Fri, Aug 3, 2012 at 3:28 AM, Colin Cross wrote: > On Fri, Jul 27, 2012 at 8:30 PM, Colin Cross wrote: >> On Fri, Jul 27, 2012 at 6:15 PM, Colin Cross wrote: >>> That patch was merged in 3.4, and my patch is on top of it. Your >>> patch updates epoch_cyc and epoch_ns in suspend, but if the fi

Re: [RFC v2] ARM: sched_clock: update epoch_cyc on resume

2012-08-02 Thread Colin Cross
On Fri, Jul 27, 2012 at 8:30 PM, Colin Cross wrote: > On Fri, Jul 27, 2012 at 6:15 PM, Colin Cross wrote: >> That patch was merged in 3.4, and my patch is on top of it. Your >> patch updates epoch_cyc and epoch_ns in suspend, but if the first call >> to cyc_to_sched_clock after resume gets cyc =

Re: [RFC v2] ARM: sched_clock: update epoch_cyc on resume

2012-07-27 Thread Colin Cross
On Fri, Jul 27, 2012 at 6:15 PM, Colin Cross wrote: > On Fri, Jul 27, 2012 at 4:38 PM, Russell King - ARM Linux > wrote: >> On Sat, Jul 28, 2012 at 01:32:50AM +0200, Linus Walleij wrote: >>> On Wed, Jul 25, 2012 at 4:49 AM, Colin Cross wrote: >>> >>> > Many clocks that are used to provide sched_

Re: [RFC v2] ARM: sched_clock: update epoch_cyc on resume

2012-07-27 Thread Colin Cross
On Fri, Jul 27, 2012 at 4:38 PM, Russell King - ARM Linux wrote: > On Sat, Jul 28, 2012 at 01:32:50AM +0200, Linus Walleij wrote: >> On Wed, Jul 25, 2012 at 4:49 AM, Colin Cross wrote: >> >> > Many clocks that are used to provide sched_clock will reset during >> > suspend. If read_sched_clock re

Re: [RFC v2] ARM: sched_clock: update epoch_cyc on resume

2012-07-27 Thread Russell King - ARM Linux
On Sat, Jul 28, 2012 at 01:32:50AM +0200, Linus Walleij wrote: > On Wed, Jul 25, 2012 at 4:49 AM, Colin Cross wrote: > > > Many clocks that are used to provide sched_clock will reset during > > suspend. If read_sched_clock returns 0 after suspend, sched_clock will > > appear to jump forward. Th

Re: [RFC v2] ARM: sched_clock: update epoch_cyc on resume

2012-07-27 Thread Linus Walleij
On Wed, Jul 25, 2012 at 4:49 AM, Colin Cross wrote: > Many clocks that are used to provide sched_clock will reset during > suspend. If read_sched_clock returns 0 after suspend, sched_clock will > appear to jump forward. This patch resets cd.epoch_cyc to the current > value of read_sched_clock d

[RFC v2] ARM: sched_clock: update epoch_cyc on resume

2012-07-24 Thread Colin Cross
Many clocks that are used to provide sched_clock will reset during suspend. If read_sched_clock returns 0 after suspend, sched_clock will appear to jump forward. This patch resets cd.epoch_cyc to the current value of read_sched_clock during resume, which causes sched_clock() just after suspend to