Re: [GRUB PATCH] xfs: accept filesystem with sparse inodes

2018-05-16 Thread Daniel Kiper
On Tue, May 15, 2018 at 02:55:55PM -0500, Eric Sandeen wrote: > The sparse inode metadata format became a mkfs.xfs default in > xfsprogs-4.16.0, and such filesystems are now rejected by grub as > containing an incompatible feature. > > In essence, this feature allows xfs to allocate inodes into fra

Re: FTDI serial console support?

2018-05-16 Thread Daniel Kiper
On Wed, May 16, 2018 at 06:21:17AM +0200, Petter Gustad wrote: > From: Daniel Kiper > Subject: Re: FTDI serial console support? > Date: Tue, 15 May 2018 22:00:06 +0200 > > > On Fri, May 11, 2018 at 03:55:36PM +0200, Petter Gustad wrote: > >> > >> Is there a way to specify a FTDI based serial conso

Re: [PATCH] mbi: use per segment a separate relocator chunk

2018-05-16 Thread Daniel Kiper
On Tue, May 15, 2018 at 09:18:18PM +0200, Alexander Boettcher wrote: > On 15.05.2018 21:10, Alexander Boettcher wrote: > >>I assume that a given ELF PHDR address/size does not cover VGA memory or > >>anything like that, > > > >No. > > > >>so, I am not sure what exactly overwrites this region. > >>g

[PATCH 6/9] btrfs: refactor the code that read from disk

2018-05-16 Thread Goffredo Baroncelli
This is a preparatory patch, to help the adding of the RAID 5/6 recovery code. In case of availability of all disks, this code is good for all the RAID profiles. However in case of failure, the error handling is quite different. Refactoring this code increases the general readability. Signed-off-b

[PATCH 3/9] btrfs: move the error logging from find_device() to its callee.

2018-05-16 Thread Goffredo Baroncelli
This is a preparatory patch. The callee knows better if this error is fatal or not, i.e. another available disk. Signed-off-by: Goffredo Baroncelli --- grub-core/fs/btrfs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/grub-core/fs/btrfs.c b/grub-core/fs/btrfs.c inde

[PATCH 4/9] btrfs: avoiding a rescan for a device which was already not founded.

2018-05-16 Thread Goffredo Baroncelli
If a device is not found, record this failure storing NULL in data->devices_attached[]. This avoid un-necessary devices rescan, speeding the reading in case of a degraded array. Signed-off-by: Goffredo Baroncelli --- grub-core/fs/btrfs.c | 19 +-- 1 file changed, 9 insertions(+),

[PATCH 1/9] btrfs: add support for reading a filesystem with a RAID 5 or RAID 6 profile.

2018-05-16 Thread Goffredo Baroncelli
Signed-off-by: Goffredo Baroncelli --- grub-core/fs/btrfs.c | 68 1 file changed, 68 insertions(+) diff --git a/grub-core/fs/btrfs.c b/grub-core/fs/btrfs.c index be195448d..394611cbb 100644 --- a/grub-core/fs/btrfs.c +++ b/grub-core/fs/btrfs.c @@ -119

[PATCH 7/9] btrfs: add support for recovery for a RAID 5 btrfs profiles.

2018-05-16 Thread Goffredo Baroncelli
Signed-off-by: Goffredo Baroncelli --- grub-core/fs/btrfs.c | 174 ++- 1 file changed, 170 insertions(+), 4 deletions(-) diff --git a/grub-core/fs/btrfs.c b/grub-core/fs/btrfs.c index 63651928b..5fcaad86f 100644 --- a/grub-core/fs/btrfs.c +++ b/grub-core/f

[PATCH 9/9] btrfs: add RAID 6 recovery for a btrfs filesystem.

2018-05-16 Thread Goffredo Baroncelli
Add the RAID 6 recovery, in order to use a RAID 6 filesystem even if some disks (up to two) are missing. This code use the old md RAID 6 code already present in grub. Signed-off-by: Goffredo Baroncelli --- grub-core/fs/btrfs.c | 45 +++- 1 file changed, 40

[PATCH V4] Add support for BTRFS raid5/6 to GRUB

2018-05-16 Thread Goffredo Baroncelli
Hi All, the aim of this patches set is to provide support for a BTRFS raid5/6 filesystem in GRUB. The first patch, implements the basic support for raid5/6. I.e this works when all the disks are present. The next 5 patches, are preparatory ones. The 7th patch implements the raid5 recovery for

[PATCH 8/9] btrfs: make more generic the code for RAID 6 rebuilding

2018-05-16 Thread Goffredo Baroncelli
The original code which handles the recovery of a RAID 6 disks array assumes that all reads are multiple of 1 << GRUB_DISK_SECTOR_BITS and it assumes that all the I/O is done via the struct grub_diskfilter_segment. This is not true for the btrfs code. In order to reuse the native grub_raid6_recover

Re: [PATCH 6/8] Add support for recovery for a raid5 btrfs profiles.

2018-05-16 Thread Goffredo Baroncelli
On 05/14/2018 08:40 PM, Daniel Kiper wrote: > On Fri, May 11, 2018 at 09:24:44PM +0200, Goffredo Baroncelli wrote: >> Signed-off-by: Goffredo Baroncelli >> --- >> grub-core/fs/btrfs.c | 178 +-- >> 1 file changed, 173 insertions(+), 5 deletions(-) >> >> dif

[PATCH 2/9] btrfs: add helper to check the btrfs header.

2018-05-16 Thread Goffredo Baroncelli
This helper will be used in few places to help the debugging. As conservative approach, in case of error it is only logged. This because I am not sure if this can change something in the error handling of the currently existing code. Signed-off-by: Goffredo Baroncelli --- grub-core/fs/btrfs.c |

[PATCH 5/9] btrfs: move logging code in grub_btrfs_read_logical()

2018-05-16 Thread Goffredo Baroncelli
A portion of the logging code is moved outside a for(;;). The part that is left inside is the one which depends by the for(;;) index. This is a preparatory patch: in the next one it will be possible to refactor the code inside the for(;;) in an another function. --- grub-core/fs/btrfs.c | 25 +

Re: [PATCH 8/8] Add raid6 recovery for a btrfs filesystem.

2018-05-16 Thread Goffredo Baroncelli
On 05/14/2018 09:06 PM, Daniel Kiper wrote: > On Fri, May 11, 2018 at 09:24:46PM +0200, Goffredo Baroncelli wrote: >> Add the raid6 recovery, in order to use a raid6 filesystem even if some >> disks (up to two) are missing. >> This code use the old md raid6 code already present in grub. > > Please

Re: [PATCH 1/8] Add support for reading a filesystem with a raid5 or raid6 profile.

2018-05-16 Thread Goffredo Baroncelli
On 05/14/2018 07:52 PM, Daniel Kiper wrote: > On Fri, May 11, 2018 at 09:24:39PM +0200, Goffredo Baroncelli wrote: >> Signed-off-by: Goffredo Baroncelli >> --- >> grub-core/fs/btrfs.c | 61 >> 1 file changed, 61 insertions(+) >> >> diff --git a/grub-co