Re: [PATCH] ARM: sched_clock: Load cycle count after epoch stabilizes

2013-06-17 Thread Stephen Boyd
On 06/17/13 14:50, John Stultz wrote: > On 06/17/2013 12:51 PM, Stephen Boyd wrote: >> John, >> >> I just saw your pull request for making this code generic. I believe >> this patch fixes a bug that nobody has seen in practice so it's probably >> fine to delay this until 3.11. >> >> Also, I've just

Re: [PATCH] ARM: sched_clock: Load cycle count after epoch stabilizes

2013-06-17 Thread John Stultz
On 06/17/2013 12:51 PM, Stephen Boyd wrote: John, I just saw your pull request for making this code generic. I believe this patch fixes a bug that nobody has seen in practice so it's probably fine to delay this until 3.11. Also, I've just noticed that "ARM: sched_clock: Return suspended count e

Re: [PATCH] ARM: sched_clock: Load cycle count after epoch stabilizes

2013-06-17 Thread Stephen Boyd
John, I just saw your pull request for making this code generic. I believe this patch fixes a bug that nobody has seen in practice so it's probably fine to delay this until 3.11. Also, I've just noticed that "ARM: sched_clock: Return suspended count earlier" that I sent in that series is going to

[PATCH] ARM: sched_clock: Load cycle count after epoch stabilizes

2013-06-12 Thread Stephen Boyd
There is a small race between when the cycle count is read from the hardware and when the epoch stabilizes. Consider this scenario: CPU0 CPU1 cyc = read_sched_clock() cyc_to_sched_clock() update_sche