summaryrefslogtreecommitdiff
path: root/arch/parisc
diff options
context:
space:
mode:
authorYu-Chun Lin <eleanor15x@gmail.com>2025-02-09 01:43:04 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-05-02 07:47:01 +0200
commitd0db2eb9902961dac019c1043449ffce776fe997 (patch)
treef0ba238ce595667c9142491c2b7db1d1488468d0 /arch/parisc
parent2236d765a3658b57fd5ced80398fc963eaddac0d (diff)
downloadlinux-d0db2eb9902961dac019c1043449ffce776fe997.tar.gz
linux-d0db2eb9902961dac019c1043449ffce776fe997.tar.bz2
linux-d0db2eb9902961dac019c1043449ffce776fe997.zip
parisc: PDT: Fix missing prototype warning
[ Upstream commit b899981750dcb958ceffa4462d903963ee494aa2 ] As reported by the kernel test robot, the following error occurs: arch/parisc/kernel/pdt.c:65:6: warning: no previous prototype for 'arch_report_meminfo' [-Wmissing-prototypes] 65 | void arch_report_meminfo(struct seq_file *m) | ^~~~~~~~~~~~~~~~~~~ arch_report_meminfo() is declared in include/linux/proc_fs.h and only defined when CONFIG_PROC_FS is enabled. Wrap its definition in #ifdef CONFIG_PROC_FS to fix the -Wmissing-prototypes warning. Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202502082315.IPaHaTyM-lkp@intel.com/ Signed-off-by: Yu-Chun Lin <eleanor15x@gmail.com> Signed-off-by: Helge Deller <deller@gmx.de> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'arch/parisc')
-rw-r--r--arch/parisc/kernel/pdt.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/parisc/kernel/pdt.c b/arch/parisc/kernel/pdt.c
index e391b175f5ec..7dbb241a9fb7 100644
--- a/arch/parisc/kernel/pdt.c
+++ b/arch/parisc/kernel/pdt.c
@@ -62,6 +62,7 @@ static unsigned long pdt_entry[MAX_PDT_ENTRIES] __page_aligned_bss;
#define PDT_ADDR_PERM_ERR (pdt_type != PDT_PDC ? 2UL : 0UL)
#define PDT_ADDR_SINGLE_ERR 1UL
+#ifdef CONFIG_PROC_FS
/* report PDT entries via /proc/meminfo */
void arch_report_meminfo(struct seq_file *m)
{
@@ -73,6 +74,7 @@ void arch_report_meminfo(struct seq_file *m)
seq_printf(m, "PDT_cur_entries: %7lu\n",
pdt_status.pdt_entries);
}
+#endif
static int get_info_pat_new(void)
{