Re: [RFC PATCH] dm: Avoid sending redundant empty flush bios to the same block device

2024-04-24 Thread YangYang
On 2024/4/22 18:05, Yang Yang wrote: __send_empty_flush() sends empty flush bios to every target in the dm_table. However, if the num_targets exceeds the number of block devices in the dm_table's device list, it could lead to multiple invocations of __send_duplicate_bios() for the same block

Re: [PATCH 2/3] libmultipath: change flush_on_last_del to fix a multipathd hang

2024-04-24 Thread Benjamin Marzinski
On Wed, Apr 24, 2024 at 04:42:04PM -0400, Benjamin Marzinski wrote: > On Wed, Apr 24, 2024 at 06:34:35PM +0200, Martin Wilck wrote: > > On Tue, 2024-04-23 at 18:25 -0400, Benjamin Marzinski wrote: > > > + > > > + /* It's not safe to do a non-deferred remove of a map that > > > has > > > + *

Re: [PATCH 3/3] libmultipath: simplify dm_flush_map_nopaths

2024-04-24 Thread Benjamin Marzinski
On Wed, Apr 24, 2024 at 06:40:36PM +0200, Martin Wilck wrote: > On Tue, 2024-04-23 at 18:25 -0400, Benjamin Marzinski wrote: > > Now that flush_map_nopaths(), its only caller, needs to deal with > > whether or not a remove is deferred, dm_flush_map_nopaths() > > doesn't need to worry if

Re: [PATCH 2/3] libmultipath: change flush_on_last_del to fix a multipathd hang

2024-04-24 Thread Benjamin Marzinski
On Wed, Apr 24, 2024 at 06:34:35PM +0200, Martin Wilck wrote: > On Tue, 2024-04-23 at 18:25 -0400, Benjamin Marzinski wrote: > > Commit 9bd3482e ("multipathd: make flush_map() delete maps like the > > multipath command") Fixed an issue where deleting a queueing > > multipath > > device through

Re: [PATCH 1/3] libmultipath: export partmap_in_use and do_deferred

2024-04-24 Thread Martin Wilck
On Tue, 2024-04-23 at 18:25 -0400, Benjamin Marzinski wrote: > A future commit will make use of these functions > > Signed-off-by: Benjamin Marzinski Reviewed-by: Martin Wilck > --- >  libmultipath/devmapper.c  | 4 +--- >  libmultipath/devmapper.h  | 3 +++ >  

Re: [PATCH 3/3] libmultipath: simplify dm_flush_map_nopaths

2024-04-24 Thread Martin Wilck
On Tue, 2024-04-23 at 18:25 -0400, Benjamin Marzinski wrote: > Now that flush_map_nopaths(), its only caller, needs to deal with > whether or not a remove is deferred, dm_flush_map_nopaths() > doesn't need to worry if LIBDM_API_DEFERRED is defined. It can just > trust that the caller took care of

Re: [PATCH 2/3] libmultipath: change flush_on_last_del to fix a multipathd hang

2024-04-24 Thread Martin Wilck
On Tue, 2024-04-23 at 18:25 -0400, Benjamin Marzinski wrote: > Commit 9bd3482e ("multipathd: make flush_map() delete maps like the > multipath command") Fixed an issue where deleting a queueing > multipath > device through multipathd could hang because the multipath device had > outstanding IO,

Re: [PATCH] block: allow device to have both virt_boundary_mask and max segment size

2024-04-24 Thread Geert Uytterhoeven
Hi Ming, On Wed, Apr 24, 2024 at 2:41 PM Ming Lei wrote: > On Wed, Apr 24, 2024 at 12:26:26PM +0200, Geert Uytterhoeven wrote: > > On Sun, 7 Apr 2024, Ming Lei wrote: > > > When one stacking device is over one device with virt_boundary_mask and > > > another one with max segment size, the

Re: [PATCH] block: allow device to have both virt_boundary_mask and max segment size

2024-04-24 Thread Ming Lei
On Wed, Apr 24, 2024 at 12:26:26PM +0200, Geert Uytterhoeven wrote: > Hi Ming, > > On Sun, 7 Apr 2024, Ming Lei wrote: > > When one stacking device is over one device with virt_boundary_mask and > > another one with max segment size, the stacking device have both limits > > set. This way is

Re: [PATCH] block: allow device to have both virt_boundary_mask and max segment size

2024-04-24 Thread Geert Uytterhoeven
Hi Ming, On Sun, 7 Apr 2024, Ming Lei wrote: When one stacking device is over one device with virt_boundary_mask and another one with max segment size, the stacking device have both limits set. This way is allowed before d690cb8ae14b ("block: add an API to atomically update queue