diff --git a/drivers/block/null_blk_zoned.c b/drivers/block/null_blk_zoned.c index 5f1376578ea3..90dcf4a915f4 100644 --- a/drivers/block/null_blk_zoned.c +++ b/drivers/block/null_blk_zoned.c @@ -73,6 +73,7 @@ int null_zone_init(struct nullb_device *dev) void null_zone_exit(struct nullb_device *dev) { kvfree(dev->zones); + dev->zones = NULL; } int null_zone_report(struct gendisk *disk, sector_t sector,