From b87008dc6733046480cdbff7ff781a667a424dd3 Mon Sep 17 00:00:00 2001 From: Adam Rutkowski Date: Fri, 26 Mar 2021 07:22:34 -0500 Subject: [PATCH] Clear hot flag when removing node from LRU list This isn't strictly required in current implementation as nodes are always re-initialized before inserting to LRU list. However it seems to make sense to zero the flag anyway to make the code easier to reason about. Signed-off-by: Adam Rutkowski --- src/eviction/lru.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/eviction/lru.c b/src/eviction/lru.c index 542d69b..4eb9beb 100644 --- a/src/eviction/lru.c +++ b/src/eviction/lru.c @@ -170,6 +170,7 @@ static void remove_lru_list(ocf_cache_t cache, node->prev = end_marker; } + node->hot = false; --list->num_nodes; }