All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nathan Chancellor <nathan@kernel.org>
To: bcain@quicinc.com, akpm@linux-foundation.org, arnd@arndb.de
Cc: linux-hexagon@vger.kernel.org, llvm@lists.linux.dev,
	 patches@lists.linux.dev, Nathan Chancellor <nathan@kernel.org>
Subject: [PATCH 12/19] hexagon: reset: Include linux/reboot.h for prototypes
Date: Thu, 30 Nov 2023 15:58:25 -0700	[thread overview]
Message-ID: <20231130-hexagon-missing-prototypes-v1-12-5c34714afe9e@kernel.org> (raw)
In-Reply-To: <20231130-hexagon-missing-prototypes-v1-0-5c34714afe9e@kernel.org>

Clang warns about missing prototypes that are declared in this header:

  arch/hexagon/kernel/reset.c:9:6: warning: no previous prototype for function 'machine_power_off' [-Wmissing-prototypes]
      9 | void machine_power_off(void)
        |      ^
  arch/hexagon/kernel/reset.c:9:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
      9 | void machine_power_off(void)
        | ^
        | static
  arch/hexagon/kernel/reset.c:15:6: warning: no previous prototype for function 'machine_halt' [-Wmissing-prototypes]
     15 | void machine_halt(void)
        |      ^
  arch/hexagon/kernel/reset.c:15:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
     15 | void machine_halt(void)
        | ^
        | static
  arch/hexagon/kernel/reset.c:19:6: warning: no previous prototype for function 'machine_restart' [-Wmissing-prototypes]
     19 | void machine_restart(char *cmd)
        |      ^
  arch/hexagon/kernel/reset.c:19:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
     19 | void machine_restart(char *cmd)
        | ^
        | static
  3 warnings generated.

Signed-off-by: Nathan Chancellor <nathan@kernel.org>
---
 arch/hexagon/kernel/reset.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/hexagon/kernel/reset.c b/arch/hexagon/kernel/reset.c
index da36114d928f..efd70a8d2526 100644
--- a/arch/hexagon/kernel/reset.c
+++ b/arch/hexagon/kernel/reset.c
@@ -3,6 +3,7 @@
  * Copyright (c) 2010-2011, The Linux Foundation. All rights reserved.
  */
 
+#include <linux/reboot.h>
 #include <linux/smp.h>
 #include <asm/hexagon_vm.h>
 

-- 
2.43.0


  parent reply	other threads:[~2023-11-30 22:58 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-30 22:58 [PATCH 00/19] hexagon: Fix up instances of -Wmissing-prototypes Nathan Chancellor
2023-11-30 22:58 ` [PATCH 01/19] hexagon: uaccess: Remove clear_user_hexagon() Nathan Chancellor
2023-11-30 22:58 ` [PATCH 02/19] hexagon: mm: Mark paging_init() as static Nathan Chancellor
2023-11-30 22:58 ` [PATCH 03/19] hexagon: mm: Include asm/setup.h for setup_arch_memory()'s prototype Nathan Chancellor
2023-11-30 22:58 ` [PATCH 04/19] hexagon: smp: Mark handle_ipi() and start_secondary() as static Nathan Chancellor
2023-11-30 22:58 ` [PATCH 05/19] hexagon: vm_fault: Mark do_page_fault() " Nathan Chancellor
2023-11-30 22:58 ` [PATCH 06/19] hexagon: vm_fault: Include asm/vm_fault.h for prototypes Nathan Chancellor
2023-11-30 22:58 ` [PATCH 07/19] hexagon: vm_tlb: Include asm/tlbflush.h " Nathan Chancellor
2023-11-30 22:58 ` [PATCH 08/19] hexagon: time: Include asm/time.h " Nathan Chancellor
2023-11-30 22:58 ` [PATCH 09/19] hexagon: time: Mark time_init_deferred() as static Nathan Chancellor
2023-11-30 22:58 ` [PATCH 10/19] hexagon: time: Include asm/delay.h for prototypes Nathan Chancellor
2023-11-30 22:58 ` [PATCH 11/19] hexagon: signal: Switch to SYSCALL_DEFINE0 for sys_rt_sigreturn() Nathan Chancellor
2023-11-30 22:58 ` Nathan Chancellor [this message]
2023-11-30 22:58 ` [PATCH 13/19] hexagon: process: Include linux/cpu.h for arch_cpu_idle() prototype Nathan Chancellor
2023-11-30 22:58 ` [PATCH 14/19] hexagon: process: Add internal prototype for do_work_pending() Nathan Chancellor
2023-11-30 22:58 ` [PATCH 15/19] hexagon: vdso: Include asm/elf.h for arch_setup_additional_pages() prototype Nathan Chancellor
2023-11-30 22:58 ` [PATCH 16/19] hexagon: vm_events: Remove unused dummy_handler() Nathan Chancellor
2023-11-30 22:58 ` [PATCH 17/19] hexagon: irq: Add prototype for arch_do_IRQ() Nathan Chancellor
2023-11-30 22:58 ` [PATCH 18/19] hexagon: traps: Remove sys_syscall() Nathan Chancellor
2023-11-30 22:58 ` [PATCH 19/19] hexagon: traps: Add internal prototypes for functions only called from asm Nathan Chancellor
2023-11-30 23:38 ` [PATCH 00/19] hexagon: Fix up instances of -Wmissing-prototypes Andrew Morton
2023-12-01  7:12 ` Arnd Bergmann

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=20231130-hexagon-missing-prototypes-v1-12-5c34714afe9e@kernel.org \
    --to=nathan@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=arnd@arndb.de \
    --cc=bcain@quicinc.com \
    --cc=linux-hexagon@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=patches@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.