/* All xfs metadata buffers except log state machine buffers get this attached as their b_bdstrat callback function. This is so that we can catch a buffer after prematurely unpinning it to forcibly shutdown the filesystem.  */
int xfs_bdstrat_cb(struct xfs_buf *bp)
/* All xfs metadata buffers except log state machine buffers get this attached as their b_bdstrat callback function. This is so that we can catch a buffer after prematurely unpinning it to forcibly shutdown the filesystem.  */
int xfs_bdstrat_cb(struct xfs_buf *bp)
{
	if (XFS_FORCED_SHUTDOWN(bp->b_mount)) {
		trace_xfs_bdstrat_shut(bp, _RET_IP_);
		if (XFS_BUF_IODONE_FUNC(bp) == NULL &&
		    (XFS_BUF_ISREAD(bp)) == 0)
			return (xfs_bioerror_relse(bp));
		else
			return (xfs_bioerror(bp));
	}
	xfs_buf_iorequest(bp);
	return 0;
}