aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShaibal Dutta <shaibal.dutta@linaro.org>2014-01-31 14:18:24 -0500
committerThomas Gleixner <tglx@linutronix.de>2014-02-07 09:34:28 -0500
commite8b175946c16d7001b22620f52d78ab497efc9d0 (patch)
tree373c898c227efc64ef5b07c277649f8b2f5c29e0
parent38dbfb59d1175ef458d006556061adeaa8751b72 (diff)
timekeeping: Move clock sync work to power efficient workqueue
For better use of CPU idle time, allow the scheduler to select the CPU on which the CMOS clock sync work would be scheduled. This improves idle residency time and conserver power. This functionality is enabled when CONFIG_WQ_POWER_EFFICIENT is selected. Signed-off-by: Shaibal Dutta <shaibal.dutta@broadcom.com> [zoran.markovic@linaro.org: Added commit message. Aligned code.] Signed-off-by: Zoran Markovic <zoran.markovic@linaro.org> Cc: John Stultz <john.stultz@linaro.org> Link: http://lkml.kernel.org/r/1391195904-12497-1-git-send-email-zoran.markovic@linaro.org Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
-rw-r--r--kernel/time/ntp.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/kernel/time/ntp.c b/kernel/time/ntp.c
index af8d1d4f3d55..419a52cecd20 100644
--- a/kernel/time/ntp.c
+++ b/kernel/time/ntp.c
@@ -514,12 +514,13 @@ static void sync_cmos_clock(struct work_struct *work)
514 next.tv_sec++; 514 next.tv_sec++;
515 next.tv_nsec -= NSEC_PER_SEC; 515 next.tv_nsec -= NSEC_PER_SEC;
516 } 516 }
517 schedule_delayed_work(&sync_cmos_work, timespec_to_jiffies(&next)); 517 queue_delayed_work(system_power_efficient_wq,
518 &sync_cmos_work, timespec_to_jiffies(&next));
518} 519}
519 520
520void ntp_notify_cmos_timer(void) 521void ntp_notify_cmos_timer(void)
521{ 522{
522 schedule_delayed_work(&sync_cmos_work, 0); 523 queue_delayed_work(system_power_efficient_wq, &sync_cmos_work, 0);
523} 524}
524 525
525#else 526#else