Skip to content

Commit 52d1998

Browse files
committed
Merge tag 'fscrypt-for-linus' of git://git.kernel.org/pub/scm/fs/fscrypt/fscrypt
Pull fscrypt fix from Eric Biggers: "Fix a regression where a new WARN_ON() was reachable when using FSCRYPT_POLICY_FLAG_IV_INO_LBLK_32 on ext4, causing xfstest generic/602 to sometimes fail on ext4" * tag 'fscrypt-for-linus' of git://git.kernel.org/pub/scm/fs/fscrypt/fscrypt: fscrypt: remove reachable WARN in fscrypt_setup_iv_ino_lblk_32_key()
2 parents 8bff39b + 92cfcd0 commit 52d1998

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

fs/crypto/keysetup.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -269,9 +269,7 @@ static int fscrypt_setup_iv_ino_lblk_32_key(struct fscrypt_info *ci,
269269
* New inodes may not have an inode number assigned yet.
270270
* Hashing their inode number is delayed until later.
271271
*/
272-
if (ci->ci_inode->i_ino == 0)
273-
WARN_ON(!(ci->ci_inode->i_state & I_CREATING));
274-
else
272+
if (ci->ci_inode->i_ino)
275273
fscrypt_hash_inode_number(ci, mk);
276274
return 0;
277275
}

0 commit comments

Comments
 (0)