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 /core/timebase.c | |
parent | a3041e3bdb9fb7adb6505e5f3ff4edb63fde1e84 (diff) | |
download | talos-skiboot-f6df3f8ddabd3bc7859cf1ebd24a736223961446.tar.gz talos-skiboot-f6df3f8ddabd3bc7859cf1ebd24a736223961446.zip |
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>
Diffstat (limited to 'core/timebase.c')
-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 0714f25f..8b1c01b6 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(); } |