arm64: move cpu_suspend_set_dbg_restorer() prototype to header
authorArnd Bergmann <arnd@arndb.de>
Tue, 16 May 2023 16:06:31 +0000 (18:06 +0200)
committerCatalin Marinas <catalin.marinas@arm.com>
Thu, 25 May 2023 16:44:01 +0000 (17:44 +0100)
commitec3a3db7100ddebb32ed5b1052c1cd1136057230
tree64d6f0ad230fe15aadf06c6010323116ef0e1364
parent6ac19f96515e1f5198503701d3aecf60d5bc83e5
arm64: move cpu_suspend_set_dbg_restorer() prototype to header

The cpu_suspend_set_dbg_restorer() function is called by the hw_breakpoint
code but defined in another file. Since the declaration is in the
same file as the caller, the compiler warns about the definition
without a prior prototype:

arch/arm64/kernel/suspend.c:35:13: error: no previous prototype for 'cpu_suspend_set_dbg_restorer' [-Werror=missing-prototypes]

Move it into the corresponding header instead to avoid the warning.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Kees Cook <keescook@chromium.org>
Acked-by: Ard Biesheuvel <ardb@kernel.org>
Link: https://lore.kernel.org/r/20230516160642.523862-5-arnd@kernel.org
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/include/asm/hw_breakpoint.h
arch/arm64/kernel/hw_breakpoint.c