From 59c7190722bf003435cd32a5199053f0d06eb693 Mon Sep 17 00:00:00 2001 From: Stephen Rothwell Date: Thu, 28 Jul 2022 20:28:41 +1000 Subject: [PATCH] fix up for "dm: Add verity helpers for LoadPin" interacting with 2aec377a2925 ("dm table: remove dm_table_get_num_targets() wrapper") 564b5c5476cd ("dm table: audit all dm_table_get_target() callers") from the device-mapper tree. Signed-off-by: Stephen Rothwell --- drivers/md/dm-verity-loadpin.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/md/dm-verity-loadpin.c b/drivers/md/dm-verity-loadpin.c index 10c18bc1652c2..387ec43aef728 100644 --- a/drivers/md/dm-verity-loadpin.c +++ b/drivers/md/dm-verity-loadpin.c @@ -5,6 +5,7 @@ #include #include "dm.h" +#include "dm-core.h" #include "dm-verity.h" #define DM_MSG_PREFIX "verity-loadpin" @@ -58,7 +59,7 @@ bool dm_verity_loadpin_is_bdev_trusted(struct block_device *bdev) table = dm_get_live_table(md, &srcu_idx); - if (dm_table_get_num_targets(table) != 1) + if (table->num_targets != 1) goto out; ti = dm_table_get_target(table, 0);