xfs: remove the unused return value from xfs_log_unmount_write
Remove the ignored return value from xfs_log_unmount_write, and also remove a rather pointless assert on the return value from xfs_log_force. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
This commit is contained in:
parent
cb3d425fa5
commit
550319e9df
|
@ -953,8 +953,7 @@ out_err:
|
||||||
* currently architecture converted and "Unmount" is a bit foo.
|
* currently architecture converted and "Unmount" is a bit foo.
|
||||||
* As far as I know, there weren't any dependencies on the old behaviour.
|
* As far as I know, there weren't any dependencies on the old behaviour.
|
||||||
*/
|
*/
|
||||||
|
static void
|
||||||
static int
|
|
||||||
xfs_log_unmount_write(xfs_mount_t *mp)
|
xfs_log_unmount_write(xfs_mount_t *mp)
|
||||||
{
|
{
|
||||||
struct xlog *log = mp->m_log;
|
struct xlog *log = mp->m_log;
|
||||||
|
@ -962,7 +961,6 @@ xfs_log_unmount_write(xfs_mount_t *mp)
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
xlog_in_core_t *first_iclog;
|
xlog_in_core_t *first_iclog;
|
||||||
#endif
|
#endif
|
||||||
int error;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Don't write out unmount record on norecovery mounts or ro devices.
|
* Don't write out unmount record on norecovery mounts or ro devices.
|
||||||
|
@ -971,11 +969,10 @@ xfs_log_unmount_write(xfs_mount_t *mp)
|
||||||
if (mp->m_flags & XFS_MOUNT_NORECOVERY ||
|
if (mp->m_flags & XFS_MOUNT_NORECOVERY ||
|
||||||
xfs_readonly_buftarg(log->l_targ)) {
|
xfs_readonly_buftarg(log->l_targ)) {
|
||||||
ASSERT(mp->m_flags & XFS_MOUNT_RDONLY);
|
ASSERT(mp->m_flags & XFS_MOUNT_RDONLY);
|
||||||
return 0;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
error = xfs_log_force(mp, XFS_LOG_SYNC);
|
xfs_log_force(mp, XFS_LOG_SYNC);
|
||||||
ASSERT(error || !(XLOG_FORCED_SHUTDOWN(log)));
|
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
first_iclog = iclog = log->l_iclog;
|
first_iclog = iclog = log->l_iclog;
|
||||||
|
@ -1007,7 +1004,7 @@ xfs_log_unmount_write(xfs_mount_t *mp)
|
||||||
iclog = log->l_iclog;
|
iclog = log->l_iclog;
|
||||||
atomic_inc(&iclog->ic_refcnt);
|
atomic_inc(&iclog->ic_refcnt);
|
||||||
xlog_state_want_sync(log, iclog);
|
xlog_state_want_sync(log, iclog);
|
||||||
error = xlog_state_release_iclog(log, iclog);
|
xlog_state_release_iclog(log, iclog);
|
||||||
switch (iclog->ic_state) {
|
switch (iclog->ic_state) {
|
||||||
case XLOG_STATE_ACTIVE:
|
case XLOG_STATE_ACTIVE:
|
||||||
case XLOG_STATE_DIRTY:
|
case XLOG_STATE_DIRTY:
|
||||||
|
@ -1019,9 +1016,7 @@ xfs_log_unmount_write(xfs_mount_t *mp)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
return error;
|
|
||||||
} /* xfs_log_unmount_write */
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Empty the log for unmount/freeze.
|
* Empty the log for unmount/freeze.
|
||||||
|
|
Loading…
Reference in New Issue