[Devel] [PATCH RH8 17/18] ploop: Make fsync work be able to run in parallel with main work

Kirill Tkhai ktkhai at virtuozzo.com
Wed Jun 16 18:47:46 MSK 2021


This should improve performace. Also, this is required
for next patch.

Signed-off-by: Kirill Tkhai <ktkhai at virtuozzo.com>
---
 drivers/md/dm-ploop-target.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/md/dm-ploop-target.c b/drivers/md/dm-ploop-target.c
index aa6b576b93b1..9e173f5d8d0c 100644
--- a/drivers/md/dm-ploop-target.c
+++ b/drivers/md/dm-ploop-target.c
@@ -279,6 +279,7 @@ static int ploop_ctr(struct dm_target *ti, unsigned int argc, char **argv)
 {
 	percpu_ref_func_t *release;
 	struct ploop *ploop;
+	unsigned int flags;
 	int i, ret;
 
 	if (argc < 2)
@@ -325,7 +326,8 @@ static int ploop_ctr(struct dm_target *ti, unsigned int argc, char **argv)
 		}
 	}
 
-	ploop->wq = alloc_ordered_workqueue("dm-" DM_MSG_PREFIX, WQ_MEM_RECLAIM);
+	flags = WQ_MEM_RECLAIM|WQ_HIGHPRI|WQ_UNBOUND;
+	ploop->wq = alloc_workqueue("dm-" DM_MSG_PREFIX, flags, 0);
 	if (!ploop->wq) {
 		ret = -ENOMEM;
 		goto err;




More information about the Devel mailing list