* [PATCH] alpha/boot: fix the breakage from -isystem series...
@ 2023-01-11 20:43 Al Viro
2023-01-11 20:43 ` [PATCH] alpha/boot/tools/objstrip: fix the check for ELF header Al Viro
0 siblings, 1 reply; 3+ messages in thread
From: Al Viro @ 2023-01-11 20:43 UTC (permalink / raw)
To: linux-alpha
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
---
arch/alpha/boot/bootp.c | 2 +-
arch/alpha/boot/bootpz.c | 2 +-
arch/alpha/boot/main.c | 2 +-
arch/alpha/boot/stdio.c | 4 ++--
4 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/arch/alpha/boot/bootp.c b/arch/alpha/boot/bootp.c
index b4faba2432d5..842e85776cc0 100644
--- a/arch/alpha/boot/bootp.c
+++ b/arch/alpha/boot/bootp.c
@@ -18,7 +18,7 @@
#include <asm/hwrpb.h>
#include <asm/io.h>
-#include <stdarg.h>
+#include <linux/stdarg.h>
#include "ksize.h"
diff --git a/arch/alpha/boot/bootpz.c b/arch/alpha/boot/bootpz.c
index 90a2b341e9c0..c6079308eab3 100644
--- a/arch/alpha/boot/bootpz.c
+++ b/arch/alpha/boot/bootpz.c
@@ -20,7 +20,7 @@
#include <asm/hwrpb.h>
#include <asm/io.h>
-#include <stdarg.h>
+#include <linux/stdarg.h>
#include "kzsize.h"
diff --git a/arch/alpha/boot/main.c b/arch/alpha/boot/main.c
index e5347a080008..22a1cb0264af 100644
--- a/arch/alpha/boot/main.c
+++ b/arch/alpha/boot/main.c
@@ -15,7 +15,7 @@
#include <asm/console.h>
#include <asm/hwrpb.h>
-#include <stdarg.h>
+#include <linux/stdarg.h>
#include "ksize.h"
diff --git a/arch/alpha/boot/stdio.c b/arch/alpha/boot/stdio.c
index 60f73ccd2e89..a5abeaf94791 100644
--- a/arch/alpha/boot/stdio.c
+++ b/arch/alpha/boot/stdio.c
@@ -2,8 +2,8 @@
/*
* Copyright (C) Paul Mackerras 1997.
*/
-#include <stdarg.h>
-#include <stddef.h>
+#include <linux/string.h>
+#include <linux/stdarg.h>
size_t strnlen(const char * s, size_t count)
{
--
2.30.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH] alpha/boot/tools/objstrip: fix the check for ELF header
2023-01-11 20:43 [PATCH] alpha/boot: fix the breakage from -isystem series Al Viro
@ 2023-01-11 20:43 ` Al Viro
2023-01-11 20:44 ` alpha/boot/misc: trim unused declarations Al Viro
0 siblings, 1 reply; 3+ messages in thread
From: Al Viro @ 2023-01-11 20:43 UTC (permalink / raw)
To: linux-alpha
Just memcmp() with ELFMAG - that's the normal way to do it in userland
code, which that thing is. Besides, that has the benefit of actually
building - str_has_prefix() is *NOT* present in <string.h>.
Fixes: 5f14596e55de "alpha: Replace strncmp with str_has_prefix"
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
---
arch/alpha/boot/tools/objstrip.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/alpha/boot/tools/objstrip.c b/arch/alpha/boot/tools/objstrip.c
index 08b430d25a31..7cf92d172dce 100644
--- a/arch/alpha/boot/tools/objstrip.c
+++ b/arch/alpha/boot/tools/objstrip.c
@@ -148,7 +148,7 @@ main (int argc, char *argv[])
#ifdef __ELF__
elf = (struct elfhdr *) buf;
- if (elf->e_ident[0] == 0x7f && str_has_prefix((char *)elf->e_ident + 1, "ELF")) {
+ if (memcmp(&elf->e_ident[EI_MAG0], ELFMAG, SELFMAG) == 0) {
if (elf->e_type != ET_EXEC) {
fprintf(stderr, "%s: %s is not an ELF executable\n",
prog_name, inname);
--
2.30.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* alpha/boot/misc: trim unused declarations
2023-01-11 20:43 ` [PATCH] alpha/boot/tools/objstrip: fix the check for ELF header Al Viro
@ 2023-01-11 20:44 ` Al Viro
0 siblings, 0 replies; 3+ messages in thread
From: Al Viro @ 2023-01-11 20:44 UTC (permalink / raw)
To: linux-alpha
gzip_mark() and gzip_release() are gone; there used to be two
forward declarations of each and the patch removing those suckers
had left one of each behind...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
---
arch/alpha/boot/misc.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/arch/alpha/boot/misc.c b/arch/alpha/boot/misc.c
index 325d4dd4f904..1ab91852d9f7 100644
--- a/arch/alpha/boot/misc.c
+++ b/arch/alpha/boot/misc.c
@@ -89,8 +89,6 @@ static ulg output_ptr;
static ulg bytes_out;
static void error(char *m);
-static void gzip_mark(void **);
-static void gzip_release(void **);
extern int end;
static ulg free_mem_ptr;
--
2.30.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-01-11 20:44 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-01-11 20:43 [PATCH] alpha/boot: fix the breakage from -isystem series Al Viro
2023-01-11 20:43 ` [PATCH] alpha/boot/tools/objstrip: fix the check for ELF header Al Viro
2023-01-11 20:44 ` alpha/boot/misc: trim unused declarations Al Viro
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.