From: Christoph Hellwig Date: Sat, 19 Nov 2011 18:13:37 +0000 (-0500) Subject: xfs: fix error handling for synchronous writes X-Git-Tag: firefly_0821_release~7541^2~2230 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=e62cccfcf5535487daf8c1d3613b9dabc2315b44;p=firefly-linux-kernel-4.4.55.git xfs: fix error handling for synchronous writes If removed storage while synchronous buffer write underway, "xfslogd" hangs. Detailed log http://oss.sgi.com/archives/xfs/2011-07/msg00740.html Related work bfc60177f8ab509bc225becbb58f7e53a0e33e81 "xfs: fix error handling for synchronous writes" Given that xfs_bwrite actually does the shutdown already after waiting for the b_iodone completion and given that we actually found that calling xfs_force_shutdown from inside xfs_buf_iodone_callbacks was a major contributor the problem it better to drop this call. Signed-off-by: Ajeet Yadav Reviewed-by: Christoph Hellwig Signed-off-by: Alex Elder Signed-off-by: Greg Kroah-Hartman --- diff --git a/fs/xfs/xfs_buf_item.c b/fs/xfs/xfs_buf_item.c index a7342e840d77..7888a7563078 100644 --- a/fs/xfs/xfs_buf_item.c +++ b/fs/xfs/xfs_buf_item.c @@ -1023,7 +1023,6 @@ xfs_buf_iodone_callbacks( XFS_BUF_UNDELAYWRITE(bp); trace_xfs_buf_error_relse(bp, _RET_IP_); - xfs_force_shutdown(mp, SHUTDOWN_META_IO_ERROR); do_callbacks: xfs_buf_do_callbacks(bp);