Skip to contentSkip to conversation

dm-writecache: get rid of memory_data flush to writecache_flush_entry

PATCH Superseded Huaisheng Ye 1 participant 1 message Jan 3, 2019 Device mapper

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 2/2 dm-writecache: get rid of memory_data flush to writecache_flush_entry

From: Huaisheng Ye <[email protected]>

writecache_flush_region only works when SSD mode.
If wc->pmem_mode sets, writecache_flush_region doesn't need to be called in writecache_flush_entry.

---
 drivers/md/dm-writecache.c | 2 --
 1 file changed, 2 deletions(-)
drivers/md/dm-writecache.c +0 -2
index 2d8e0c0..c69317c 100644
@@ -688,8 +688,6 @@ static void writecache_poison_lists(struct dm_writecache *wc)
 static void writecache_flush_entry(struct dm_writecache *wc, struct wc_entry *e)
 {
 	writecache_flush_region(wc, memory_entry(wc, e));
-	if (WC_MODE_PMEM(wc))
-		writecache_flush_region(wc, memory_data(wc, e));
 }
 
 static bool writecache_entry_is_committed(struct dm_writecache *wc, struct wc_entry *e)
Signature · 1 line
1.8.3.1