search for: ext_write_adv

Displaying 14 results from an estimated 14 matches for "ext_write_adv".

2015 Nov 13
4
[PATCH] extlinux: code cleanup and simplification
Merge btrfs_read_adv and xfs_read_adv into a single generic function ext_read_adv and split ext_write_adv_offset out of ext_write_adv. Use those new functions in rewrite_boot_image and btrfs_install_file where it is actually hardcoded. Signed-off-by: Nicolas Cornu <nicolac76 at yahoo.fr> --- extlinux/main.c | 113 +++++++++++++++++++++++++++----------------------------- 1 file changed, 55 inse...
2015 Nov 12
1
[PATCH] Unification of ext_(write/read)_adv
...vfd); + return ext_read_adv_offset(devfd, boot_image_len); } else { err = read_adv(path, name = "ldlinux.sys"); if (err == 2) /* ldlinux.sys does not exist */ @@ -1455,17 +1446,26 @@ static int ext_read_adv(const char *path, int devfd, const char **namep) } } +static int ext_write_adv_offset(int devfd, off_t offset) +{ + const size_t adv_size = 2 * ADV_SIZE; + + if (xpwrite(devfd, syslinux_adv, adv_size, offset) != adv_size) { + perror("writing adv"); + return 1; + } + + return 0; +} + static int ext_write_adv(const char *path, const char *cfg, int devfd)...
2015 Nov 18
0
[PATCH] extlinux: code cleanup and simplification
2015-11-13 20:35 UTC+01:00, Nicolas Cornu via Syslinux <syslinux at zytor.com>: > Merge btrfs_read_adv and xfs_read_adv into a single generic function > ext_read_adv and split ext_write_adv_offset out of ext_write_adv. > > Use those new functions in rewrite_boot_image and btrfs_install_file > where it is actually hardcoded. > > Signed-off-by: Nicolas Cornu <nicolac76 at yahoo.fr> > --- > extlinux/main.c | 113 > +++++++++++++++++++++++++++----------------...
2015 Nov 26
0
[syslinux:master] extlinux: code cleanup and simplification
...ux at zytor.com> AuthorDate: Fri, 13 Nov 2015 20:35:29 +0100 Committer: Paulo Alcantara <pcacjr at zytor.com> CommitDate: Wed, 25 Nov 2015 21:58:23 -0200 extlinux: code cleanup and simplification Merge btrfs_read_adv and xfs_read_adv into a single generic function ext_read_adv and split ext_write_adv_offset out of ext_write_adv. Use those new functions in rewrite_boot_image and btrfs_install_file where it is actually hardcoded. Signed-off-by: Nicolas Cornu <nicolac76 at yahoo.fr> Signed-off-by: Paulo Alcantara <pcacjr at zytor.com> --- extlinux/main.c | 113 +++++++++++++++++++++...
2015 Nov 18
1
[PATCH] extlinux: code cleanup and simplification
...rry for that ;) Le Mercredi 18 novembre 2015 7h31, Celelibi <celelibi at gmail.com> a ?crit : 2015-11-13 20:35 UTC+01:00, Nicolas Cornu via Syslinux <syslinux at zytor.com>: > Merge btrfs_read_adv and xfs_read_adv into a single generic function > ext_read_adv and split ext_write_adv_offset out of ext_write_adv. > > Use those new functions in rewrite_boot_image and btrfs_install_file > where it is actually hardcoded. > > Signed-off-by: Nicolas Cornu <nicolac76 at yahoo.fr> > --- >? extlinux/main.c | 113 > +++++++++++++++++++++++++++----------------...
2015 Nov 26
1
[PATCH] extlinux: code cleanup and simplification
> On Fri, 13 Nov 2015 20:35:29 +0100 > Nicolas Cornu via Syslinux <syslinux at zytor.com> wrote: > > > Merge btrfs_read_adv and xfs_read_adv into a single generic function > > ext_read_adv and split ext_write_adv_offset out of ext_write_adv. > > > > Use those new functions in rewrite_boot_image and btrfs_install_file > > where it is actually hardcoded. > > > > Signed-off-by: Nicolas Cornu <nicolac76 at yahoo.fr> > > --- > > extlinux/main.c | 113 > > +...
2015 Nov 26
0
[PATCH] extlinux: code cleanup and simplification
On Fri, 13 Nov 2015 20:35:29 +0100 Nicolas Cornu via Syslinux <syslinux at zytor.com> wrote: > Merge btrfs_read_adv and xfs_read_adv into a single generic function > ext_read_adv and split ext_write_adv_offset out of ext_write_adv. > > Use those new functions in rewrite_boot_image and btrfs_install_file > where it is actually hardcoded. > > Signed-off-by: Nicolas Cornu <nicolac76 at yahoo.fr> > --- > extlinux/main.c | 113 > +++++++++++++++++++++++++++--------------...
2013 May 30
0
Possible bug in ext_read_adv
...if (xpread(devfd, syslinux_adv, adv_size, boot_image_len) != adv_size) return -1; return syslinux_validate_adv(syslinux_adv) ? 1 : 0; } boot_image_len for me is about 53 kb so it read after 53 kb after start of partition however comment on ext_read_adv state that 2kb is used. Also in ext_write_adv adv is written with a write_adv which use a file inside the filesystem so the first function looks wrong to me. Well, we are not corrupting XFS cause is a read and never a write but surely adv won't work for xfs code. I did not test it so I could be possible wrong. Frediano
2012 Oct 15
3
Syslinux-4.06-pre14
Another week, *another* -pre. I'm really planning on this being the last one. The shortlog is appended below. Apart from a better fix for the "disabled menu entry" bug it's only documentation updates. Testing from the last -pre's has been pretty quiet, so as soon as Ady and Matt have tested this one and confirmed that the disabled entry bug is finally gone I'll do the
2014 Dec 24
0
[PATCH 1/8] extlinux/main.c: support unmounted ext2/3/4 filesystem
...92,12 @@ static int install_file(const char *path, int devfd, struct stat *rst) return 1; } + +static int install_file_to_device(const char *device_path, int devfd, + int update_only) +{ +} + #ifdef __KLIBC__ static char devname_buf[64]; @@ -1452,15 +1459,26 @@ static int ext_write_adv(const char *path, const char *cfg, int devfd) return write_adv(path, cfg); } -static int install_loader(const char *path, int update_only) +static int install_loader(const char *path, int update_only, struct stat st) { - struct stat st, fst; + struct stat fst; int devfd, rv;...
2013 Jul 22
1
[PATCH 1/1 v2] Add UFS1/2 support to Extlinux installer.
...t;ldlinux.sys" is in 64k blank area */ return btrfs_read_adv(devfd); } else if (fs_type == XFS) { /* XFS "ldlinux.sys" is in the first 2048 bytes of the primary AG */ @@ -1400,7 +1440,8 @@ static int ext_read_adv(const char *path, int devfd, const char **namep) static int ext_write_adv(const char *path, const char *cfg, int devfd) { - if (fs_type == BTRFS) { /* btrfs "ldlinux.sys" is in 64k blank area */ + /* btrfs/ufs2 "ldlinux.sys" is in 64k blank area */ + if (fs_type == BTRFS || fs_type == UFS2) { if (xpwrite(devfd, syslinux_adv, 2 * ADV_SIZE,...
2013 Jul 12
2
[PATCH 001/001] Add UFS1/2 support to Extlinux installer.
...t;ldlinux.sys" is in 64k blank area */ return btrfs_read_adv(devfd); } else if (fs_type == XFS) { /* XFS "ldlinux.sys" is in the first 2048 bytes of the primary AG */ @@ -1400,7 +1436,8 @@ static int ext_read_adv(const char *path, int devfd, const char **namep) static int ext_write_adv(const char *path, const char *cfg, int devfd) { - if (fs_type == BTRFS) { /* btrfs "ldlinux.sys" is in 64k blank area */ + /* btrfs/ufs2 "ldlinux.sys" is in 64k blank area */ + if (fs_type == BTRFS || fs_type == UFS2) { if (xpwrite(devfd, syslinux_adv, 2 * ADV_SIZE,...
2012 Sep 10
19
Initial support for sector size >512
This set of patches add some support for sector size >512. Currently it fixes extlinux, MBR for GPT and ext partitions. Other code is unaffected. This set of patches has been tested on a read Dell machine running a beta firmware.
2014 Dec 24
14
[PATCH 0/8] extlinux: support unmounted ext2/3/4 filesystem
Hello syslinux, Merry Christmas! These patches will make extlinux work with umounted ext2/3/4 filesystem, for example: $ extlinux -i /dev/sdXN or $ extlinux -i file_block Also it can work with something like: $ extlinux /dev/sdXN --reset-adv or $ extlinux file_block --reset-adv We don't use a new option (I planed to use "-d" but it is already in use), it will check whether the