diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2014-07-17 01:04:38 +0400 |
---|---|---|
committer | John Stultz <john.stultz@linaro.org> | 2014-07-23 21:18:07 +0400 |
commit | f2dec1eae8029bb056a3c1b2d3373681fa8e3e7a (patch) | |
tree | d3f8daca72af614d8d9e8e5c8b5e4a07adb8c6c0 /arch/powerpc/platforms/cell/spufs/file.c | |
parent | 68f6783d28316affcd2ce332d949e40e4c7416bd (diff) | |
download | linux-f2dec1eae8029bb056a3c1b2d3373681fa8e3e7a.tar.xz |
powerpc: cell: Use ktime_get_ns()
Replace the ever recurring:
ts = ktime_get_ts();
ns = timespec_to_ns(&ts);
with
ns = ktime_get_ns();
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: John Stultz <john.stultz@linaro.org>
Diffstat (limited to 'arch/powerpc/platforms/cell/spufs/file.c')
-rw-r--r-- | arch/powerpc/platforms/cell/spufs/file.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/powerpc/platforms/cell/spufs/file.c b/arch/powerpc/platforms/cell/spufs/file.c index 90986923a53a..d966bbe58b8f 100644 --- a/arch/powerpc/platforms/cell/spufs/file.c +++ b/arch/powerpc/platforms/cell/spufs/file.c @@ -2338,7 +2338,6 @@ static const char *ctx_state_names[] = { static unsigned long long spufs_acct_time(struct spu_context *ctx, enum spu_utilization_state state) { - struct timespec ts; unsigned long long time = ctx->stats.times[state]; /* @@ -2351,8 +2350,7 @@ static unsigned long long spufs_acct_time(struct spu_context *ctx, * of the spu context. */ if (ctx->spu && ctx->stats.util_state == state) { - ktime_get_ts(&ts); - time += timespec_to_ns(&ts) - ctx->stats.tstamp; + time += ktime_get_ns() - ctx->stats.tstamp; } return time / NSEC_PER_MSEC; |