mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-12 03:10:08 +01:00
Add new internal state marking resilience type as not set.
This commit is contained in:
@@ -139,7 +139,8 @@ typedef struct {
|
|||||||
} keyslot_handler;
|
} keyslot_handler;
|
||||||
|
|
||||||
struct reenc_protection {
|
struct reenc_protection {
|
||||||
enum { REENC_PROTECTION_NONE = 0, /* none should be 0 always */
|
enum { REENC_PROTECTION_NOT_SET = 0,
|
||||||
|
REENC_PROTECTION_NONE,
|
||||||
REENC_PROTECTION_CHECKSUM,
|
REENC_PROTECTION_CHECKSUM,
|
||||||
REENC_PROTECTION_JOURNAL,
|
REENC_PROTECTION_JOURNAL,
|
||||||
REENC_PROTECTION_DATASHIFT } type;
|
REENC_PROTECTION_DATASHIFT } type;
|
||||||
|
|||||||
@@ -1229,6 +1229,9 @@ static int reencrypt_hotzone_protect_ready(struct crypt_device *cd,
|
|||||||
{
|
{
|
||||||
assert(rp);
|
assert(rp);
|
||||||
|
|
||||||
|
if (rp->type == REENC_PROTECTION_NOT_SET)
|
||||||
|
return -EINVAL;
|
||||||
|
|
||||||
if (rp->type != REENC_PROTECTION_CHECKSUM)
|
if (rp->type != REENC_PROTECTION_CHECKSUM)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user