Whamcloud - gitweb
libext2fs: fix problems with LE<->BE conversions on BE platforms
authorDarrick J. Wong <darrick.wong@oracle.com>
Mon, 25 Aug 2014 02:01:36 +0000 (22:01 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Mon, 25 Aug 2014 02:01:36 +0000 (22:01 -0400)
commit2432a41a58c03be4afdfb12f40e7b7cfe3255145
treed26d38470268fa60e1023f623eb5d337daf46896
parent18b234b121be5c0bbe6865048acaadcac208b7fd
libext2fs: fix problems with LE<->BE conversions on BE platforms

Fix more problems that I found when testing on ppc64:

- Inode swap cut and paste error leads to immutable inodes being
  detected as inlinedata inodes, leading to e2fsck incorrectly barfing
  on i_block[] contents.

- Superblock csum/verify must be aware of the fs->super byte order
  when checking for metadata_csum feature flag.  (Hint: in _openfs(),
  fs->super is in LE order for the first csum verification)

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
lib/ext2fs/csum.c
lib/ext2fs/swapfs.c