All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@kernel.org>
To: Russell King <linux@armlinux.org.uk>
Cc: Arnd Bergmann <arnd@arndb.de>,
	Steven Rostedt <rostedt@goodmis.org>,
	Masami Hiramatsu <mhiramat@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Oleg Nesterov <oleg@redhat.com>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	Pavel Machek <pavel@ucw.cz>,
	Linus Walleij <linus.walleij@linaro.org>,
	Ard Biesheuvel <ardb@kernel.org>,
	Kees Cook <keescook@chromium.org>,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org,
	linux-pm@vger.kernel.org
Subject: [PATCH 04/16] ARM: vdso: add missing prototypes
Date: Tue, 16 May 2023 17:45:53 +0200	[thread overview]
Message-ID: <20230516154605.517690-5-arnd@kernel.org> (raw)
In-Reply-To: <20230516154605.517690-1-arnd@kernel.org>

From: Arnd Bergmann <arnd@arndb.de>

The __vdso_clock_* functions have no prototype, and the
__eabi_unwind_cpp_pr* functions have a prototype in a header that is
not included before the definition:

arch/arm/vdso/vgettimeofday.c:10:5: error: no previous prototype for '__vdso_clock_gettime' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:16:5: error: no previous prototype for '__vdso_clock_gettime64' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:22:5: error: no previous prototype for '__vdso_gettimeofday' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:28:5: error: no previous prototype for '__vdso_clock_getres' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:36:6: error: no previous prototype for '__aeabi_unwind_cpp_pr0' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:40:6: error: no previous prototype for '__aeabi_unwind_cpp_pr1' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:44:6: error: no previous prototype for '__aeabi_unwind_cpp_pr2' [-Werror=missing-prototypes]

Add the prototypes in an appropriate header and ensure that
both are included here.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 arch/arm/include/asm/vdso.h   | 5 +++++
 arch/arm/vdso/vgettimeofday.c | 2 ++
 2 files changed, 7 insertions(+)

diff --git a/arch/arm/include/asm/vdso.h b/arch/arm/include/asm/vdso.h
index 5b85889f82ee..422c3afa806a 100644
--- a/arch/arm/include/asm/vdso.h
+++ b/arch/arm/include/asm/vdso.h
@@ -24,6 +24,11 @@ static inline void arm_install_vdso(struct mm_struct *mm, unsigned long addr)
 
 #endif /* CONFIG_VDSO */
 
+int __vdso_clock_gettime(clockid_t clock, struct old_timespec32 *ts);
+int __vdso_clock_gettime64(clockid_t clock, struct __kernel_timespec *ts);
+int __vdso_gettimeofday(struct __kernel_old_timeval *tv, struct timezone *tz);
+int __vdso_clock_getres(clockid_t clock_id, struct old_timespec32 *res);
+
 #endif /* __ASSEMBLY__ */
 
 #endif /* __KERNEL__ */
diff --git a/arch/arm/vdso/vgettimeofday.c b/arch/arm/vdso/vgettimeofday.c
index 1976c6f325a4..a003beacac76 100644
--- a/arch/arm/vdso/vgettimeofday.c
+++ b/arch/arm/vdso/vgettimeofday.c
@@ -6,6 +6,8 @@
  */
 #include <linux/time.h>
 #include <linux/types.h>
+#include <asm/vdso.h>
+#include <asm/unwind.h>
 
 int __vdso_clock_gettime(clockid_t clock,
 			 struct old_timespec32 *ts)
-- 
2.39.2


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

WARNING: multiple messages have this Message-ID (diff)
From: Arnd Bergmann <arnd@kernel.org>
To: Russell King <linux@armlinux.org.uk>
Cc: Arnd Bergmann <arnd@arndb.de>,
	Steven Rostedt <rostedt@goodmis.org>,
	Masami Hiramatsu <mhiramat@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Oleg Nesterov <oleg@redhat.com>,
	"Rafael J. Wysocki" <rafael@kernel.org>,
	Pavel Machek <pavel@ucw.cz>,
	Linus Walleij <linus.walleij@linaro.org>,
	Ard Biesheuvel <ardb@kernel.org>,
	Kees Cook <keescook@chromium.org>,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org,
	linux-pm@vger.kernel.org
