author: Christoph Hellwig <hch@lst.de> 2020-11-24 12:01:45 +0100
committer: Jens Axboe <axboe@kernel.dk> 2020-12-01 14:53:40 -0700
commit: 231926dbf0f084211e4ec4f4c006f0bf1f47809a
parent: 29ff57c61094e7bbd921ab10b5a99dce9a0132e0
Commit Summary:
Diffstat:
1 file changed, 4 insertions, 3 deletions
diff --git a/init/do_mounts.c b/init/do_mounts.c
index 5879edf083b3..368ccb718501 100644
--- a/init/do_mounts.c
+++ b/init/do_mounts.c
@@ -79,8 +79,8 @@ static int match_dev_by_uuid(struct device *dev, const void *data)
const struct uuidcmp *cmp = data;
struct hd_struct *part = dev_to_part(dev);
- if (!part->info ||
- strncasecmp(cmp->uuid, part->info->uuid, cmp->len))
+ if (!part->bdev->bd_meta_info ||
+ strncasecmp(cmp->uuid, part->bdev->bd_meta_info->uuid, cmp->len))
return 0;
return 1;
}
@@ -169,7 +169,8 @@ static int match_dev_by_label(struct device *dev, const void *data)
const char *label = data;
struct hd_struct *part = dev_to_part(dev);
- if (!part->info || strcmp(label, part->info->volname))
+ if (!part->bdev->bd_meta_info ||
+ strcmp(label, part->bdev->bd_meta_info->volname))
return 0;
return 1;
}