mbox series

[v2,0/3] btrfs: zoned: fix writes on a compressed zoned filesystem

Message ID cover.1621351444.git.johannes.thumshirn@wdc.com (mailing list archive)
Headers show
Series btrfs: zoned: fix writes on a compressed zoned filesystem | expand

Message

Johannes Thumshirn May 18, 2021, 3:40 p.m. UTC
David reported that I/O errors get thrown on a zoned filesystem with
compression enabled.

This happens because we're using regular writes instead of zoned append, but
with regular writes and increased parallelism, we cannot guarantee the data
placement requirements can be met.

This series switches the compressed I/O submission path to zone append writing
on a zoned filesystem.

Changes in v2:
- Factor out zoned device lookup
- limit scope of bdev variable

Johannes Thumshirn (3):
  btrfs: zoned: pass start block to btrfs_use_zone_append
  btrfs: zoned: fix compressed writes
  btrfs: zoned: factor out zoned device lookup

 fs/btrfs/compression.c | 35 +++++++++++++++++++++++++++++++----
 fs/btrfs/extent_io.c   | 18 ++++++------------
 fs/btrfs/inode.c       |  2 +-
 fs/btrfs/zoned.c       | 25 +++++++++++++++++++++++--
 fs/btrfs/zoned.h       | 14 +++++++++++---
 5 files changed, 72 insertions(+), 22 deletions(-)

Comments

David Sterba May 20, 2021, 3:05 p.m. UTC | #1
On Wed, May 19, 2021 at 12:40:26AM +0900, Johannes Thumshirn wrote:
> David reported that I/O errors get thrown on a zoned filesystem with
> compression enabled.
> 
> This happens because we're using regular writes instead of zoned append, but
> with regular writes and increased parallelism, we cannot guarantee the data
> placement requirements can be met.
> 
> This series switches the compressed I/O submission path to zone append writing
> on a zoned filesystem.
> 
> Changes in v2:
> - Factor out zoned device lookup
> - limit scope of bdev variable
> 
> Johannes Thumshirn (3):
>   btrfs: zoned: pass start block to btrfs_use_zone_append
>   btrfs: zoned: fix compressed writes
>   btrfs: zoned: factor out zoned device lookup

The test now does not report any problems. Moved to misc-next, thanks.