summaryrefslogtreecommitdiff
path: root/drivers/md/dm-verity.h
diff options
context:
space:
mode:
authorSami Tolvanen <samitolvanen@google.com>2015-12-03 16:30:36 -0500
committerMike Snitzer <snitzer@redhat.com>2015-12-10 10:39:02 -0500
commitbb4d73ac5e4f0a6c4853f35824f6cb2d396a2f9c (patch)
tree5037336f6c36fdc9b284331b11666596235f6f26 /drivers/md/dm-verity.h
parentffa393807cd69656d5b6bc9d9622e205071cbab8 (diff)
dm verity: factor out verity_for_bv_block()
verity_for_bv_block() will be re-used by optional dm-verity object. Signed-off-by: Sami Tolvanen <samitolvanen@google.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Diffstat (limited to 'drivers/md/dm-verity.h')
-rw-r--r--drivers/md/dm-verity.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/md/dm-verity.h b/drivers/md/dm-verity.h
index c7ad4fd05188..f5af52df8e38 100644
--- a/drivers/md/dm-verity.h
+++ b/drivers/md/dm-verity.h
@@ -103,6 +103,12 @@ static inline u8 *verity_io_want_digest(struct dm_verity *v,
return (u8 *)(io + 1) + v->shash_descsize + v->digest_size;
}
+extern int verity_for_bv_block(struct dm_verity *v, struct dm_verity_io *io,
+ struct bvec_iter *iter,
+ int (*process)(struct dm_verity *v,
+ struct dm_verity_io *io,
+ u8 *data, size_t len));
+
extern int verity_hash(struct dm_verity *v, struct shash_desc *desc,
const u8 *data, size_t len, u8 *digest);