alpha/boot: fix the breakage from -isystem series...
PATCH 1/1 alpha/boot: fix the breakage from -isystem series...
Signed-off-by Al Viro <[email protected]>
--- 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(-)
arch/alpha/boot/bootp.c +1 -1
@@ -18,7 +18,7 @@#include <asm/hwrpb.h> #include <asm/io.h> -#include <stdarg.h> +#include <linux/stdarg.h> #include "ksize.h"
arch/alpha/boot/bootpz.c +1 -1
@@ -20,7 +20,7 @@#include <asm/hwrpb.h> #include <asm/io.h> -#include <stdarg.h> +#include <linux/stdarg.h> #include "kzsize.h"
arch/alpha/boot/main.c +1 -1
@@ -15,7 +15,7 @@#include <asm/console.h> #include <asm/hwrpb.h> -#include <stdarg.h> +#include <linux/stdarg.h> #include "ksize.h"
arch/alpha/boot/stdio.c +2 -2
@@ -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) {
Signature · 1 line
2.30.2
PATCH 1/1 alpha/boot/tools/objstrip: fix the check for ELF header
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 <[email protected]>
--- arch/alpha/boot/tools/objstrip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/alpha/boot/tools/objstrip.c +1 -1
@@ -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);
Signature · 1 line
2.30.2
alpha/boot/misc: trim unused declarations
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 <[email protected]>
--- arch/alpha/boot/misc.c | 2 -- 1 file changed, 2 deletions(-)
arch/alpha/boot/misc.c +0 -2
@@ -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;
Signature · 1 line
2.30.2