Commit 0bf91a7
loop: Simplify discard granularity calc
[ Upstream commit d47de6a ]
A bdev discard granularity is always at least SECTOR_SIZE, so don't check
for a zero value.
Suggested-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: John Garry <john.g.garry@oracle.com>
Link: https://lore.kernel.org/r/20241101092215.422428-1-john.g.garry@oracle.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Stable-dep-of: f5c84ef ("loop: Add sanity check for read/write_iter")
Signed-off-by: Sasha Levin <sashal@kernel.org>
(cherry picked from commit 722f6dece719e5a18ec949f4774eda302ec6d68c)
Signed-off-by: Jack Vogel <jack.vogel@oracle.com>1 parent 0e5abd0 commit 0bf91a7
1 file changed
+1
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
713 | 713 | | |
714 | 714 | | |
715 | 715 | | |
716 | | - | |
717 | | - | |
| 716 | + | |
718 | 717 | | |
719 | 718 | | |
720 | 719 | | |
| |||
0 commit comments