Re: [PATCH] bcache: avoid redundant access RB tree in read_dirty

Pierre Juhen <[email protected]> Mon, 20 Oct 2025 18:44:51 +0200
Newsgroups org.kernel.vger.linux-bcache
Message-ID <[email protected]>
Hi

I am on kernel 6.16.12.

I have had errors with bcache recently, And I lost my fronted 3 or 4 times :

oct. 20 15:37:40 pierre.juhen kernel: bcache: journal_read_bucket() 128: 
bad csum, 32768 bytes, offset 0
oct. 20 15:37:40 pierre.juhen kernel: bcache: journal_read_bucket() 64: 
bad csum, 22928 bytes, offset 0
oct. 20 15:37:40 pierre.juhen kernel: bcache: journal_read_bucket() 32: 
bad csum, 4848 bytes, offset 2
oct. 20 15:37:40 pierre.juhen kernel: bcache: journal_read_bucket() 48: 
bad csum, 14096 bytes, offset 0
oct. 20 15:37:40 pierre.juhen (udev-worker)[461]: nvme0n1p3: Process 
'bcache-register /dev/nvme0n1p3' failed with exit code 1.
oct. 20 15:37:40 pierre.juhen kernel: bcache: prio_read() bad csum 
reading priorities
oct. 20 15:37:40 pierre.juhen kernel: bcache: bch_cache_set_error() 
error on 448f191c-28df-4396-bc44-14d1f77c9005: IO error reading 
priorities, disabling caching
oct. 20 15:37:40 pierre.juhen kernel: bcache: register_bcache() error : 
failed to register device

I had to reconfigure everything after a disk problem.

I have been running bcache for years now, without any problems.

The only difference might be that I configured the frontend with the 
discard option.

The logical volume using bcache have also a discard option in fstab.

The frontend is on a Samsung 980 nvme disk.

Any hint ?

Thank you

Regards