Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1167500rwd; Tue, 16 May 2023 12:52:00 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7HrlAUdQjMD/eKHrEiRGomWmmOTAxV3zs4INXn7V7F7whjdqYeKbQ6COAEr+kOtXRl0LlE X-Received: by 2002:a05:6a21:7896:b0:101:1951:d4ae with SMTP id bf22-20020a056a21789600b001011951d4aemr35865409pzc.14.1684266720452; Tue, 16 May 2023 12:52:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684266720; cv=none; d=google.com; s=arc-20160816; b=WdEGhdZ06axoC9kvhFVgL0kFtqUawcST+S6ifytVRW4bmOgQhOYyp9S4Fp6HP61fe9 5ycnl74Hx1Hca3gvBaCcMpOzdGZQVlwYg3zqDWcpd0mDxcm4HOD1hjEGV7hQOQhWGicv 0hPS4DuFuCJsDLLqBECA0qixN3FFRV1zhldHfmsAbtTN/ifuJQPHkEX5n+hzESR4hwS7 OJd4lxHnJSi1qnEZVW6ISqApZNEehI6lcCiE0Q7LuYFN3shmzf9BUxeZJxkpLUgpYJk8 hpT1HcG+PmcwLkqPnQ1RWV9Vl9gww7KWZmukIJ05KsBczrnJhiC0k3/OTu/GMbaF1BeR QQHg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=O6xJdLbEOI/54+AC04d1brsd6N0qTT4pdlPZE+xRiwc=; b=fCVNqhz8K5rrMltqvFFq96q6Vd9GAhWB/gUc7W6hxLs9853L5imeT8d0wx8zSvcrUp wsy5tUqWEMyNosfq1Qbd476rxF7i+dOjtNUdvsBtvyigoJzkfMqxsALrGl8E6yZbji4a y72q3zymfMDHNE+hKqCnodty+/MDTvm+sHh37c7k0LtUDgEtJFFHSXN8mgkAsFzaZbF5 k7myExur/WkU5NaQr8lclmqxHg4cIahsqGEG/JLEyIgcwg1fgE0CyzZP3VxhKBl48mrr NW4j52pGcPVJplUxJFHHfxf7/4TTNKA71cC+gIRjS1jyIQTC93U/ZCO5ZiuS2Q364PwZ AcRQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=KwDbO61f; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f199-20020a6238d0000000b0063b8eec0832si19928375pfa.114.2023.05.16.12.51.48; Tue, 16 May 2023 12:52:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=KwDbO61f; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229879AbjEPTgM (ORCPT + 99 others); Tue, 16 May 2023 15:36:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55066 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229458AbjEPTgJ (ORCPT ); Tue, 16 May 2023 15:36:09 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8AEB03ABC; Tue, 16 May 2023 12:36:08 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 2479563D02; Tue, 16 May 2023 19:36:08 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E5E20C433EF; Tue, 16 May 2023 19:36:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1684265767; bh=oAoSmF3XxuLgHtI7FvZzT7auqFocUXgu+0MePwNsyrE=; h=From:To:Cc:Subject:Date:From; b=KwDbO61f3SBWhJix8Gr20ak/Qqboqqh3ldX/gA4euZLkNvRlBoYXYxgW34oKD5+bq lgA3GGHMsATzDaZfCh2jM0WzWNvEFjiOGPlsVGcQu/sXjiIoK3zNv5yWDm1DhznX7Y 9C89B6xO5lEbyaGUNpJ+Oy07z9iVjaOP927NmsglHmbwU2P2dm4OwFSIPr5PJ2r5Gz 1qqAqLg3NzZPU+tuOvCbIzt9KUilvGUbJ8Y+hlsLmDHIjedHIx/H1y1Bj+xZR8Goe8 03nF3w/T1w6FhjESnpTOJw33XxK0QUG9UAP0KyuSJ0VYZg4J2UxgOMGzi+kT2/XCMT GZd4OSYv/yqOQ== From: Arnd Bergmann To: x86@kernel.org Cc: Arnd Bergmann , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , "H. Peter Anvin" , Andy Lutomirski , Steven Rostedt , Masami Hiramatsu , Mark Rutland , Juergen Gross , "Srivatsa S. Bhat (VMware)" , Alexey Makhalov , VMware PV-Drivers Reviewers , Peter Zijlstra , Darren Hart , Andy Shevchenko , Boris Ostrovsky , "Rafael J. Wysocki" , linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org, virtualization@lists.linux-foundation.org, linux-pci@vger.kernel.org, platform-driver-x86@vger.kernel.org, xen-devel@lists.xenproject.org, linux-pm@vger.kernel.org, linux-mm@kvack.org Subject: [PATCH 00/20] x86: address -Wmissing-prototype warnings Date: Tue, 16 May 2023 21:35:29 +0200 Message-Id: <20230516193549.544673-1-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Arnd Bergmann This addresses all x86 specific prototype warnings. The majority of the patches should be straightforward, either adding an #include statement to get the right header, or ensuring that an unused global function is left out of the build when the prototype is hidden. The ones that are a bit awkward are those that just add a prototype to shut up the warning, but the prototypes are never used for calling the function because the only caller is in assembler code. I tried to come up with other ways to shut up the compiler using the asmlinkage annotation, but with no success. All of the warnings have to be addressed in some form before the warning can be enabled by default. Arnd Link: https://people.kernel.org/arnd/missing-prototype-warnings-in-the-kernel Arnd Bergmann (20): x86: move prepare_ftrace_return prototype to header x86: ce4100: Mark local functions as 'static' x86: apic: hide unused safe_smp_processor_id on UP x86: avoid unneeded __div64_32 function definition x86: head: add dummy prototype for mk_early_pgtbl_32 x86: math-emu: include asm/fpu/regset.h x86: doublefault: avoid missing-prototype warnings x86: highmem: include asm/numa.h for set_highmem_pages_init x86: platform_quirks: include linux/pnp.h for arch_pnpbios_disabled x86: xen: add missing prototypes x86: entry: add do_SYSENTER_32() prototype x86: qspinlock-paravirt: fix mising-prototype warnings x86: hibernate: declare global functions in suspend.h x86: fbdev: include asm/fb.h as needed x86: mce: add copy_mc_fragile_handle_tail prototype x86: vdso: include vdso/processor.h x86: usercopy: include arch_wb_cache_pmem declaration x86: ioremap: add early_memremap_pgprot_adjust prototype x86: purgatory: include header for warn() declaration x86: olpc: avoid missing-prototype warnings arch/x86/boot/compressed/error.c | 2 +- arch/x86/boot/compressed/error.h | 2 +- arch/x86/entry/vdso/vgetcpu.c | 1 + arch/x86/include/asm/div64.h | 2 ++ arch/x86/include/asm/doublefault.h | 4 ++++ arch/x86/include/asm/ftrace.h | 3 +++ arch/x86/include/asm/mce.h | 3 +++ arch/x86/include/asm/qspinlock_paravirt.h | 2 ++ arch/x86/include/asm/syscall.h | 6 ++++-- arch/x86/kernel/apic/ipi.c | 2 ++ arch/x86/kernel/doublefault_32.c | 1 + arch/x86/kernel/ftrace.c | 3 --- arch/x86/kernel/head32.c | 1 + arch/x86/kernel/paravirt.c | 2 ++ arch/x86/kernel/platform-quirks.c | 1 + arch/x86/lib/usercopy_64.c | 1 + arch/x86/math-emu/fpu_entry.c | 1 + arch/x86/mm/highmem_32.c | 1 + arch/x86/pci/ce4100.c | 4 ++-- arch/x86/platform/olpc/olpc_dt.c | 2 +- arch/x86/purgatory/purgatory.c | 1 + arch/x86/video/fbdev.c | 1 + arch/x86/xen/efi.c | 2 ++ arch/x86/xen/smp.h | 3 +++ arch/x86/xen/xen-ops.h | 14 ++++++++++++++ include/linux/io.h | 5 +++++ include/linux/olpc-ec.h | 2 ++ include/linux/suspend.h | 4 ++++ include/xen/xen.h | 3 +++ kernel/locking/qspinlock_paravirt.h | 20 ++++++++++---------- kernel/power/power.h | 5 ----- mm/internal.h | 6 ------ 32 files changed, 79 insertions(+), 31 deletions(-) -- 2.39.2 Cc: Thomas Gleixner (maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT),commit_signer:1/5=20%,authored:1/5=20%) Cc: Ingo Molnar (maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)) Cc: Borislav Petkov (maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT),commit_signer:1/3=33%,commit_signer:1/5=20%,authored:1/5=20%,removed_lines:40/51=78%) Cc: Dave Hansen (maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT),commit_signer:1/5=20%) Cc: x86@kernel.org (maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)) Cc: "H. Peter Anvin" (reviewer:X86 ARCHITECTURE (32-BIT AND 64-BIT)) Cc: Andy Lutomirski (maintainer:X86 VDSO) Cc: Steven Rostedt (maintainer:FUNCTION HOOKS (FTRACE)) Cc: Masami Hiramatsu (maintainer:FUNCTION HOOKS (FTRACE)) Cc: Mark Rutland (reviewer:FUNCTION HOOKS (FTRACE)) Cc: Juergen Gross (supporter:PARAVIRT_OPS INTERFACE,commit_signer:2/5=40%,authored:1/5=20%,added_lines:20/31=65%,removed_lines:27/35=77%) Cc: "Srivatsa S. Bhat (VMware)" (supporter:PARAVIRT_OPS INTERFACE) Cc: Alexey Makhalov (reviewer:PARAVIRT_OPS INTERFACE) Cc: VMware PV-Drivers Reviewers (reviewer:PARAVIRT_OPS INTERFACE) Cc: Peter Zijlstra (maintainer:X86 MM,commit_signer:4/5=80%,commit_signer:1/2=50%) Cc: Darren Hart (reviewer:X86 PLATFORM DRIVERS - ARCH) Cc: Andy Shevchenko (reviewer:X86 PLATFORM DRIVERS - ARCH) Cc: Boris Ostrovsky (reviewer:XEN HYPERVISOR X86) Cc: "Rafael J. Wysocki" (supporter:HIBERNATION (aka Software Suspend, aka swsusp)) Cc: linux-kernel@vger.kernel.org (open list:X86 ARCHITECTURE (32-BIT AND 64-BIT)) Cc: linux-trace-kernel@vger.kernel.org (open list:FUNCTION HOOKS (FTRACE)) Cc: virtualization@lists.linux-foundation.org (open list:PARAVIRT_OPS INTERFACE) Cc: linux-pci@vger.kernel.org (open list:PCI SUBSYSTEM) Cc: platform-driver-x86@vger.kernel.org (open list:X86 PLATFORM DRIVERS - ARCH) Cc: xen-devel@lists.xenproject.org (moderated list:XEN HYPERVISOR X86) Cc: linux-pm@vger.kernel.org (open list:HIBERNATION (aka Software Suspend, aka swsusp)) Cc: linux-mm@kvack.org (open list:MEMORY MANAGEMENT)