diff options
author | Mikulas Patocka <mpatocka@redhat.com> | 2024-11-11 16:51:02 +0100 |
---|---|---|
committer | Mikulas Patocka <mpatocka@redhat.com> | 2024-11-11 17:04:39 +0100 |
commit | 346dbf1b1345476a6524512892cceb931bee3039 (patch) | |
tree | ccf912859cf6d78384303a0a8a8ba244f88d2872 /drivers/md/dm-cache-background-tracker.h | |
parent | 42964e4b5e3ac95090bdd23ed7da2a941ccd902c (diff) |
dm-cache: fix warnings about duplicate slab caches
The commit 4c39529663b9 adds a warning about duplicate cache names if
CONFIG_DEBUG_VM is selected. These warnings are triggered by the dm-cache
code.
The dm-cache code allocates a slab cache for each device. This commit
changes it to allocate just one slab cache in the module init function.
Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Fixes: 4c39529663b9 ("slab: Warn on duplicate cache names when DEBUG_VM=y")
Diffstat (limited to 'drivers/md/dm-cache-background-tracker.h')
-rw-r--r-- | drivers/md/dm-cache-background-tracker.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/md/dm-cache-background-tracker.h b/drivers/md/dm-cache-background-tracker.h index 5b8f5c667b81..09c8fc59f7bb 100644 --- a/drivers/md/dm-cache-background-tracker.h +++ b/drivers/md/dm-cache-background-tracker.h @@ -26,6 +26,14 @@ * protected with a spinlock. */ +struct bt_work { + struct list_head list; + struct rb_node node; + struct policy_work work; +}; + +extern struct kmem_cache *btracker_work_cache; + struct background_work; struct background_tracker; |