diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2016-08-09 16:38:19 +1000 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2016-08-11 19:54:23 +1000 |
commit | f6df3f8ddabd3bc7859cf1ebd24a736223961446 (patch) | |
tree | 9769debbd8bc5c06a6235f14ad7dba0ba673d50d | |
parent | a3041e3bdb9fb7adb6505e5f3ff4edb63fde1e84 (diff) | |
download | skiboot-f6df3f8ddabd3bc7859cf1ebd24a736223961446.zip skiboot-f6df3f8ddabd3bc7859cf1ebd24a736223961446.tar.gz skiboot-f6df3f8ddabd3bc7859cf1ebd24a736223961446.tar.bz2 |
time: Improve time_wait_poll()
Call time_wait_nopoll() when period is smaller than remaining
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
-rw-r--r-- | core/timebase.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/timebase.c b/core/timebase.c index 0714f25..8b1c01b 100644 --- a/core/timebase.c +++ b/core/timebase.c @@ -40,7 +40,8 @@ static void time_wait_poll(unsigned long duration) opal_run_pollers(); time_wait_nopoll(period); remaining -= period; - } + } else + time_wait_nopoll(remaining); cpu_relax(); } |