From: Heinz Mauelshagen Date: Tue, 7 Feb 2023 22:15:36 +0000 (+0100) Subject: dm: declare variables static when sensible X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=774f13ac2b567207f04eb34d25188f5daec57f9e;p=linux.git dm: declare variables static when sensible Signed-off-by: Heinz Mauelshagen Signed-off-by: Mike Snitzer --- diff --git a/drivers/md/dm-cache-target.c b/drivers/md/dm-cache-target.c index 6ee3599f94003..23195701dc153 100644 --- a/drivers/md/dm-cache-target.c +++ b/drivers/md/dm-cache-target.c @@ -859,7 +859,7 @@ static const char *cache_device_name(struct cache *cache) static void notify_mode_switch(struct cache *cache, enum cache_metadata_mode mode) { - const char *descs[] = { + static const char *descs[] = { "write", "read-only", "fail" diff --git a/drivers/md/dm-thin.c b/drivers/md/dm-thin.c index 0e7f4d0c59944..affd91a53042c 100644 --- a/drivers/md/dm-thin.c +++ b/drivers/md/dm-thin.c @@ -294,7 +294,7 @@ static enum pool_mode get_pool_mode(struct pool *pool) static void notify_of_pool_mode_change(struct pool *pool) { - const char *descs[] = { + static const char *descs[] = { "write", "out-of-data-space", "read-only",