From: Zygo Blaxell Date: Mon, 20 Sep 2021 16:26:38 +0000 (-0400) Subject: Revert "btrfs: don't report readahead errors and don't update statistics" because... X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6f3b097ed8d761db6b51db496c8e1d972a6be9e7;p=linux Revert "btrfs: don't report readahead errors and don't update statistics" because we want to know about errors This reverts commit 0cc068e6ee59c1fffbfa977d8bf868b7551d80ac. (cherry picked from commit edca545b3e61a4b4f88d6676317c0d5bd30e785f) --- diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index b98a8498882f..cc5f83f02667 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -7094,9 +7094,9 @@ static void btrfs_end_bio(struct bio *bio) if (btrfs_op(bio) == BTRFS_MAP_WRITE) btrfs_dev_stat_inc_and_print(dev, BTRFS_DEV_STAT_WRITE_ERRS); - else if (!(bio->bi_opf & REQ_RAHEAD)) + else btrfs_dev_stat_inc_and_print(dev, - BTRFS_DEV_STAT_READ_ERRS); + BTRFS_DEV_STAT_READ_ERRS); if (bio->bi_opf & REQ_PREFLUSH) btrfs_dev_stat_inc_and_print(dev, BTRFS_DEV_STAT_FLUSH_ERRS);