Any objection that I commit his patch? -------- Weitergeleitete Nachricht -------- Von: Michel Dänzer <daen...@debian.org> An: Felix Zielcke <fziel...@z-51.de> Kopie: 520...@bugs.debian.org Betreff: Re: Bug#520286: ext2 module fails to recognize ext4 files with extents on big endian Datum: Wed, 18 Mar 2009 18:41:47 +0100
On Mit, 2009-03-18 at 18:26 +0100, Felix Zielcke wrote: > Am Mittwoch, den 18.03.2009, 18:00 +0100 schrieb Michel Dänzer: > > > The function grub_ext2_read_block() doesn't take endianness into account > > when checking the inode flags for EXT4_EXTENTS_FLAG, so the check doesn't > > work properly on big endian. The attached patch fixes this, it was necessary > > for loading and booting a Linux kernel from an ext4 filesystem on my > > PowerBook. > > Hi, > > it would be nice if you could write a ChangeLog entry for this and send > your patch directly upstream to grub-devel@gnu.org, though you need to > subscribe first. Last time I tried this wasn't too pleasant an experience for me I'm afraid (as a result I filed #516458, which was fixed with a different patch, for which I thanked the author personally). The attached includes a ChangeLog entry, but I'd appreciate if you or someone else could take care of getting it integrated upstream. Thanks, -- Felix Zielcke
--- grub2-1.96+20090317.orig/fs/ext2.c 2009-02-08 01:28:09.000000000 +0100 +++ grub2-1.96+20090317/fs/ext2.c 2009-03-18 17:29:03.000000000 +0100 @@ -385,7 +385,7 @@ grub_ext2_read_block (grub_fshelp_node_t unsigned int blksz = EXT2_BLOCK_SIZE (data); int log2_blksz = LOG2_EXT2_BLOCK_SIZE (data); - if (inode->flags & EXT4_EXTENTS_FLAG) + if (grub_le_to_cpu32(inode->flags) & EXT4_EXTENTS_FLAG) { char buf[EXT2_BLOCK_SIZE(data)]; struct grub_ext4_extent_header *leaf; --- grub2-1.96+20090317.orig/ChangeLog 2009-03-14 16:18:59.000000000 +0100 +++ grub2-1.96+20090317/ChangeLog 2009-03-18 18:39:26.000000000 +0100 @@ -0,0 +1,5 @@ +2009-03-18 Michel Dänzer <mic...@daenzer.net> + + * fs/ext2.c (grub_ext2_read_block): Take endianness into account when + checking inode flags for EXT4_EXTENTS_FLAG. +
_______________________________________________ Grub-devel mailing list Grub-devel@gnu.org http://lists.gnu.org/mailman/listinfo/grub-devel