summaryrefslogtreecommitdiffstats
path: root/drivers/md
diff options
context:
space:
mode:
authorJoe Thornber <ejt@redhat.com>2014-12-01 14:38:11 +0000
committerMike Snitzer <snitzer@redhat.com>2014-12-02 10:25:06 -0500
commit02717d9855400c12c6e338ce1f5c2e1310def49a (patch)
treede3feeb1e094b0eafa8ef51930b4d8cef211d9f9 /drivers/md
parentc1c6156fe4d4577444b769d7edd5dd503e57bbc9 (diff)
downloadblackbird-op-linux-02717d9855400c12c6e338ce1f5c2e1310def49a.tar.gz
blackbird-op-linux-02717d9855400c12c6e338ce1f5c2e1310def49a.zip
dm space map metadata: fix sm_bootstrap_get_count()
Must set 'result' accordingly rather than return it. Signed-off-by: Joe Thornber <ejt@redhat.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md')
-rw-r--r--drivers/md/persistent-data/dm-space-map-metadata.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/md/persistent-data/dm-space-map-metadata.c b/drivers/md/persistent-data/dm-space-map-metadata.c
index f4e22bcc7fb8..e8a904298887 100644
--- a/drivers/md/persistent-data/dm-space-map-metadata.c
+++ b/drivers/md/persistent-data/dm-space-map-metadata.c
@@ -583,7 +583,9 @@ static int sm_bootstrap_get_count(struct dm_space_map *sm, dm_block_t b,
{
struct sm_metadata *smm = container_of(sm, struct sm_metadata, sm);
- return b < smm->begin ? 1 : 0;
+ *result = (b < smm->begin) ? 1 : 0;
+
+ return 0;
}
static int sm_bootstrap_count_is_more_than_one(struct dm_space_map *sm,
OpenPOWER on IntegriCloud