[Devel] [PATCH RHEL8 COMMIT] ploop: Convert ploop_init_end_io()

Konstantin Khorenko khorenko at virtuozzo.com
Mon May 17 19:04:51 MSK 2021


The commit is pushed to "branch-rh8-4.18.0-240.1.1.vz8.5.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh8-4.18.0-240.1.1.vz8.5.30
------>
commit 6de9c5934fcc1b6fb473c2549437e8e3a4846154
Author: Kirill Tkhai <ktkhai at virtuozzo.com>
Date:   Mon May 17 19:04:51 2021 +0300

    ploop: Convert ploop_init_end_io()
    
    Signed-off-by: Kirill Tkhai <ktkhai at virtuozzo.com>
    
    =====================
    Patchset description:
    
    dm-ploop: Kill loop
    
    Intermediate patches can't be base for bisect.
    
    In scope of https://jira.sw.ru/browse/PSBM-123654
    
    Signed-off-by: Kirill Tkhai <ktkhai at virtuozzo.com>
---
 drivers/md/dm-ploop-map.c | 13 +++----------
 1 file changed, 3 insertions(+), 10 deletions(-)

diff --git a/drivers/md/dm-ploop-map.c b/drivers/md/dm-ploop-map.c
index a61de5f934c0..b62eb055160d 100644
--- a/drivers/md/dm-ploop-map.c
+++ b/drivers/md/dm-ploop-map.c
@@ -82,7 +82,7 @@ static void ploop_index_wb_init(struct ploop_index_wb *piwb, struct ploop *ploop
 	piwb->type = PIWB_TYPE_ALLOC;
 }
 
-static void __ploop_init_end_io(struct ploop *ploop, struct pio *pio)
+static void ploop_init_end_io(struct ploop *ploop, struct pio *pio)
 {
 	pio->action = PLOOP_END_IO_NONE;
 	pio->ref_index = PLOOP_REF_INDEX_INVALID;
@@ -95,13 +95,6 @@ static void __ploop_init_end_io(struct ploop *ploop, struct pio *pio)
 	RB_CLEAR_NODE(&pio->node);
 }
 
-static void ploop_init_end_io(struct ploop *ploop, struct bio *bio)
-{
-	struct pio *pio = bio_to_endio_hook(bio);
-
-	__ploop_init_end_io(ploop, pio);
-}
-
 /* Get cluster related to pio sectors */
 static int ploop_pio_cluster(struct ploop *ploop, struct pio *pio,
 			     unsigned int *ret_cluster)
@@ -1077,7 +1070,7 @@ int submit_cluster_cow(struct ploop *ploop, unsigned int level,
 	bio->bi_end_io = ploop_cow_endio;
 	bio->bi_private = cow;
 
-	__ploop_init_end_io(ploop, &cow->hook);
+	ploop_init_end_io(ploop, &cow->hook);
 	add_cluster_lk(ploop, &cow->hook, cluster);
 
 	/* Stage #0: read secondary delta full cluster */
@@ -1636,7 +1629,7 @@ int ploop_map(struct dm_target *ti, struct bio *bio)
 	unsigned int cluster;
 	unsigned long flags;
 
-	ploop_init_end_io(ploop, bio);
+	ploop_init_end_io(ploop, pio);
 
 	remap_to_origin(ploop, bio);
 


More information about the Devel mailing list