diff options
| author | Johannes Thumshirn <[email protected]> | 2023-05-31 11:50:37 +0000 |
|---|---|---|
| committer | Jens Axboe <[email protected]> | 2023-06-01 15:13:31 +0000 |
| commit | f83123223a8447a1369409568f698c68a230010e (patch) | |
| tree | ac436760fabafc956267d45bcf8302fe71b01601 /fs/btrfs/dev-replace.c | |
| parent | md: check for failure when adding pages in alloc_behind_master_bio (diff) | |
| download | kernel-f83123223a8447a1369409568f698c68a230010e.tar.gz kernel-f83123223a8447a1369409568f698c68a230010e.zip | |
md: raid1: use __bio_add_page for adding single page to bio
The sync request code uses bio_add_page() to add a page to a newly created bio.
bio_add_page() can fail, but the return value is never checked.
Use __bio_add_page() as adding a single page to a newly created bio is
guaranteed to succeed.
This brings us a step closer to marking bio_add_page() as __must_check.
Reviewed-by: Christoph Hellwig <[email protected]>
Reviewed-by: Damien Le Moal <[email protected]>
Acked-by: Song Liu <[email protected]>
Signed-off-by: Johannes Thumshirn <[email protected]>
Link: https://lore.kernel.org/r/6cf7f66c6e646231200d025dfd5f2d3ae75c8fe5.1685532726.git.johannes.thumshirn@wdc.com
Signed-off-by: Jens Axboe <[email protected]>
Diffstat (limited to 'fs/btrfs/dev-replace.c')
0 files changed, 0 insertions, 0 deletions
