Commit ece25773 authored by Jiapeng Chong's avatar Jiapeng Chong Committed by Mike Snitzer

dm persistent data: remove unused return from exit_shadow_spine()

Fix the following coccicheck warnings:

./drivers/md/persistent-data/dm-btree-spine.c:188:5-6: Unneeded
variable: "r". Return "0" on line 194.
Reported-by: default avatarAbaci Robot <abaci@linux.alibaba.com>
Signed-off-by: default avatarJiapeng Chong <jiapeng.chong@linux.alibaba.com>
Signed-off-by: default avatarMike Snitzer <snitzer@redhat.com>
parent 63508e38
...@@ -83,7 +83,7 @@ struct shadow_spine { ...@@ -83,7 +83,7 @@ struct shadow_spine {
}; };
void init_shadow_spine(struct shadow_spine *s, struct dm_btree_info *info); void init_shadow_spine(struct shadow_spine *s, struct dm_btree_info *info);
int exit_shadow_spine(struct shadow_spine *s); void exit_shadow_spine(struct shadow_spine *s);
int shadow_step(struct shadow_spine *s, dm_block_t b, int shadow_step(struct shadow_spine *s, dm_block_t b,
struct dm_btree_value_type *vt); struct dm_btree_value_type *vt);
......
...@@ -183,15 +183,13 @@ void init_shadow_spine(struct shadow_spine *s, struct dm_btree_info *info) ...@@ -183,15 +183,13 @@ void init_shadow_spine(struct shadow_spine *s, struct dm_btree_info *info)
s->count = 0; s->count = 0;
} }
int exit_shadow_spine(struct shadow_spine *s) void exit_shadow_spine(struct shadow_spine *s)
{ {
int r = 0, i; int i;
for (i = 0; i < s->count; i++) { for (i = 0; i < s->count; i++) {
unlock_block(s->info, s->nodes[i]); unlock_block(s->info, s->nodes[i]);
} }
return r;
} }
int shadow_step(struct shadow_spine *s, dm_block_t b, int shadow_step(struct shadow_spine *s, dm_block_t b,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment