Skip to content
Unverified Commit 86c60efd authored by Hannes Reinecke's avatar Hannes Reinecke Committed by Christian Brauner
Browse files

fs/mpage: avoid negative shift for large blocksize



For large blocksizes the number of block bits is larger than PAGE_SHIFT,
so calculate the sector number from the byte offset instead. This is
required to enable large folios with buffer-heads.

Reviewed-by: default avatar"Matthew Wilcox (Oracle)" <willy@infradead.org>
Signed-off-by: default avatarLuis Chamberlain <mcgrof@kernel.org>
Signed-off-by: default avatarHannes Reinecke <hare@kernel.org>
Link: https://lore.kernel.org/r/20250221223823.1680616-4-mcgrof@kernel.org


Reviewed-by: default avatarHannes Reinecke <hare@suse.de>
Signed-off-by: default avatarChristian Brauner <brauner@kernel.org>
parent b72e591f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment