[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aRxpq2RH3v4Dz33q@milan>
Date: Tue, 18 Nov 2025 13:42:19 +0100
From: Uladzislau Rezki <urezki@...il.com>
To: Mikulas Patocka <mpatocka@...hat.com>
Cc: Benjamin Marzinski <bmarzins@...hat.com>,
"Uladzislau Rezki (Sony)" <urezki@...il.com>,
Alasdair Kergon <agk@...hat.com>, DMML <dm-devel@...ts.linux.dev>,
Andrew Morton <akpm@...ux-foundation.org>,
Mike Snitzer <snitzer@...hat.com>, Christoph Hellwig <hch@....de>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] dm-bufio: align write boundary on bdev_logical_block_size
On Tue, Nov 18, 2025 at 12:15:43PM +0100, Mikulas Patocka wrote:
>
>
> On Mon, 17 Nov 2025, Benjamin Marzinski wrote:
>
> > On Mon, Oct 20, 2025 at 02:48:13PM +0200, Mikulas Patocka wrote:
> > >
> > >
> > > On Mon, 20 Oct 2025, Uladzislau Rezki (Sony) wrote:
> > >
> > > > When performing a read-modify-write(RMW) operation, any modification
> > > > to a buffered block must cause the entire buffer to be marked dirty.
> > > >
> > > > Marking only a subrange as dirty is incorrect because the underlying
> > > > device block size(ubs) defines the minimum read/write granularity. A
> > > > lower device can perform I/O only on regions which are fully aligned
> > > > and sized to ubs.
> > >
> > > Hi
> > >
> > > I think it would be better to fix this in dm-bufio, so that other dm-bufio
> > > users would also benefit from the fix.
> >
> > This looks to me like it should accomplish the same thing as
> > Uladzislau's patch. But I think there could still be problems with other
> > dm-bufio users, for devices where the blocksize is larger than 4k.
>
> Yes, but Uladzislau said that this patch doesn't work for him. So, I
> suspect that he has "logical_block_size" set incorrectly.
>
Indeed. Because logical is < physical in my case. Your change does not fix
it because of I/O size is equal to physical.
--
Uladzislau Rezki
Powered by blists - more mailing lists