diff options
Diffstat (limited to 'fs/xfs/xfs_buf.c')
-rw-r--r-- | fs/xfs/xfs_buf.c | 26 |
1 files changed, 8 insertions, 18 deletions
diff --git a/fs/xfs/xfs_buf.c b/fs/xfs/xfs_buf.c index afe7645e4b2b..9fccfb594291 100644 --- a/fs/xfs/xfs_buf.c +++ b/fs/xfs/xfs_buf.c | |||
@@ -1593,12 +1593,11 @@ xfs_free_buftarg( | |||
1593 | kmem_free(btp); | 1593 | kmem_free(btp); |
1594 | } | 1594 | } |
1595 | 1595 | ||
1596 | STATIC int | 1596 | int |
1597 | xfs_setsize_buftarg_flags( | 1597 | xfs_setsize_buftarg( |
1598 | xfs_buftarg_t *btp, | 1598 | xfs_buftarg_t *btp, |
1599 | unsigned int blocksize, | 1599 | unsigned int blocksize, |
1600 | unsigned int sectorsize, | 1600 | unsigned int sectorsize) |
1601 | int verbose) | ||
1602 | { | 1601 | { |
1603 | btp->bt_bsize = blocksize; | 1602 | btp->bt_bsize = blocksize; |
1604 | btp->bt_sshift = ffs(sectorsize) - 1; | 1603 | btp->bt_sshift = ffs(sectorsize) - 1; |
@@ -1619,26 +1618,17 @@ xfs_setsize_buftarg_flags( | |||
1619 | } | 1618 | } |
1620 | 1619 | ||
1621 | /* | 1620 | /* |
1622 | * When allocating the initial buffer target we have not yet | 1621 | * When allocating the initial buffer target we have not yet |
1623 | * read in the superblock, so don't know what sized sectors | 1622 | * read in the superblock, so don't know what sized sectors |
1624 | * are being used at this early stage. Play safe. | 1623 | * are being used at this early stage. Play safe. |
1625 | */ | 1624 | */ |
1626 | STATIC int | 1625 | STATIC int |
1627 | xfs_setsize_buftarg_early( | 1626 | xfs_setsize_buftarg_early( |
1628 | xfs_buftarg_t *btp, | 1627 | xfs_buftarg_t *btp, |
1629 | struct block_device *bdev) | 1628 | struct block_device *bdev) |
1630 | { | 1629 | { |
1631 | return xfs_setsize_buftarg_flags(btp, | 1630 | return xfs_setsize_buftarg(btp, PAGE_SIZE, |
1632 | PAGE_SIZE, bdev_logical_block_size(bdev), 0); | 1631 | bdev_logical_block_size(bdev)); |
1633 | } | ||
1634 | |||
1635 | int | ||
1636 | xfs_setsize_buftarg( | ||
1637 | xfs_buftarg_t *btp, | ||
1638 | unsigned int blocksize, | ||
1639 | unsigned int sectorsize) | ||
1640 | { | ||
1641 | return xfs_setsize_buftarg_flags(btp, blocksize, sectorsize, 1); | ||
1642 | } | 1632 | } |
1643 | 1633 | ||
1644 | xfs_buftarg_t * | 1634 | xfs_buftarg_t * |