mbox series

[0/3] iomap: 1 cleanup, 1 fix, 1 optimization

Message ID 1544739929-21651-1-git-send-email-sandeen@sandeen.net (mailing list archive)
Headers show
Series iomap: 1 cleanup, 1 fix, 1 optimization | expand

Message

Eric Sandeen Dec. 13, 2018, 10:25 p.m. UTC
Patch 1 is trivial, to use the SECTOR_SIZE macro instead of open-coding.
Patch 2 is the one that matters: iomap_is_partially_uptodate was doing invalid memory accesses past the end of the iomap_page->uptodate bitmap.
Patch3 is a small optimization (?) based on what the non-iomap code does, i.e. don't bother checking each block if the "partial" range covers the whole page

These survived an xfstests -g auto run on 4k and 1k block size filesystems
on x86_64.  Careful review for off by ones is appreciated in any case. ;)

Thanks,
-Eric

Comments

Eric Sandeen Dec. 13, 2018, 10:27 p.m. UTC | #1
On 12/13/18 4:25 PM, Eric Sandeen wrote:
> Patch 1 is trivial, to use the SECTOR_SIZE macro instead of open-coding.
> Patch 2 is the one that matters: iomap_is_partially_uptodate was doing invalid memory accesses past the end of the iomap_page->uptodate bitmap.
> Patch3 is a small optimization (?) based on what the non-iomap code does, i.e. don't bother checking each block if the "partial" range covers the whole page
> 
> These survived an xfstests -g auto run on 4k and 1k block size filesystems
> on x86_64.  Careful review for off by ones is appreciated in any case. ;)

Ugh, I fatfingered a cc (or maybe I'll blame guilt) - careful on reply-all,
sorry about that.

-Eric