public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: Tian Tao <tiantao6@hisilicon.com>
To: <catalin.marinas@arm.com>, <will@kernel.org>,
	<vincenzo.frascino@arm.com>,  <tglx@linutronix.de>,
	<linux-arm-kernel@lists.infradead.org>
Cc: linuxarm@huawei.com
Subject: [PATCH] arm64: vdso: Add extern declarations for vDSO time-related functions
Date: Tue, 15 Sep 2020 19:24:30 +0800	[thread overview]
Message-ID: <1600169070-13611-1-git-send-email-tiantao6@hisilicon.com> (raw)

Add extern declarations for vDSO time-related functions to notify the
compiler these functions will be used in somewhere to fix
"no previous prototype" compile warning.

arch/arm64/kernel/vdso/vgettimeofday.c:9:5: warning: no previous
prototype for ‘__kernel_clock_gettime’ [-Wmissing-prototypes]
int __kernel_clock_gettime(clockid_t clock,
     ^
arch/arm64/kernel/vdso/vgettimeofday.c:15:5: warning: no previous
prototype for ‘__kernel_gettimeofday’ [-Wmissing-prototypes]
int __kernel_gettimeofday(struct __kernel_old_timeval *tv,
     ^
arch/arm64/kernel/vdso/vgettimeofday.c:21:5: warning: no previous
prototype for ‘__kernel_clock_getres’ [-Wmissing-prototypes]
int __kernel_clock_getres(clockid_t clock_id,

Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
---
 arch/arm64/kernel/vdso/vgettimeofday.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/arch/arm64/kernel/vdso/vgettimeofday.c b/arch/arm64/kernel/vdso/vgettimeofday.c
index 4236cf3..e808481 100644
--- a/arch/arm64/kernel/vdso/vgettimeofday.c
+++ b/arch/arm64/kernel/vdso/vgettimeofday.c
@@ -6,18 +6,27 @@
  *
  */
 
+extern
+int __kernel_clock_gettime(clockid_t clock,
+			   struct __kernel_timespec *ts);
 int __kernel_clock_gettime(clockid_t clock,
 			   struct __kernel_timespec *ts)
 {
 	return __cvdso_clock_gettime(clock, ts);
 }
 
+extern
+int __kernel_gettimeofday(struct __kernel_old_timeval *tv,
+			  struct timezone *tz);
 int __kernel_gettimeofday(struct __kernel_old_timeval *tv,
 			  struct timezone *tz)
 {
 	return __cvdso_gettimeofday(tv, tz);
 }
 
+extern
+int __kernel_clock_getres(clockid_t clock_id,
+			  struct __kernel_timespec *res);
 int __kernel_clock_getres(clockid_t clock_id,
 			  struct __kernel_timespec *res)
 {
-- 
2.7.4


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

             reply	other threads:[~2020-09-15 11:28 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-15 11:24 Tian Tao [this message]
2020-09-15 11:48 ` [PATCH] arm64: vdso: Add extern declarations for vDSO time-related functions Will Deacon
2020-09-15 12:06   ` tiantao (H)
2020-09-18 14:41   ` Jean-Philippe Brucker

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=1600169070-13611-1-git-send-email-tiantao6@hisilicon.com \
    --to=tiantao6@hisilicon.com \
    --cc=catalin.marinas@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linuxarm@huawei.com \
    --cc=tglx@linutronix.de \
    --cc=vincenzo.frascino@arm.com \
    --cc=will@kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox