linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC][PATCH 1/5] tick/nohz: Improve tick_nohz_get_next_hrtimer() kerneldoc
       [not found] <2188825.ElGaqSPkdT@kreacher>
@ 2021-03-29 18:11 ` Rafael J. Wysocki
  0 siblings, 0 replies; only message in thread
From: Rafael J. Wysocki @ 2021-03-29 18:11 UTC (permalink / raw)
  To: Linux PM
  Cc: LKML, Frederic Weisbecker, Peter Zijlstra, Thomas Gleixner,
	Zhou Ti (x2019cwm)

From: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>

Make the tick_nohz_get_next_hrtimer() kerneldoc comment state clearly
that the function may return negative numbers.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
---
 kernel/time/tick-sched.c |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

Index: linux-pm/kernel/time/tick-sched.c
===================================================================
--- linux-pm.orig/kernel/time/tick-sched.c
+++ linux-pm/kernel/time/tick-sched.c
@@ -1124,7 +1124,11 @@ ktime_t tick_nohz_get_next_hrtimer(void)
  * tick_nohz_get_sleep_length - return the expected length of the current sleep
  * @delta_next: duration until the next event if the tick cannot be stopped
  *
- * Called from power state control code with interrupts disabled
+ * Called from power state control code with interrupts disabled.
+ *
+ * The return value of this function and/or the value returned by it through the
+ * @delta_next pointer can be negative which must be taken into account by its
+ * callers.
  */
 ktime_t tick_nohz_get_sleep_length(ktime_t *delta_next)
 {




^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-03-29 18:38 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <2188825.ElGaqSPkdT@kreacher>
2021-03-29 18:11 ` [RFC][PATCH 1/5] tick/nohz: Improve tick_nohz_get_next_hrtimer() kerneldoc Rafael J. Wysocki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).