Loading fs/crypto/keysetup.c +3 −12 Original line number Diff line number Diff line Loading @@ -477,18 +477,9 @@ static void put_crypt_info(struct fscrypt_info *ci) if (ci->ci_direct_key) fscrypt_put_direct_key(ci->ci_direct_key); else if (ci->ci_owns_key) { if (fscrypt_policy_contents_mode(&ci->ci_policy) != FSCRYPT_MODE_PRIVATE) { else if (ci->ci_owns_key) fscrypt_destroy_prepared_key(&ci->ci_key); } else { crypto_free_skcipher(ci->ci_key.tfm); #ifdef CONFIG_FS_ENCRYPTION_INLINE_CRYPT if (ci->ci_key.blk_key) kzfree(ci->ci_key.blk_key); #endif } } key = ci->ci_master_key; if (key) { struct fscrypt_master_key *mk = key->payload.data[0]; Loading fs/crypto/keysetup_v1.c +2 −6 Original line number Diff line number Diff line Loading @@ -314,7 +314,6 @@ static int setup_v1_file_key_derived(struct fscrypt_info *ci, if ((fscrypt_policy_contents_mode(&ci->ci_policy) == FSCRYPT_MODE_PRIVATE) && fscrypt_using_inline_encryption(ci)) { ci->ci_owns_key = true; if (ci->ci_policy.v1.flags & FSCRYPT_POLICY_FLAG_IV_INO_LBLK_32) { union { Loading Loading @@ -353,11 +352,8 @@ static int setup_v1_file_key_derived(struct fscrypt_info *ci, for (i = 0; i < ARRAY_SIZE(key_new.words); i++) __cpu_to_be32s(&key_new.words[i]); err = fscrypt_prepare_inline_crypt_key(&ci->ci_key, key_new.bytes, ci->ci_mode->keysize, false, ci); err = setup_v1_file_key_direct(ci, key_new.bytes); if (derived_key) kzfree(derived_key); Loading Loading
fs/crypto/keysetup.c +3 −12 Original line number Diff line number Diff line Loading @@ -477,18 +477,9 @@ static void put_crypt_info(struct fscrypt_info *ci) if (ci->ci_direct_key) fscrypt_put_direct_key(ci->ci_direct_key); else if (ci->ci_owns_key) { if (fscrypt_policy_contents_mode(&ci->ci_policy) != FSCRYPT_MODE_PRIVATE) { else if (ci->ci_owns_key) fscrypt_destroy_prepared_key(&ci->ci_key); } else { crypto_free_skcipher(ci->ci_key.tfm); #ifdef CONFIG_FS_ENCRYPTION_INLINE_CRYPT if (ci->ci_key.blk_key) kzfree(ci->ci_key.blk_key); #endif } } key = ci->ci_master_key; if (key) { struct fscrypt_master_key *mk = key->payload.data[0]; Loading
fs/crypto/keysetup_v1.c +2 −6 Original line number Diff line number Diff line Loading @@ -314,7 +314,6 @@ static int setup_v1_file_key_derived(struct fscrypt_info *ci, if ((fscrypt_policy_contents_mode(&ci->ci_policy) == FSCRYPT_MODE_PRIVATE) && fscrypt_using_inline_encryption(ci)) { ci->ci_owns_key = true; if (ci->ci_policy.v1.flags & FSCRYPT_POLICY_FLAG_IV_INO_LBLK_32) { union { Loading Loading @@ -353,11 +352,8 @@ static int setup_v1_file_key_derived(struct fscrypt_info *ci, for (i = 0; i < ARRAY_SIZE(key_new.words); i++) __cpu_to_be32s(&key_new.words[i]); err = fscrypt_prepare_inline_crypt_key(&ci->ci_key, key_new.bytes, ci->ci_mode->keysize, false, ci); err = setup_v1_file_key_direct(ci, key_new.bytes); if (derived_key) kzfree(derived_key); Loading