From: Dan Williams <dan.j.williams@intel.com>
To: kernel test robot <lkp@intel.com>
Cc: kbuild-all@lists.01.org,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Borislav Petkov <bp@suse.de>, Tony Luck <tony.luck@intel.com>
Subject: Re: arch/x86/lib/copy_mc.c:30:1: warning: no previous prototype for 'copy_mc_fragile_handle_tail'
Date: Wed, 9 Jun 2021 16:43:25 -0700 [thread overview]
Message-ID: <CAPcyv4jAkutNExqao0Q1HYL-pQxrSbAN3F5N9Uj=09KDa_uynw@mail.gmail.com> (raw)
In-Reply-To: <202106100613.JQBEtsqj-lkp@intel.com>
On Wed, Jun 9, 2021 at 3:43 PM kernel test robot <lkp@intel.com> wrote:
>
> Hi Dan,
>
> FYI, the error/warning still remains.
>
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head: 368094df48e680fa51cedb68537408cfa64b788e
> commit: ec6347bb43395cb92126788a1a5b25302543f815 x86, powerpc: Rename memcpy_mcsafe() to copy_mc_to_{user, kernel}()
> date: 8 months ago
> config: x86_64-randconfig-r025-20210610 (attached as .config)
> compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
> reproduce (this is a W=1 build):
> # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=ec6347bb43395cb92126788a1a5b25302543f815
> git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
> git fetch --no-tags linus master
> git checkout ec6347bb43395cb92126788a1a5b25302543f815
> # save the attached .config to linux build tree
> make W=1 ARCH=x86_64
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@intel.com>
>
> All warnings (new ones prefixed by >>):
>
> >> arch/x86/lib/copy_mc.c:30:1: warning: no previous prototype for 'copy_mc_fragile_handle_tail' [-Wmissing-prototypes]
> 30 | copy_mc_fragile_handle_tail(char *to, char *from, unsigned len)
> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~
This routine is only ever called from ASM code, so the fact that there
is no C declaration is expected.
For W=1 builds we could do something like this:
diff --git a/arch/x86/lib/Makefile b/arch/x86/lib/Makefile
index bad4dee4f0e4..b87f40cbc3d5 100644
--- a/arch/x86/lib/Makefile
+++ b/arch/x86/lib/Makefile
@@ -44,6 +44,7 @@ obj-$(CONFIG_SMP) += msr-smp.o cache-smp.o
lib-y := delay.o misc.o cmdline.o cpu.o
lib-y += usercopy_$(BITS).o usercopy.o getuser.o putuser.o
lib-y += memcpy_$(BITS).o
+CFLAGS_copy_mc.o = -Wno-strict-prototypes
lib-$(CONFIG_ARCH_HAS_COPY_MC) += copy_mc.o copy_mc_64.o
lib-$(CONFIG_INSTRUCTION_DECODER) += insn.o inat.o insn-eval.o
lib-$(CONFIG_RANDOMIZE_BASE) += kaslr.o
...but I don't like it nor adding a dummy declaration.
next prev parent reply other threads:[~2021-06-09 23:43 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-09 22:43 arch/x86/lib/copy_mc.c:30:1: warning: no previous prototype for 'copy_mc_fragile_handle_tail' kernel test robot
2021-06-09 23:43 ` Dan Williams [this message]
2021-06-09 23:55 ` Luck, Tony
2021-06-10 0:13 ` Dan Williams
-- strict thread matches above, loose matches on Subject: below --
2021-04-28 8:32 kernel test robot
2021-03-30 18:10 kernel test robot
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='CAPcyv4jAkutNExqao0Q1HYL-pQxrSbAN3F5N9Uj=09KDa_uynw@mail.gmail.com' \
--to=dan.j.williams@intel.com \
--cc=bp@suse.de \
--cc=kbuild-all@lists.01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lkp@intel.com \
--cc=tony.luck@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).