Commit 3cd1d18b authored by Christoph Hellwig's avatar Christoph Hellwig Committed by Darrick J. Wong

xfs: remove the m_readio_* fields in struct xfs_mount

m_readio_blocks is entirely unused, and m_readio_blocks is only used in
xfs_stat_blksize in a max statements that is a no-op as it always has
the same value as m_writeio_log.
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Reviewed-by: default avatarDarrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: default avatarDarrick J. Wong <darrick.wong@oracle.com>
parent b5ad616c
...@@ -514,7 +514,7 @@ xfs_stat_blksize( ...@@ -514,7 +514,7 @@ xfs_stat_blksize(
if (mp->m_swidth) if (mp->m_swidth)
return mp->m_swidth << mp->m_sb.sb_blocklog; return mp->m_swidth << mp->m_sb.sb_blocklog;
if (mp->m_flags & XFS_MOUNT_DFLT_IOSIZE) if (mp->m_flags & XFS_MOUNT_DFLT_IOSIZE)
return 1U << max(mp->m_readio_log, mp->m_writeio_log); return 1U << mp->m_writeio_log;
} }
return PAGE_SIZE; return PAGE_SIZE;
......
...@@ -437,25 +437,15 @@ xfs_set_rw_sizes(xfs_mount_t *mp) ...@@ -437,25 +437,15 @@ xfs_set_rw_sizes(xfs_mount_t *mp)
xfs_sb_t *sbp = &(mp->m_sb); xfs_sb_t *sbp = &(mp->m_sb);
int readio_log, writeio_log; int readio_log, writeio_log;
if (!(mp->m_flags & XFS_MOUNT_DFLT_IOSIZE)) { if (!(mp->m_flags & XFS_MOUNT_DFLT_IOSIZE))
readio_log = XFS_READIO_LOG_LARGE;
writeio_log = XFS_WRITEIO_LOG_LARGE; writeio_log = XFS_WRITEIO_LOG_LARGE;
} else { else
readio_log = mp->m_readio_log;
writeio_log = mp->m_writeio_log; writeio_log = mp->m_writeio_log;
}
if (sbp->sb_blocklog > readio_log) { if (sbp->sb_blocklog > writeio_log)
mp->m_readio_log = sbp->sb_blocklog;
} else {
mp->m_readio_log = readio_log;
}
mp->m_readio_blocks = 1 << (mp->m_readio_log - sbp->sb_blocklog);
if (sbp->sb_blocklog > writeio_log) {
mp->m_writeio_log = sbp->sb_blocklog; mp->m_writeio_log = sbp->sb_blocklog;
} else { } else
mp->m_writeio_log = writeio_log; mp->m_writeio_log = writeio_log;
}
mp->m_writeio_blocks = 1 << (mp->m_writeio_log - sbp->sb_blocklog); mp->m_writeio_blocks = 1 << (mp->m_writeio_log - sbp->sb_blocklog);
} }
......
...@@ -98,8 +98,6 @@ typedef struct xfs_mount { ...@@ -98,8 +98,6 @@ typedef struct xfs_mount {
xfs_agnumber_t m_agirotor; /* last ag dir inode alloced */ xfs_agnumber_t m_agirotor; /* last ag dir inode alloced */
spinlock_t m_agirotor_lock;/* .. and lock protecting it */ spinlock_t m_agirotor_lock;/* .. and lock protecting it */
xfs_agnumber_t m_maxagi; /* highest inode alloc group */ xfs_agnumber_t m_maxagi; /* highest inode alloc group */
uint m_readio_log; /* min read size log bytes */
uint m_readio_blocks; /* min read size blocks */
uint m_writeio_log; /* min write size log bytes */ uint m_writeio_log; /* min write size log bytes */
uint m_writeio_blocks; /* min write size blocks */ uint m_writeio_blocks; /* min write size blocks */
struct xfs_da_geometry *m_dir_geo; /* directory block geometry */ struct xfs_da_geometry *m_dir_geo; /* directory block geometry */
...@@ -248,9 +246,8 @@ typedef struct xfs_mount { ...@@ -248,9 +246,8 @@ typedef struct xfs_mount {
/* /*
* Default minimum read and write sizes. * Default write size.
*/ */
#define XFS_READIO_LOG_LARGE 16
#define XFS_WRITEIO_LOG_LARGE 16 #define XFS_WRITEIO_LOG_LARGE 16
/* /*
......
...@@ -405,7 +405,6 @@ xfs_parseargs( ...@@ -405,7 +405,6 @@ xfs_parseargs(
} }
mp->m_flags |= XFS_MOUNT_DFLT_IOSIZE; mp->m_flags |= XFS_MOUNT_DFLT_IOSIZE;
mp->m_readio_log = iosizelog;
mp->m_writeio_log = iosizelog; mp->m_writeio_log = iosizelog;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment