public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] timekeeping: Remove __current_kernel_time()
@ 2018-04-13  5:27 Baolin Wang
  2018-04-17 15:23 ` [tip:timers/urgent] " tip-bot for Baolin Wang
  0 siblings, 1 reply; 2+ messages in thread
From: Baolin Wang @ 2018-04-13  5:27 UTC (permalink / raw)
  To: john.stultz, tglx, sboyd; +Cc: arnd, broonie, baolin.wang, linux-kernel

The __current_kernel_time() function based on 'struct timespec' is no
longer recommended for new code, and the only user of this function
has been replaced by commit 6909e29fdefb ("kdb: use
__ktime_get_real_seconds instead of __current_kernel_time"). So now we
can remove this obsolete interface.

Signed-off-by: Baolin Wang <baolin.wang@linaro.org>
---
 include/linux/timekeeping32.h |    3 ---
 kernel/time/timekeeping.c     |    7 -------
 2 files changed, 10 deletions(-)

diff --git a/include/linux/timekeeping32.h b/include/linux/timekeeping32.h
index af4114d..3616b4b 100644
--- a/include/linux/timekeeping32.h
+++ b/include/linux/timekeeping32.h
@@ -9,9 +9,6 @@
 extern void do_gettimeofday(struct timeval *tv);
 unsigned long get_seconds(void);
 
-/* does not take xtime_lock */
-struct timespec __current_kernel_time(void);
-
 static inline struct timespec current_kernel_time(void)
 {
 	struct timespec64 now = current_kernel_time64();
diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c
index ca90219..dcf7f20 100644
--- a/kernel/time/timekeeping.c
+++ b/kernel/time/timekeeping.c
@@ -2139,13 +2139,6 @@ unsigned long get_seconds(void)
 }
 EXPORT_SYMBOL(get_seconds);
 
-struct timespec __current_kernel_time(void)
-{
-	struct timekeeper *tk = &tk_core.timekeeper;
-
-	return timespec64_to_timespec(tk_xtime(tk));
-}
-
 struct timespec64 current_kernel_time64(void)
 {
 	struct timekeeper *tk = &tk_core.timekeeper;
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [tip:timers/urgent] timekeeping: Remove __current_kernel_time()
  2018-04-13  5:27 [PATCH] timekeeping: Remove __current_kernel_time() Baolin Wang
@ 2018-04-17 15:23 ` tip-bot for Baolin Wang
  0 siblings, 0 replies; 2+ messages in thread
From: tip-bot for Baolin Wang @ 2018-04-17 15:23 UTC (permalink / raw)
  To: linux-tip-commits; +Cc: tglx, baolin.wang, mingo, linux-kernel, hpa

Commit-ID:  e142aa09ed88be98395dde7acb96fb2263566b68
Gitweb:     https://git.kernel.org/tip/e142aa09ed88be98395dde7acb96fb2263566b68
Author:     Baolin Wang <baolin.wang@linaro.org>
AuthorDate: Fri, 13 Apr 2018 13:27:58 +0800
Committer:  Thomas Gleixner <tglx@linutronix.de>
CommitDate: Tue, 17 Apr 2018 17:18:05 +0200

timekeeping: Remove __current_kernel_time()

The __current_kernel_time() function based on 'struct timespec' is no
longer recommended for new code, and the only user of this function has
been replaced by commit 6909e29fdefb ("kdb: use __ktime_get_real_seconds
instead of __current_kernel_time").

Remove the obsolete interface.

Signed-off-by: Baolin Wang <baolin.wang@linaro.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: arnd@arndb.de
Cc: sboyd@kernel.org
Cc: broonie@kernel.org
Cc: john.stultz@linaro.org
Link: https://lkml.kernel.org/r/1a9dbea7ee2cda7efe9ed330874075cf17fdbff6.1523596316.git.baolin.wang@linaro.org

---
 include/linux/timekeeping32.h | 3 ---
 kernel/time/timekeeping.c     | 7 -------
 2 files changed, 10 deletions(-)

diff --git a/include/linux/timekeeping32.h b/include/linux/timekeeping32.h
index af4114d5dc17..3616b4becb59 100644
--- a/include/linux/timekeeping32.h
+++ b/include/linux/timekeeping32.h
@@ -9,9 +9,6 @@
 extern void do_gettimeofday(struct timeval *tv);
 unsigned long get_seconds(void);
 
-/* does not take xtime_lock */
-struct timespec __current_kernel_time(void);
-
 static inline struct timespec current_kernel_time(void)
 {
 	struct timespec64 now = current_kernel_time64();
diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c
index ca90219a1e73..dcf7f20fcd12 100644
--- a/kernel/time/timekeeping.c
+++ b/kernel/time/timekeeping.c
@@ -2139,13 +2139,6 @@ unsigned long get_seconds(void)
 }
 EXPORT_SYMBOL(get_seconds);
 
-struct timespec __current_kernel_time(void)
-{
-	struct timekeeper *tk = &tk_core.timekeeper;
-
-	return timespec64_to_timespec(tk_xtime(tk));
-}
-
 struct timespec64 current_kernel_time64(void)
 {
 	struct timekeeper *tk = &tk_core.timekeeper;

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-04-17 15:23 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-04-13  5:27 [PATCH] timekeeping: Remove __current_kernel_time() Baolin Wang
2018-04-17 15:23 ` [tip:timers/urgent] " tip-bot for Baolin Wang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox