From: Johannes Thumshirn Date: Thu, 23 Jun 2016 09:52:04 +0000 (+0200) Subject: libnvdimm: initialize struct blk_integrity with 0 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=8729bdea829ebecfbc9601ba792e35f63331f63e;p=linux-beck.git libnvdimm: initialize struct blk_integrity with 0 Initialize struct blk_integrity with 0 as blk_integrity_register() takes the then unitialized struct blk_integrity::flags and ORs it to the resulting block integrity structure. Signed-off-by: Johannes Thumshirn Signed-off-by: Dan Williams --- diff --git a/drivers/nvdimm/core.c b/drivers/nvdimm/core.c index be89764315c2..32e4fe2f6274 100644 --- a/drivers/nvdimm/core.c +++ b/drivers/nvdimm/core.c @@ -601,7 +601,8 @@ int nd_integrity_init(struct gendisk *disk, unsigned long meta_size) if (meta_size == 0) return 0; - bi.profile = NULL; + memset(&bi, 0, sizeof(bi)); + bi.tuple_size = meta_size; bi.tag_size = meta_size;