Skip to content

xfs: fixes for malformed on-disk i_mode

Amir Goldstein linux-xfs 5 versions – Applied

Status from this message: Applied, soaking into for-next now.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v8 Latest6 patches 7 repliesApplied
  2. v76 patches 5 repliesSuperseded
  3. v63 patches 6 repliesSuperseded
Earlier versions · 2
VersionPostedPatchesRepliesStatus
v51 patch1 replySuperseded
v41 patch3 repliesSuperseded

Changes in v8 from the cover letter

- Address review comments by Darrick
- Added Reviewed-by Darrick to patches 4,6

Patches in v8 Applied

#Subject and filesSizeRepliesApplied
1/6xfs: make the ASSERT() condition likelyfs/xfs/xfs_linux.h+3 -32 replies
2/6xfs: sanity check directory inode di_sizefs/xfs/libxfs/xfs_dir2.c fs/xfs/libxfs/xfs_inode_buf.c+7 -31 reply
3/6xfs: add missing include dependencies to xfs_dir2.hfs/xfs/libxfs/xfs_dir2.h+3 -01 reply
4/6xfs: replace xfs_mode_to_ftype table with switch statementfs/xfs/libxfs/xfs_dir2.c fs/xfs/libxfs/xfs_dir2.h fs/xfs/xfs_iops.c+25 -181 reply
5/6xfs: sanity check inode mode when creating new dentryfs/xfs/xfs_iops.c+39 -91 reply
6/6xfs: sanity check inode di_modefs/xfs/libxfs/xfs_inode_buf.c+3 -01 reply

Reviews trailers per patch

All 6 patches have a Reviewed-by or Acked-by.

PatchChristoph HellwigDarrick J. Wong
1/6R-b
2/6R-b
3/6R-b
4/6R-b R-b
5/6R-b
6/6R-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v8 thread

Cover letter [PATCH v8 0/6] xfs: fixes for malformed on-disk i_mode

Darrick,

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

Patches 1-2 are reviewed by Christoph and IMO, you should consider patch 1 and perhaprs also patch 2 for 4.10 and stable 4.9.

Patches 4-6 replace xfs_mode_to_ftype table with switch statement per Christoph's suggestion and add sanity checks.

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

Amir.

v8:
- Address review comments by Darrick
- Added Reviewed-by Darrick to patches 4,6

v7:
- Replaced xfs_mode_to_ftype table with switch statement
- Reordered patches so reviewed trivial patches are first
- Added Reviewed-by Christoph to first 2 patches
- Added cleanup patch for xfs_dir2.h
- Added sanity checks for invalid mode in more places

v6:
- Added Reviewed-by Brian for patch 1
- Added patch to address new xfs/348 failures
- Added patch 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

*** BLURB HERE ***

Amir Goldstein (6):
xfs: make the ASSERT() condition likely
xfs: sanity check directory inode di_size
xfs: add missing include dependencies to xfs_dir2.h
xfs: replace xfs_mode_to_ftype table with switch statement
xfs: sanity check inode mode when creating new dentry
xfs: sanity check inode di_mode

 fs/xfs/libxfs/xfs_dir2.c      | 39 ++++++++++++++++++++-------------
 fs/xfs/libxfs/xfs_dir2.h      |  8 ++++---
 fs/xfs/libxfs/xfs_inode_buf.c | 10 +++++++--
 fs/xfs/xfs_iops.c             | 50 ++++++++++++++++++++++++++++++++++---------
 fs/xfs/xfs_linux.h            |  6 +++---
 5 files changed, 80 insertions(+), 33 deletions(-)
Signature · 1 line
2.7.4