Re: [dm-devel] [PATCH 02/19] drbd: use __bio_add_page to add page to bio

2023-03-29 Thread Damien Le Moal
On 3/30/23 02:05, Johannes Thumshirn wrote: > The drbd code only adds a single page to a newly created bio. So use > __bio_add_page() to add the page which is guaranteed to succeed in this > case. > > This brings us closer to marking bio_add_page() as __must_check. > > Signed-off-by: Johannes

Re: [dm-devel] [PATCH 02/19] drbd: use __bio_add_page to add page to bio

2023-03-29 Thread Matthew Wilcox
On Wed, Mar 29, 2023 at 10:05:48AM -0700, Johannes Thumshirn wrote: > +++ b/drivers/block/drbd/drbd_bitmap.c > @@ -1043,9 +1043,11 @@ static void bm_page_io_async(struct drbd_bm_aio_ctx > *ctx, int page_nr) __must_ho > bio = bio_alloc_bioset(device->ldev->md_bdev, 1, op, GFP_NOIO, >

[dm-devel] [PATCH 02/19] drbd: use __bio_add_page to add page to bio

2023-03-29 Thread Johannes Thumshirn
The drbd code only adds a single page to a newly created bio. So use __bio_add_page() to add the page which is guaranteed to succeed in this case. This brings us closer to marking bio_add_page() as __must_check. Signed-off-by: Johannes Thumshirn --- drivers/block/drbd/drbd_bitmap.c | 8