aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Chinner <david@fromorbit.com>2015-02-09 17:24:25 -0500
committerDave Chinner <david@fromorbit.com>2015-02-09 17:24:25 -0500
commitbad962662dbc60e76ec1baae34af56b1ba2dfa5f (patch)
treebf6d56e8658ab5eceb6edec34d4f205f4217d23b
parent179073620d8090e9c52bf203e2033fc9cfe088b3 (diff)
parente9892d3cc853afdda2cc69e2576d9ddb5fafad71 (diff)
Merge branch 'xfs-misc-fixes-for-3.20-4' into for-next
-rw-r--r--Documentation/filesystems/xfs.txt5
-rw-r--r--fs/xfs/xfs_fsops.c1
-rw-r--r--fs/xfs/xfs_ioctl.c4
-rw-r--r--fs/xfs/xfs_super.c5
-rw-r--r--fs/xfs/xfs_trans_buf.c5
5 files changed, 14 insertions, 6 deletions
diff --git a/Documentation/filesystems/xfs.txt b/Documentation/filesystems/xfs.txt
index 7077103ac541..0bfafe108357 100644
--- a/Documentation/filesystems/xfs.txt
+++ b/Documentation/filesystems/xfs.txt
@@ -287,9 +287,9 @@ The following sysctls are available for the XFS filesystem:
287 XFS_ERRLEVEL_LOW: 1 287 XFS_ERRLEVEL_LOW: 1
288 XFS_ERRLEVEL_HIGH: 5 288 XFS_ERRLEVEL_HIGH: 5
289 289
290 fs.xfs.panic_mask (Min: 0 Default: 0 Max: 127) 290 fs.xfs.panic_mask (Min: 0 Default: 0 Max: 255)
291 Causes certain error conditions to call BUG(). Value is a bitmask; 291 Causes certain error conditions to call BUG(). Value is a bitmask;
292 AND together the tags which represent errors which should cause panics: 292 OR together the tags which represent errors which should cause panics:
293 293
294 XFS_NO_PTAG 0 294 XFS_NO_PTAG 0
295 XFS_PTAG_IFLUSH 0x00000001 295 XFS_PTAG_IFLUSH 0x00000001
@@ -299,6 +299,7 @@ The following sysctls are available for the XFS filesystem:
299 XFS_PTAG_SHUTDOWN_CORRUPT 0x00000010 299 XFS_PTAG_SHUTDOWN_CORRUPT 0x00000010
300 XFS_PTAG_SHUTDOWN_IOERROR 0x00000020 300 XFS_PTAG_SHUTDOWN_IOERROR 0x00000020
301 XFS_PTAG_SHUTDOWN_LOGERROR 0x00000040 301 XFS_PTAG_SHUTDOWN_LOGERROR 0x00000040
302 XFS_PTAG_FSBLOCK_ZERO 0x00000080
302 303
303 This option is intended for debugging only. 304 This option is intended for debugging only.
304 305
diff --git a/fs/xfs/xfs_fsops.c b/fs/xfs/xfs_fsops.c
index f7114527cd2f..fba6532efba4 100644
--- a/fs/xfs/xfs_fsops.c
+++ b/fs/xfs/xfs_fsops.c
@@ -488,6 +488,7 @@ xfs_growfs_data_private(
488 xfs_trans_mod_sb(tp, XFS_TRANS_SB_FDBLOCKS, nfree); 488 xfs_trans_mod_sb(tp, XFS_TRANS_SB_FDBLOCKS, nfree);
489 if (dpct) 489 if (dpct)
490 xfs_trans_mod_sb(tp, XFS_TRANS_SB_IMAXPCT, dpct); 490 xfs_trans_mod_sb(tp, XFS_TRANS_SB_IMAXPCT, dpct);
491 xfs_trans_set_sync(tp);
491 error = xfs_trans_commit(tp, 0); 492 error = xfs_trans_commit(tp, 0);
492 if (error) 493 if (error)
493 return error; 494 return error;
diff --git a/fs/xfs/xfs_ioctl.c b/fs/xfs/xfs_ioctl.c
index b88ab927debe..f7afb86c9148 100644
--- a/fs/xfs/xfs_ioctl.c
+++ b/fs/xfs/xfs_ioctl.c
@@ -1086,7 +1086,7 @@ out_cancel:
1086 * to half the AG size to avoid alignment extending the extent beyond the 1086 * to half the AG size to avoid alignment extending the extent beyond the
1087 * limits of the AG. 1087 * limits of the AG.
1088 */ 1088 */
1089int 1089static int
1090xfs_ioctl_setattr_check_extsize( 1090xfs_ioctl_setattr_check_extsize(
1091 struct xfs_inode *ip, 1091 struct xfs_inode *ip,
1092 struct fsxattr *fa) 1092 struct fsxattr *fa)
@@ -1129,7 +1129,7 @@ xfs_ioctl_setattr_check_extsize(
1129 return 0; 1129 return 0;
1130} 1130}
1131 1131
1132int 1132static int
1133xfs_ioctl_setattr_check_projid( 1133xfs_ioctl_setattr_check_projid(
1134 struct xfs_inode *ip, 1134 struct xfs_inode *ip,
1135 struct fsxattr *fa) 1135 struct fsxattr *fa)
diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c
index 5ce76d01885d..f2449fd86926 100644
--- a/fs/xfs/xfs_super.c
+++ b/fs/xfs/xfs_super.c
@@ -1111,6 +1111,11 @@ xfs_fs_statfs(
1111 statp->f_files, 1111 statp->f_files,
1112 mp->m_maxicount); 1112 mp->m_maxicount);
1113 1113
1114 /* If sb_icount overshot maxicount, report actual allocation */
1115 statp->f_files = max_t(typeof(statp->f_files),
1116 statp->f_files,
1117 sbp->sb_icount);
1118
1114 /* make sure statp->f_ffree does not underflow */ 1119 /* make sure statp->f_ffree does not underflow */
1115 ffree = statp->f_files - (sbp->sb_icount - sbp->sb_ifree); 1120 ffree = statp->f_files - (sbp->sb_icount - sbp->sb_ifree);
1116 statp->f_ffree = max_t(__int64_t, ffree, 0); 1121 statp->f_ffree = max_t(__int64_t, ffree, 0);
diff --git a/fs/xfs/xfs_trans_buf.c b/fs/xfs/xfs_trans_buf.c
index 0a4d4ab6d9a9..75798412859a 100644
--- a/fs/xfs/xfs_trans_buf.c
+++ b/fs/xfs/xfs_trans_buf.c
@@ -327,9 +327,10 @@ xfs_trans_read_buf_map(
327 return -EIO; 327 return -EIO;
328 } 328 }
329 329
330 if (tp) 330 if (tp) {
331 _xfs_trans_bjoin(tp, bp, 1); 331 _xfs_trans_bjoin(tp, bp, 1);
332 trace_xfs_trans_read_buf(bp->b_fspriv); 332 trace_xfs_trans_read_buf(bp->b_fspriv);
333 }
333 *bpp = bp; 334 *bpp = bp;
334 return 0; 335 return 0;
335 336