search for: com32_filedata

Displaying 17 results from an estimated 17 matches for "com32_filedata".

2011 Jul 12
0
[PATCH] pxelinux: open_file() returns a non-negative handle
...at linux.intel.com> --- core/fs/pxe/pxe.c | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/core/fs/pxe/pxe.c b/core/fs/pxe/pxe.c index f0f8b61..d689e61 100644 --- a/core/fs/pxe/pxe.c +++ b/core/fs/pxe/pxe.c @@ -1065,7 +1065,7 @@ static int pxe_open_config(struct com32_filedata *filedata) get_prefix(); if (DHCPMagic & 0x02) { /* We got a DHCP option, try it first */ - if (!open_file(ConfigName, filedata)) + if (open_file(ConfigName, filedata) >= 0) return 0; } @@ -1077,13 +1077,13 @@ static int pxe_open_config(struct com32_filedata *...
2014 Oct 15
1
syslinux efi configuration file name proposal
...> -Klaus A simpler patch for just the config filenames (whitespace changed for email): diff --git a/core/fs/lib/loadconfig.c b/core/fs/lib/loadconfig.c index 95e6f3f..47101f9 100644 --- a/core/fs/lib/loadconfig.c +++ b/core/fs/lib/loadconfig.c @@ -22,6 +22,11 @@ int generic_open_config(struct com32_filedata *filedata) }; static const char *filenames[] = { "extlinux.conf", +#if defined(__FIRMWARE_EFI64__) + "syslnx64.cfg", +#elif defined(__FIRMWARE_EFI32__) + "syslnx32.cfg", +#endif "syslinux.cfg", NULL }; --...
2015 Sep 20
1
[syslinux:master] core/fs/lib/loadconfig.c: Add architecture-specific config name to search
...b/loadconfig.c | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/core/fs/lib/loadconfig.c b/core/fs/lib/loadconfig.c > index 95e6f3f..d164ae1 100644 > --- a/core/fs/lib/loadconfig.c > +++ b/core/fs/lib/loadconfig.c > @@ -22,6 +22,11 @@ int generic_open_config(struct com32_filedata *filedata) > }; > static const char *filenames[] = { > "extlinux.conf", > +#if defined(__FIRMWARE_EFI64__) > + "syslx64.cfg", > +#elif defined(__FIRMWARE_EFI32__) > + "syslia32.cfg", > +#endif > "sys...
2010 Jun 24
0
[PATCH] COM32: Fix read() with directories
...et errno = EISDIR. A file descriptor for a directory may be open()ed but must be used with fdopendir() and readdir() to read anything beyond what stat()/fstat() returns. Signed-off-by: Gene Cumm <gene.cumm at gmail.com> Depends on previous patch from last night for the change to the struct com32_filedata. --- diff --git a/com32/lib/sys/read.c b/com32/lib/sys/read.c index e097ade..5e45697 100644 --- a/com32/lib/sys/read.c +++ b/com32/lib/sys/read.c @@ -36,6 +36,7 @@ #include <com32.h> #include <minmax.h> #include <klibc/compiler.h> +#include <dirent.h> #include "fi...
2013 Oct 18
1
[RFC/PATCH 2/3] core: MultiFS infrastructure added.
..._info *this_fs = NULL; +/* export p_ops to be used outside the core */ +__export const struct fs_ops **p_ops = NULL; /* Actual file structures (we don't have malloc yet...) */ __export struct file files[MAX_OPEN]; @@ -344,6 +349,9 @@ __export int open_file(const char *name, int flags, struct com32_filedata *filed dprintf("open_file %s\n", name); + if (switch_fs(&name)) + return -1; + mangle_name(mangled_name, name); rv = searchdir(mangled_name, flags); @@ -361,6 +369,9 @@ __export int open_file(const char *name, int flags, struct com32_filedata *filed filedata-...
2014 Feb 24
3
[RFC, PATCH] core/pxe: Add architecture-specific discovery request for PXE config file
...S,%.o, $(wildcard $(SRC)/thread/*.S))) +CFLAGS += -D__EFI__ endif COBJS = $(filter-out $(FILTER_OBJS),$(COBJ)) diff --git a/core/fs/pxe/pxe.c b/core/fs/pxe/pxe.c index 4de4dbf..5cc9082 100644 --- a/core/fs/pxe/pxe.c +++ b/core/fs/pxe/pxe.c @@ -471,6 +471,11 @@ static int pxe_open_config(struct com32_filedata *filedata) tries--; }; + /* Try by client architecture */ + sprintf(config_file, "arch-%04x", ntohs(DHCP_CLIENT_ARCH)); + if (open_file(ConfigName, O_RDONLY, filedata) >= 0) + return 0; + /* Final attempt: "default" string */ strcpy(c...
2012 Mar 23
19
[PATCH 00/19][elflink] Improve compatibility with 4.x
From: Matt Fleming <matt.fleming at intel.com> The following patch series is available at, git://git.zytor.com/users/mfleming/syslinux.git elflink All patches are against the 'elflink' branch. This series fixes a few serious bugs and some behavioural incompatibilities with the 4.x series. Matt Fleming (19): ldlinux: Initialise 'p' before using it. ldlinux: Parse
2014 Aug 27
0
syslinux efi configuration file name proposal
Hello Ady & list, On Wed, Aug 27, 2014 at 08:17:51AM +0300, Ady wrote: > > Hello Ady, > > > > On Fri, Aug 01, 2014 at 08:35:27PM +0300, Ady wrote: > > > Goal: To have one USB drive capable of booting UEFI IA32 and UEFI X64 > > > (with an optional Syslinux menu containing multiple entries). > > > > > > Problem (solved) #1: The default
2014 Aug 27
3
syslinux efi configuration file name proposal
> Hello Ady, > > On Fri, Aug 01, 2014 at 08:35:27PM +0300, Ady wrote: > > Goal: To have one USB drive capable of booting UEFI IA32 and UEFI X64 > > (with an optional Syslinux menu containing multiple entries). > > > > Problem (solved) #1: The default directory location for both > > syslinux.efi is the same. > > > > Solution #1: Rename each
2015 Jul 22
13
[PULL 0/8] MultiFS suppport for BIOS and EFI
So last week I was wondering if XFS was still working -- even with its last on-disk structure changes -- and it _suprisingly_ worked as expected. Right, now I can finally get rid of GRUB and use Syslinux to boot my Linux on EFI from a rootfs with xfs. Shit, I have two partitions (the first one being the required ESP) so there is no way to access the other partitions since because Syslinux does not
2011 May 25
1
[GIT PULL] elflink ldlinux
Hi, These patches contain support for some features that are already in Syslinux 4 but weren't working properly on the elflink branch. It's another step closer to feature parity with Syslinux 4. Having to jump through the comboot API for localboot support is less than ideal and I'll eventually fix that, probably when we move a big chunk of code from asm to C. Also, there's a
2013 Oct 18
0
[RFC/PATCH 1/3] Move partiter from com32/chain to com32/lib/syslinux
...gt;= cs*hs*ss) { - s = ss; - h = hs - 1; - c = cs - 1; - } else { - s = (lba % ss) + 1; - t = lba / ss; - h = t % hs; - c = t / hs; - } - - (*dst)[0] = h; - (*dst)[1] = s | ((c & 0x300) >> 2); - (*dst)[2] = c; -} - -uint32_t get_file_lba(const char *filename) -{ - struct com32_filedata fd; - uint32_t lba = 0; - int size = 65536; - char *buf; - - buf = lmalloc(size); - if (!buf) - return 0; - - /* Put the filename in the bounce buffer */ - strlcpy(buf, filename, size); - - if (open_file(buf, O_RDONLY, &fd) <= 0) { - goto fail; /* Filename not found...
2015 Jul 22
0
[PULL 1/8] Move partiter from com32/chain to com32/lib/syslinux
...gt;= cs*hs*ss) { - s = ss; - h = hs - 1; - c = cs - 1; - } else { - s = (lba % ss) + 1; - t = lba / ss; - h = t % hs; - c = t / hs; - } - - (*dst)[0] = h; - (*dst)[1] = s | ((c & 0x300) >> 2); - (*dst)[2] = c; -} - -uint32_t get_file_lba(const char *filename) -{ - struct com32_filedata fd; - uint32_t lba = 0; - int size = 65536; - char *buf; - - buf = lmalloc(size); - if (!buf) - return 0; - - /* Put the filename in the bounce buffer */ - strlcpy(buf, filename, size); - - if (open_file(buf, O_RDONLY, &fd) <= 0) { - goto fail; /* Filename not found...
2012 Aug 20
13
[PATCH 00/12] Multidisk support
Hello, the following patches should get multidisk access working. The syntax accepted is the following: (hdx,y)/path/to/file where x is the disk number and start at 0 and the y is the partition number starting at 1. So (hd0,1) is the first partition of the first disk. the other accepted syntax is using MBR's 32 bits disk signature so for example: (mbr:0x12345678,2)/foo/bar would address
2012 Apr 17
2
[GIT PULL] elflink warning fixes and auto extension support
...eanup_hardware(void); +extern void sirq_cleanup(void); +extern void adjust_screen(void); + #endif /* CORE_H */ diff --git a/core/include/fs.h b/core/include/fs.h index 93eb818..59ec503 100644 --- a/core/include/fs.h +++ b/core/include/fs.h @@ -193,6 +193,7 @@ int open_file(const char *name, struct com32_filedata *filedata); void pm_open_file(com32sys_t *); void close_file(uint16_t handle); void pm_close_file(com32sys_t *); +int open_config(void); /* chdir.c */ void pm_realpath(com32sys_t *regs); diff --git a/core/init.c b/core/init.c index c1ba298..19db1e2 100644 --- a/core/init.c +++ b/core/init.c...
2012 Jul 16
5
[PATCH 0/5] Deleting __intcall() from Syslinux
From: Matt Fleming <matt.fleming at intel.com> Since we can't use __intcall() for EFI, and since we can now have the ELF module code resolve all our symbols at runtime, we should delete as many references to __intcall() as possible and just access the symbols directly. The most interesting patch is the support for weak symbols. We need to be able to reference derivative-specific
2012 Aug 14
1
[GIT PULL] elflink fixes
...sk.h> +#include <syslinux/pmapi.h> #include "utility.h" static const char *bpbtypes[] = { @@ -93,14 +95,11 @@ void lba2chs(disk_chs *dst, const struct disk_info *di, uint64_t lba, uint32_t m uint32_t get_file_lba(const char *filename) { - com32sys_t inregs; + struct com32_filedata fd; uint32_t lba = 0; int size = 65536; char *buf; - /* Start with clean registers */ - memset(&inregs, 0, sizeof(com32sys_t)); - buf = lmalloc(size); if (!buf) return 0; @@ -108,32 +107,15 @@ uint32_t get_file_lba(const char *filename) /* Put the filenam...