Subject: [PATCH 04/16] ARM: vdso: add missing prototypes
Date: Tue, 16 May 2023 17:45:53 +0200	[thread overview]
Message-ID: <20230516154605.517690-5-arnd@kernel.org> (raw)
In-Reply-To: <20230516154605.517690-1-arnd@kernel.org>

From: Arnd Bergmann <arnd@arndb.de>

The __vdso_clock_* functions have no prototype, and the
__eabi_unwind_cpp_pr* functions have a prototype in a header that is
not included before the definition:

arch/arm/vdso/vgettimeofday.c:10:5: error: no previous prototype for '__vdso_clock_gettime' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:16:5: error: no previous prototype for '__vdso_clock_gettime64' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:22:5: error: no previous prototype for '__vdso_gettimeofday' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:28:5: error: no previous prototype for '__vdso_clock_getres' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:36:6: error: no previous prototype for '__aeabi_unwind_cpp_pr0' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:40:6: error: no previous prototype for '__aeabi_unwind_cpp_pr1' [-Werror=missing-prototypes]
arch/arm/vdso/vgettimeofday.c:44:6: error: no previous prototype for '__aeabi_unwind_cpp_pr2' [-Werror=missing-prototypes]

Add the prototypes in an appropriate header and ensure that
both are included here.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 arch/arm/include/asm/vdso.h   | 5 +++++
 arch/arm/vdso/vgettimeofday.c | 2 ++
 2 files changed, 7 insertions(+)

diff --git a/arch/arm/include/asm/vdso.h b/arch/arm/include/asm/vdso.h
index 5b85889f82ee..422c3afa806a 100644
--- a/arch/arm/include/asm/vdso.h
+++ b/arch/arm/include/asm/vdso.h
@@ -24,6 +24,11 @@ static inline void arm_install_vdso(struct mm_struct *mm, unsigned long addr)
 
 #endif /* CONFIG_VDSO */
 
+int __vdso_clock_gettime(clockid_t clock, struct old_timespec32 *ts);
+int __vdso_clock_gettime64(clockid_t clock, struct __kernel_timespec *ts);
+int __vdso_gettimeofday(struct __kernel_old_timeval *tv, struct timezone *tz);
+int __vdso_clock_getres(clockid_t clock_id, struct old_timespec32 *res);
+
 #endif /* __ASSEMBLY__ */
 
 #endif /* __KERNEL__ */
diff --git a/arch/arm/vdso/vgettimeofday.c b/arch/arm/vdso/vgettimeofday.c
index 1976c6f325a4..a003beacac76 100644
--- a/arch/arm/vdso/vgettimeofday.c
+++ b/arch/arm/vdso/vgettimeofday.c
@@ -6,6 +6,8 @@
  */
 #include <linux/time.h>
 #include <linux/types.h>
+#include <asm/vdso.h>
+#include <asm/unwind.h>
 
 int __vdso_clock_gettime(clockid_t clock,
 			 struct old_timespec32 *ts)
