|
@@ -107,13 +107,6 @@ static void sched_clock_poll(unsigned long wrap_ticks)
|
|
|
update_sched_clock();
|
|
|
}
|
|
|
|
|
|
-void __init setup_sched_clock_needs_suspend(u32 (*read)(void), int bits,
|
|
|
- unsigned long rate)
|
|
|
-{
|
|
|
- setup_sched_clock(read, bits, rate);
|
|
|
- cd.needs_suspend = true;
|
|
|
-}
|
|
|
-
|
|
|
void __init setup_sched_clock(u32 (*read)(void), int bits, unsigned long rate)
|
|
|
{
|
|
|
unsigned long r, w;
|
|
@@ -189,18 +182,15 @@ void __init sched_clock_postinit(void)
|
|
|
static int sched_clock_suspend(void)
|
|
|
{
|
|
|
sched_clock_poll(sched_clock_timer.data);
|
|
|
- if (cd.needs_suspend)
|
|
|
- cd.suspended = true;
|
|
|
+ cd.suspended = true;
|
|
|
return 0;
|
|
|
}
|
|
|
|
|
|
static void sched_clock_resume(void)
|
|
|
{
|
|
|
- if (cd.needs_suspend) {
|
|
|
- cd.epoch_cyc = read_sched_clock();
|
|
|
- cd.epoch_cyc_copy = cd.epoch_cyc;
|
|
|
- cd.suspended = false;
|
|
|
- }
|
|
|
+ cd.epoch_cyc = read_sched_clock();
|
|
|
+ cd.epoch_cyc_copy = cd.epoch_cyc;
|
|
|
+ cd.suspended = false;
|
|
|
}
|
|
|
|
|
|
static struct syscore_ops sched_clock_ops = {
|