diff options
| author | Ingo Molnar <mingo@kernel.org> | 2018-10-23 06:30:19 -0400 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2018-10-23 06:30:19 -0400 |
| commit | dda93b45389f025fd3422d22cc31cc1ea6040305 (patch) | |
| tree | 44a856744843e24ed1baf6ca4edb1be04809a606 /fs/xfs/xfs_iops.c | |
| parent | 2e62024c265aa69315ed02835623740030435380 (diff) | |
| parent | b61b8bba18fe2b63d38fdaf9b83de25e2d787dfe (diff) | |
Merge branch 'x86/cache' into perf/core, to pick up fixes
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'fs/xfs/xfs_iops.c')
| -rw-r--r-- | fs/xfs/xfs_iops.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/fs/xfs/xfs_iops.c b/fs/xfs/xfs_iops.c index c3e74f9128e8..f48ffd7a8d3e 100644 --- a/fs/xfs/xfs_iops.c +++ b/fs/xfs/xfs_iops.c | |||
| @@ -471,8 +471,18 @@ xfs_vn_get_link_inline( | |||
| 471 | struct inode *inode, | 471 | struct inode *inode, |
| 472 | struct delayed_call *done) | 472 | struct delayed_call *done) |
| 473 | { | 473 | { |
| 474 | char *link; | ||
| 475 | |||
| 474 | ASSERT(XFS_I(inode)->i_df.if_flags & XFS_IFINLINE); | 476 | ASSERT(XFS_I(inode)->i_df.if_flags & XFS_IFINLINE); |
| 475 | return XFS_I(inode)->i_df.if_u1.if_data; | 477 | |
| 478 | /* | ||
| 479 | * The VFS crashes on a NULL pointer, so return -EFSCORRUPTED if | ||
| 480 | * if_data is junk. | ||
| 481 | */ | ||
| 482 | link = XFS_I(inode)->i_df.if_u1.if_data; | ||
| 483 | if (!link) | ||
| 484 | return ERR_PTR(-EFSCORRUPTED); | ||
| 485 | return link; | ||
| 476 | } | 486 | } |
| 477 | 487 | ||
| 478 | STATIC int | 488 | STATIC int |