-- 
2.39.2


  parent reply	other threads:[~2023-05-16 15:47 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-16 15:45 [PATCH 00/16] ARM: address -Wmissing-prototype warnings Arnd Bergmann
2023-05-16 15:45 ` Arnd Bergmann
2023-05-16 15:45 ` [PATCH 01/16] ARM: dma-mapping: hide unused dma_contiguous_early_fixup function Arnd Bergmann
2023-05-16 15:45   ` Arnd Bergmann
2023-05-16 15:45 ` [PATCH 02/16] ARM: traps: hide unused functions on NOMMU Arnd Bergmann
2023-05-16 15:45   ` Arnd Bergmann
2023-05-16 15:45 ` [PATCH 03/16] ARM: vfp: include asm/neon.h in vfpmodule.c Arnd Bergmann
2023-05-16 15:45   ` Arnd Bergmann
2023-05-16 15:45 ` Arnd Bergmann [this message]
2023-05-16 15:45   ` [PATCH 04/16] ARM: vdso: add missing prototypes Arnd Bergmann
2023-05-16 15:45 ` [PATCH 05/16] ARM: kprobes: avoid missing-declaration warnings Arnd Bergmann
2023-05-16 15:45   ` Arnd Bergmann
2023-05-17  1:29   ` Masami Hiramatsu
2023-05-17  1:29     ` Masami Hiramatsu
2023-05-16 15:45 ` [PATCH 06/16] ARM: tcm: move tcm_init() prototype to asm/tcm.h Arnd Bergmann
2023-05-16 15:45   ` Arnd Bergmann
2023-05-22  7:34   ` Linus Walleij
2023-05-22  7:34     ` Linus Walleij
2023-05-16 15:45 ` [PATCH 07/16] ARM: add prototype for function called only from asm Arnd Bergmann
2023-05-16 15:45   ` Arnd Bergmann
2023-05-16 15:45 ` [PATCH 08/16] ARM: add clear/copy_user_highpage declarations Arnd Bergmann
2023-05-16 15:45   ` Arnd Bergmann
2023-05-16 15:45 ` [PATCH 09/16] ARM: cacheflush: avoid __flush_anon_page() missing-prototype warning Arnd Bergmann
2023-05-16 15:45   ` Arnd Bergmann
2023-05-16 15:45 ` [PATCH 10/16] ARM: nommu: include asm/idmap.h Arnd Bergmann
2023-05-16 15:45   ` Arnd Bergmann
2023-05-16 15:46 ` [PATCH 11/16] ARM: move setup functions to header Arnd Bergmann
2023-05-16 15:46   ` Arnd Bergmann
2023-05-22  7:35   ` Linus Walleij
2023-05-22  7:35     ` Linus Walleij
2023-05-16 15:46 ` [PATCH 12/16] ARM: fiq: include asm/mach/irq.h for prototypes Arnd Bergmann
2023-05-16 15:46   ` Arnd Bergmann
2023-05-16 15:46 ` [PATCH 13/16] ARM: vfp: add vfp_entry prototype Arnd Bergmann
2023-05-16 15:46   ` Arnd Bergmann
2023-05-17 11:13   ` Ard Biesheuvel
2023-05-17 11:13     ` Ard Biesheuvel
2023-05-16 15:46 ` [PATCH 14/16] ARM: add missing syscall prototypes Arnd Bergmann
2023-05-16 15:46   ` Arnd Bergmann
2023-05-16 15:46 ` [PATCH 15/16] ARM: decompressor: move function prototypes to misc.h Arnd Bergmann
2023-05-16 15:46   ` Arnd Bergmann
2023-05-16 15:46 ` [PATCH 16/16] ARM: xip-kernel: add __inflate_kernel_data prototype Arnd Bergmann
2023-05-16 15:46   ` Arnd Bergmann
2023-05-16 19:56 ` [PATCH 00/16] ARM: address -Wmissing-prototype warnings Kees Cook
2023-05-16 19:56   ` Kees Cook

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=20230516154605.517690-5-arnd@kernel.org \
    --to=arnd@kernel.org \
    --cc=ardb@kernel.org \
    --cc=arnd@arndb.de \
    --cc=keescook@chromium.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-trace-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=mark.rutland@arm.com \
    --cc=mhiramat@kernel.org \
    --cc=oleg@redhat.com \
    --cc=pavel@ucw.cz \
    --cc=rafael@kernel.org \
    --cc=rostedt@goodmis.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 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.