[PATCH v6 0/3] xfs: fixes for malformed on-disk i_mode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Darrick,

This is 6th revision of the fixes for malformed on-disk i_mode.

I implemented the xfs specific test case (xfs/348) to test all
possible malformed file type values as you suggested.

Tested with generic/401 with -n ftype=0|1.
Tested with new xfs/348 test with -n ftype=0|1.

Test xfs/348 exposed an ASSERT on attempt to readdir of regular
file that is posing as a directory.

Patch 2 implements your suggestion to address this case.

Patch 3 fixes a very strage upsidedown unlikely() in the
xfs ASSERT macros. I hope I am not tripping...

Amir.

v6:
- Added Reviewed-by Brian for patch 1
- Added patch 2 to address new xfs/348 failures
- Added patch 3 to fix ASSERT() likely

v5:
- remove wrong argument about on-disk malformed mode from commit message
- address Brian's review comments

v4:
- independent fix patch for xfs

Amir Goldstein (3):
  xfs: fix the size of xfs_mode_to_ftype table
  xfs: sanity check directory inode di_size
  xfs: make the ASSERT() condition likely

 fs/xfs/libxfs/xfs_dir2.c      | 21 +++++++++++----------
 fs/xfs/libxfs/xfs_dir2.h      |  4 +++-
 fs/xfs/libxfs/xfs_inode_buf.c |  7 +++++--
 fs/xfs/xfs_iops.c             |  2 +-
 fs/xfs/xfs_linux.h            |  6 +++---
 5 files changed, 23 insertions(+), 17 deletions(-)

-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux