From: zhaoxiao <zhaoxiao@uniontech.com>
To: tsbogend@alpha.franken.de
Cc: paul@crapouillou.net, linux-mips@vger.kernel.org,
linux-kernel@vger.kernel.org, zhaoxiao <zhaoxiao@uniontech.com>
Subject: [PATCH] arch/mips/boot/compressed/string.c: Fix build warnings
Date: Wed, 19 May 2021 16:44:05 +0800 [thread overview]
Message-ID: <20210519084405.27364-1-zhaoxiao@uniontech.com> (raw)
Fixes the following W=1 kernel build warning(s):
arch/mips/boot/compressed/string.c:11:7: warning: no previous prototype for 'memcpy' [-Wmissing-prototypes]
void *memcpy(void *dest, const void *src, size_t n)
^~~~~~
arch/mips/boot/compressed/string.c:22:7: warning: no previous prototype for 'memset' [-Wmissing-prototypes]
void *memset(void *s, int c, size_t n)
^~~~~~
arch/mips/boot/compressed/string.c:32:15: warning: no previous prototype for 'memmove' [-Wmissing-prototypes]
void * __weak memmove(void *dest, const void *src, size_t n)
^~~~~~~
Signed-off-by: zhaoxiao <zhaoxiao@uniontech.com>
---
arch/mips/boot/compressed/string.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/arch/mips/boot/compressed/string.c b/arch/mips/boot/compressed/string.c
index 0b593b709228..d28996509f91 100644
--- a/arch/mips/boot/compressed/string.c
+++ b/arch/mips/boot/compressed/string.c
@@ -8,7 +8,7 @@
#include <linux/compiler_attributes.h>
#include <linux/types.h>
-void *memcpy(void *dest, const void *src, size_t n)
+static void *memcpy(void *dest, const void *src, size_t n)
{
int i;
const char *s = src;
@@ -19,7 +19,7 @@ void *memcpy(void *dest, const void *src, size_t n)
return dest;
}
-void *memset(void *s, int c, size_t n)
+static void *memset(void *s, int c, size_t n)
{
int i;
char *ss = s;
@@ -29,7 +29,7 @@ void *memset(void *s, int c, size_t n)
return s;
}
-void * __weak memmove(void *dest, const void *src, size_t n)
+static void * __weak memmove(void *dest, const void *src, size_t n)
{
unsigned int i;
const char *s = src;
--
2.20.1
next reply other threads:[~2021-05-19 8:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-19 8:44 zhaoxiao [this message]
2021-05-19 14:00 ` [PATCH] arch/mips/boot/compressed/string.c: Fix build warnings Jiaxun Yang
2021-05-19 14:14 ` Paul Cercueil
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=20210519084405.27364-1-zhaoxiao@uniontech.com \
--to=zhaoxiao@uniontech.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@vger.kernel.org \
--cc=paul@crapouillou.net \
--cc=tsbogend@alpha.franken.de \
/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