From: James Prestwood <prestwoj@gmail.com>
To: ell@lists.linux.dev
Cc: James Prestwood <prestwoj@gmail.com>
Subject: [PATCH 1/2] time: expose _time_from_timespec in time-private.h
Date: Thu, 29 Aug 2024 04:25:48 -0700 [thread overview]
Message-ID: <20240829112549.24935-1-prestwoj@gmail.com> (raw)
---
ell/time-private.h | 1 +
ell/time.c | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/ell/time-private.h b/ell/time-private.h
index 59c2421..2860943 100644
--- a/ell/time-private.h
+++ b/ell/time-private.h
@@ -12,3 +12,4 @@ uint64_t _time_fuzz_msecs(uint64_t ms);
uint64_t _time_fuzz_secs(uint32_t secs, uint32_t max_offset);
uint64_t _time_realtime_to_boottime(const struct timeval *ts);
uint64_t time_realtime_now(void);
+uint64_t _time_from_timespec(const struct timespec *ts);
diff --git a/ell/time.c b/ell/time.c
index de4e161..e124a91 100644
--- a/ell/time.c
+++ b/ell/time.c
@@ -18,7 +18,7 @@
#include "random.h"
#include "private.h"
-static uint64_t _time_from_timespec(const struct timespec *ts)
+uint64_t _time_from_timespec(const struct timespec *ts)
{
return ts->tv_sec * L_USEC_PER_SEC + ts->tv_nsec / L_NSEC_PER_USEC;
}
--
2.34.1
next reply other threads:[~2024-08-29 11:25 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-29 11:25 James Prestwood [this message]
2024-08-29 11:25 ` [PATCH 2/2] timeout: add l_timeout_remaining James Prestwood
2024-09-03 15:05 ` [PATCH 1/2] time: expose _time_from_timespec in time-private.h Denis Kenzior
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240829112549.24935-1-prestwoj@gmail.com \
--to=prestwoj@gmail.com \
--cc=ell@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.