[Devel] [PATCH RHEL8 COMMIT] ploop: Remove unused define and comment

Konstantin Khorenko khorenko at virtuozzo.com
Thu Jun 17 19:03:22 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.44
------>
commit 60680fa54eb6e52f4f72011116f2720d1d15e193
Author: Kirill Tkhai <ktkhai at virtuozzo.com>
Date:   Thu Jun 17 19:03:22 2021 +0300

    ploop: Remove unused define and comment
    
    Signed-off-by: Kirill Tkhai <ktkhai at virtuozzo.com>
    
    =====================
    Patchset description:
    
    ploop: Freeze WRITE on -ENOSPC on host
    
    Suspend WRITEs in case of host's fs returns -ENOSPC.
    
    https://jira.sw.ru/browse/PSBM-127225
    
    Kirill Tkhai (5):
          ploop: Add check of htable is empty on .dtr
          ploop: Rename delayed_pios into suspended_pios
          ploop: Remove unused define and comment
          ploop: Close race in ploop_flip_upper_deltas()
          ploop: Freeze on ENOSPC and notify userspace via dm event
    
    Signed-off-by: Kirill Tkhai <ktkhai at virtuozzo.com>
---
 drivers/md/dm-ploop-map.c | 24 ------------------------
 drivers/md/dm-ploop.h     |  1 -
 2 files changed, 25 deletions(-)

diff --git a/drivers/md/dm-ploop-map.c b/drivers/md/dm-ploop-map.c
index 6361c770d193..a655ab426e8e 100644
--- a/drivers/md/dm-ploop-map.c
+++ b/drivers/md/dm-ploop-map.c
@@ -12,30 +12,6 @@
 
 #define PREALLOC_SIZE (128ULL * 1024 * 1024)
 
-/*
- * The idea of this driver is that the most part of time it does nothing:
- * ploop_map() just replaces bio->bi_iter.bi_sector with the cluster value
- * referred in bat_entries[]. No kwork is involved, all the work becomes
- * delegated to backed device (loop). Kwork starts only when a bio aims
- * to a not present cluster or for service requests.
- *
- * Service operations are also made from kwork, so sometimes we may avoid
- * synchronization because of this. Two different service operations can't
- * be executed in parallel.
- *
- * Discard begins from switching ploop in a special mode, when all requests
- * are managed by kwork, while all not-exclusive bios (e.g., READ or simple
- * WRITE) are linked to inflight_pios_rbtree. Discard bios are linked into
- * exclusive_bios_rbtree, but their start is delayed till all not-exclusive
- * bios going into the same cluster are finished. After exclusive bio is
- * started, the corresponding cluster becomes "locked", and all further bios
- * going into the same cluster becomes delayed.
- * Since the swithing into the mode is expensive, ploop remains in the mode
- * for CLEANUP_DELAY seconds in a hope that a new discard bio will come.
- * After this interval the device returns into normal mode, and ordinary bios
- * become handled in ploop_map() as before.
- */
-
 static void handle_cleanup(struct ploop *ploop, struct pio *pio);
 
 #define DM_MSG_PREFIX "ploop"
diff --git a/drivers/md/dm-ploop.h b/drivers/md/dm-ploop.h
index 72628756412e..d0f1493e12e6 100644
--- a/drivers/md/dm-ploop.h
+++ b/drivers/md/dm-ploop.h
@@ -76,7 +76,6 @@ struct ploop_cmd {
 /* We can't use 0 for unmapped clusters, since RAW image references 0 cluster */
 #define BAT_ENTRY_NONE		UINT_MAX
 
-#define CLEANUP_DELAY		20
 #define PLOOP_INFLIGHT_TIMEOUT	(60 * HZ)
 
 #define PLOOP_BIOS_HTABLE_BITS	8


More information about the Devel mailing list