diff options
author | Dave Chinner <david@fromorbit.com> | 2014-12-03 17:46:17 -0500 |
---|---|---|
committer | Dave Chinner <david@fromorbit.com> | 2014-12-03 17:46:17 -0500 |
commit | 6044e4386cd51dece882ea42352cdaaab0f24cad (patch) | |
tree | cde51132ea9d6afefdf05ad621fc22bbb796d5f4 /fs/xfs/xfs_buf.c | |
parent | c14fc01340dd0afe58d8671acc3ea5e907e707ae (diff) | |
parent | b29c70f59870dad0945b0e0b3fe3758ad528e268 (diff) |
Merge branch 'xfs-misc-fixes-for-3.19-2' into for-next
Conflicts:
fs/xfs/xfs_iops.c
Diffstat (limited to 'fs/xfs/xfs_buf.c')
-rw-r--r-- | fs/xfs/xfs_buf.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/fs/xfs/xfs_buf.c b/fs/xfs/xfs_buf.c index a4ce39025dcc..bb502a391792 100644 --- a/fs/xfs/xfs_buf.c +++ b/fs/xfs/xfs_buf.c | |||
@@ -1041,7 +1041,7 @@ xfs_buf_ioend_work( | |||
1041 | struct work_struct *work) | 1041 | struct work_struct *work) |
1042 | { | 1042 | { |
1043 | struct xfs_buf *bp = | 1043 | struct xfs_buf *bp = |
1044 | container_of(work, xfs_buf_t, b_iodone_work); | 1044 | container_of(work, xfs_buf_t, b_ioend_work); |
1045 | 1045 | ||
1046 | xfs_buf_ioend(bp); | 1046 | xfs_buf_ioend(bp); |
1047 | } | 1047 | } |
@@ -1050,8 +1050,8 @@ void | |||
1050 | xfs_buf_ioend_async( | 1050 | xfs_buf_ioend_async( |
1051 | struct xfs_buf *bp) | 1051 | struct xfs_buf *bp) |
1052 | { | 1052 | { |
1053 | INIT_WORK(&bp->b_iodone_work, xfs_buf_ioend_work); | 1053 | INIT_WORK(&bp->b_ioend_work, xfs_buf_ioend_work); |
1054 | queue_work(bp->b_target->bt_mount->m_buf_workqueue, &bp->b_iodone_work); | 1054 | queue_work(bp->b_ioend_wq, &bp->b_ioend_work); |
1055 | } | 1055 | } |
1056 | 1056 | ||
1057 | void | 1057 | void |
@@ -1220,6 +1220,13 @@ _xfs_buf_ioapply( | |||
1220 | */ | 1220 | */ |
1221 | bp->b_error = 0; | 1221 | bp->b_error = 0; |
1222 | 1222 | ||
1223 | /* | ||
1224 | * Initialize the I/O completion workqueue if we haven't yet or the | ||
1225 | * submitter has not opted to specify a custom one. | ||
1226 | */ | ||
1227 | if (!bp->b_ioend_wq) | ||
1228 | bp->b_ioend_wq = bp->b_target->bt_mount->m_buf_workqueue; | ||
1229 | |||
1223 | if (bp->b_flags & XBF_WRITE) { | 1230 | if (bp->b_flags & XBF_WRITE) { |
1224 | if (bp->b_flags & XBF_SYNCIO) | 1231 | if (bp->b_flags & XBF_SYNCIO) |
1225 | rw = WRITE_SYNC; | 1232 | rw = WRITE_SYNC; |