Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 25 May 2021 18:15:02 GMT
From:      "Bjoern A. Zeeb" <bz@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 18d303b05f28 - main - LinuxKPI: add ktime_get_boottime_ns() implementation to ktime.h
Message-ID:  <202105251815.14PIF2hI043866@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by bz:

URL: https://cgit.FreeBSD.org/src/commit/?id=18d303b05f28acf005dad3f2ffbbec4895181dde

commit 18d303b05f28acf005dad3f2ffbbec4895181dde
Author:     Bjoern A. Zeeb <bz@FreeBSD.org>
AuthorDate: 2021-05-24 18:30:33 +0000
Commit:     Bjoern A. Zeeb <bz@FreeBSD.org>
CommitDate: 2021-05-25 18:01:47 +0000

    LinuxKPI: add ktime_get_boottime_ns() implementation to ktime.h
    
    Sponsored by:   The FreeBSD Foundation
    MFC after:      2 weeks
    Reviewed by:    hselasky
    Differential Revision: https://reviews.freebsd.org/D30432
---
 sys/compat/linuxkpi/common/include/linux/ktime.h | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/sys/compat/linuxkpi/common/include/linux/ktime.h b/sys/compat/linuxkpi/common/include/linux/ktime.h
index e480de3181a9..1475674a12e6 100644
--- a/sys/compat/linuxkpi/common/include/linux/ktime.h
+++ b/sys/compat/linuxkpi/common/include/linux/ktime.h
@@ -220,6 +220,13 @@ ktime_get_boottime(void)
 	return (timespec_to_ktime(ts));
 }
 
+static inline uint64_t
+ktime_get_boottime_ns(void)
+{
+
+	return (ktime_to_ns(ktime_get_boottime()));
+}
+
 static inline ktime_t
 ktime_get_real(void)
 {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202105251815.14PIF2hI043866>