diff options
Diffstat (limited to 'com32/lib')
-rw-r--r-- | com32/lib/Makefile | 8 | ||||
-rw-r--r-- | com32/lib/errno.c | 7 | ||||
-rw-r--r-- | com32/lib/sys/file.h | 2 | ||||
-rw-r--r-- | com32/lib/sys/open.c | 2 | ||||
-rw-r--r-- | com32/lib/syslinux/ipappend.c | 13 | ||||
-rw-r--r-- | com32/lib/syslinux/runimage.c | 8 |
6 files changed, 13 insertions, 27 deletions
diff --git a/com32/lib/Makefile b/com32/lib/Makefile index a225f6f5..a7cfe770 100644 --- a/com32/lib/Makefile +++ b/com32/lib/Makefile @@ -125,8 +125,8 @@ LIBOTHER_OBJS = \ strnlen.o \ strncat.o strndup.o \ stpncpy.o \ - strntoimax.o strntoumax.o strsep.o strspn.o strstr.o \ - strtoimax.o strtok.o strtol.o strtoll.o strtoul.o strtoull.o \ + strntoimax.o strsep.o strspn.o strstr.o \ + strtoimax.o strtok.o strtol.o strtoll.o strtoull.o \ strtoumax.o vprintf.o vsprintf.o \ asprintf.o vasprintf.o \ vsscanf.o \ @@ -168,8 +168,8 @@ CORELIBOBJS = \ strlen.o vsnprintf.o snprintf.o stpcpy.o strcmp.o strdup.o \ strcpy.o strncpy.o setjmp.o fopen.o fread.o fread2.o puts.o \ sprintf.o strlcat.o strchr.o strlcpy.o strncasecmp.o ctypes.o \ - fputs.o fwrite2.o fwrite.o fgetc.o fclose.o errno.o lmalloc.o \ - sys/err_read.o sys/err_write.o sys/null_read.o \ + fputs.o fwrite2.o fwrite.o fgetc.o fclose.o lmalloc.o strtoul.o \ + sys/err_read.o sys/err_write.o sys/null_read.o strntoumax.o \ sys/stdcon_write.o \ syslinux/memscan.o strrchr.o strcat.o \ libgcc/__ashldi3.o libgcc/__udivdi3.o \ diff --git a/com32/lib/errno.c b/com32/lib/errno.c deleted file mode 100644 index f280e309..00000000 --- a/com32/lib/errno.c +++ /dev/null @@ -1,7 +0,0 @@ -/* - * errno.c - * - */ -#include <errno.h> - -int errno; diff --git a/com32/lib/sys/file.h b/com32/lib/sys/file.h index 4cd19464..f79b4f19 100644 --- a/com32/lib/sys/file.h +++ b/com32/lib/sys/file.h @@ -74,7 +74,7 @@ struct output_dev { /* File structure */ -#define NFILES 32 /* Number of files to support */ +#define NFILES 128 /* Number of files to support */ #define MAXBLOCK 16384 /* Defined by ABI */ struct file_info { diff --git a/com32/lib/sys/open.c b/com32/lib/sys/open.c index 3221bb60..1ed5bb4c 100644 --- a/com32/lib/sys/open.c +++ b/com32/lib/sys/open.c @@ -65,7 +65,7 @@ int open(const char *pathname, int flags, ...) fp = &__file_info[fd]; - handle = open_file(pathname, &fp->i.fd); + handle = open_file(pathname, flags, &fp->i.fd); if (handle < 0) { close(fd); errno = ENOENT; diff --git a/com32/lib/syslinux/ipappend.c b/com32/lib/syslinux/ipappend.c index 3eda48cf..11eb1bf5 100644 --- a/com32/lib/syslinux/ipappend.c +++ b/com32/lib/syslinux/ipappend.c @@ -1,6 +1,7 @@ /* ----------------------------------------------------------------------- * * * Copyright 2008 H. Peter Anvin - All Rights Reserved + * Copyright 2011 Intel Corporation; author: H. Peter Anvin * * Permission is hereby granted, free of charge, to any person * obtaining a copy of this software and associated documentation @@ -31,20 +32,16 @@ * Get ipappend strings */ +#include <syslinux/sysappend.h> #include <syslinux/config.h> +#include <syslinux/pmapi.h> #include <klibc/compiler.h> #include <core.h> struct syslinux_ipappend_strings __syslinux_ipappend_strings; -static const char *syslinux_ipappend_string_list[32]; void __constructor __syslinux_get_ipappend_strings(void) { - unsigned int i; - - __syslinux_ipappend_strings.count = (size_t)numIPAppends; - __syslinux_ipappend_strings.ptr = syslinux_ipappend_string_list; - - for (i = 0; i < (size_t)numIPAppends; i++) - syslinux_ipappend_string_list[i] = (const char *)(size_t)IPAppends[i]; + __syslinux_ipappend_strings.count = SYSAPPEND_MAX, + __syslinux_ipappend_strings.ptr = sysappend_strings; } diff --git a/com32/lib/syslinux/runimage.c b/com32/lib/syslinux/runimage.c index d3db75f3..4dcd029d 100644 --- a/com32/lib/syslinux/runimage.c +++ b/com32/lib/syslinux/runimage.c @@ -37,8 +37,6 @@ #include <syslinux/config.h> #include <core.h> -extern unsigned int ipappend; - void syslinux_run_kernel_image(const char *filename, const char *cmdline, uint32_t ipappend_flags, uint32_t type) { @@ -56,8 +54,6 @@ void syslinux_run_kernel_image(const char *filename, const char *cmdline, if (rv == -1 || (size_t)rv >= len) return; - if (syslinux_filesystem() == SYSLINUX_FS_PXELINUX) - ipappend = ipappend_flags; - - execute(bbcmdline, type); + SysAppends = ipappend_flags; + execute(bbcmdline, type, true); } |