aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/staging/iio/iio.h9
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/staging/iio/iio.h b/drivers/staging/iio/iio.h
index 38f1425..705dc66 100644
--- a/drivers/staging/iio/iio.h
+++ b/drivers/staging/iio/iio.h
@@ -181,14 +181,7 @@ int __iio_add_chan_devattr(const char *postfix,
**/
static inline s64 iio_get_time_ns(void)
{
- struct timespec ts;
- /*
- * calls getnstimeofday.
- * If hrtimers then up to ns accurate, if not microsecond.
- */
- ktime_get_real_ts(&ts);
-
- return timespec_to_ns(&ts);
+ return ktime_to_ns(ktime_get_boottime());
}
/* Device operating modes */