Skip to content

bdev: Avoid discarding buffers under a filesystem

Jan Kara linux-block linux-ext4 linux-fsdevel stable 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest2 patches 4 repliesIn review
  2. v1 RFC2 patches 13 repliesSuperseded

Changes in v2 from the cover letter

* Check for exclusive access to the bdev instead of for the presence of superblock

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2fs: Don't invalidate page buffers in block_write_full_page()fs/buffer.c+0 -161 reply
2/2block: Do not discard buffers under a mounted filesystemblock/ioctl.c fs/block_dev.c include/linux/blkdev.h+50 -101 reply

Reviews trailers per patch

All 2 patches have a Reviewed-by or Acked-by.

PatchChristoph Hellwig
1/2R-b
2/2R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH 0/2 v2] bdev: Avoid discarding buffers under a filesystem

Hello,

this patch set fixes problems when buffer heads are discarded under a live filesystem (which can lead to all sorts of issues like crashes in case of ext4). Patch 1 drops some stale buffer invalidation code, patch 2 temporarily gets exclusive access to the block device for the duration of buffer cache handling to avoid interfering with other exclusive bdev user. The patch fixes the problems for me and pass xfstests for ext4.

Changes since v1:
* Check for exclusive access to the bdev instead of for the presence of superblock

Honza