[Devel] [PATCH RH9] dm-qcow2: Rename and unexport timer function

Kirill Tkhai ktkhai at virtuozzo.com
Wed Mar 9 12:31:59 MSK 2022


Here is ploop prefix, which is wrong. Also, this name
conflicts with dm-ploop driver, when both are built-in.

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

diff --git a/drivers/md/dm-qcow2-target.c b/drivers/md/dm-qcow2-target.c
index b0421988ddc8..0322ac294b17 100644
--- a/drivers/md/dm-qcow2-target.c
+++ b/drivers/md/dm-qcow2-target.c
@@ -424,7 +424,7 @@ static void inflight_ref_exit1(struct percpu_ref *ref)
 	complete(&tgt->inflight_ref_comp);
 }
 
-void ploop_enospc_timer(struct timer_list *timer)
+static void qcow2_enospc_timer(struct timer_list *timer)
 {
 	struct qcow2_target *tgt = from_timer(tgt, timer, enospc_timer);
 	unsigned long flags;
@@ -486,7 +486,7 @@ static struct qcow2_target *alloc_qcow2_target(struct dm_target *ti)
 	init_waitqueue_head(&tgt->service_wq);
 	INIT_WORK(&tgt->event_work, qcow2_event_work);
 	INIT_LIST_HEAD(&tgt->enospc_qios);
-	timer_setup(&tgt->enospc_timer, ploop_enospc_timer, 0);
+	timer_setup(&tgt->enospc_timer, qcow2_enospc_timer, 0);
 	ti->private = tgt;
 	tgt->ti = ti;
 	qcow2_set_service_operations(ti, false);
@@ -913,7 +913,7 @@ static void qcow2_presuspend(struct dm_target *ti)
 	qcow2_set_service_operations(ti, false);
 	qcow2_set_wants_suspend(ti, true);
 	del_timer_sync(&tgt->enospc_timer);
-	ploop_enospc_timer(&tgt->enospc_timer);
+	qcow2_enospc_timer(&tgt->enospc_timer);
 }
 static void qcow2_presuspend_undo(struct dm_target *ti)
 {




More information about the Devel mailing list