mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-06 19:07:52 +00:00
[XFS] Fix v2 log bufsize reporting in /proc/mounts.
SGI-PV: 946760 SGI-Modid: xfs-linux-melb:xfs-kern:24765a Signed-off-by: Nathan Scott <nathans@sgi.com>
This commit is contained in:
parent
42fe2b1f7f
commit
c2cd255060
1 changed files with 3 additions and 2 deletions
|
@ -333,10 +333,11 @@ xfs_finish_flags(
|
||||||
|
|
||||||
/* Fail a mount where the logbuf is smaller then the log stripe */
|
/* Fail a mount where the logbuf is smaller then the log stripe */
|
||||||
if (XFS_SB_VERSION_HASLOGV2(&mp->m_sb)) {
|
if (XFS_SB_VERSION_HASLOGV2(&mp->m_sb)) {
|
||||||
if ((ap->logbufsize == -1) &&
|
if ((ap->logbufsize <= 0) &&
|
||||||
(mp->m_sb.sb_logsunit > XLOG_BIG_RECORD_BSIZE)) {
|
(mp->m_sb.sb_logsunit > XLOG_BIG_RECORD_BSIZE)) {
|
||||||
mp->m_logbsize = mp->m_sb.sb_logsunit;
|
mp->m_logbsize = mp->m_sb.sb_logsunit;
|
||||||
} else if (ap->logbufsize < mp->m_sb.sb_logsunit) {
|
} else if (ap->logbufsize > 0 &&
|
||||||
|
ap->logbufsize < mp->m_sb.sb_logsunit) {
|
||||||
cmn_err(CE_WARN,
|
cmn_err(CE_WARN,
|
||||||
"XFS: logbuf size must be greater than or equal to log stripe size");
|
"XFS: logbuf size must be greater than or equal to log stripe size");
|
||||||
return XFS_ERROR(EINVAL);
|
return XFS_ERROR(EINVAL);
|
||||||
|
|
Loading…
Reference in a new issue