From 71f7385fcb566456887409d1541e2ca0fa2b2eb6 Mon Sep 17 00:00:00 2001 From: Ondrej Kozina Date: Tue, 30 Jul 2019 15:11:44 +0200 Subject: [PATCH] Add support for linear segment in device comparison. --- lib/setup.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/setup.c b/lib/setup.c index 4883abf7..05f728b8 100644 --- a/lib/setup.c +++ b/lib/setup.c @@ -2440,6 +2440,9 @@ int crypt_compare_dm_devices(struct crypt_device *cd, case DM_INTEGRITY: r = _compare_integrity_devices(cd, s, t); break; + case DM_LINEAR: + r = (s->u.linear.offset == t->u.linear.offset) ? 0 : -EINVAL; + break; default: r = -ENOTSUP; }