diff for duplicates of <20190726224141.14044-6-ebiggers@kernel.org> diff --git a/a/1.txt b/N1/1.txt index e55f236..4a188d8 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -316,7 +316,7 @@ index 2d45a86f09db2..0000000000000 - key = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX, - ctx->master_key_descriptor, - mode->keysize, &payload); -- if (key = ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) { +- if (key == ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) { - key = find_and_lock_process_key(inode->i_sb->s_cop->key_prefix, - ctx->master_key_descriptor, - mode->keysize, &payload); @@ -330,7 +330,8 @@ index 2d45a86f09db2..0000000000000 - "Direct key mode not allowed with %s", - mode->friendly_name); - err = -EINVAL; -- } else if (ctx->contents_encryption_mode !- ctx->filenames_encryption_mode) { +- } else if (ctx->contents_encryption_mode != +- ctx->filenames_encryption_mode) { - fscrypt_warn(inode, - "Direct key mode not allowed with different contents and filenames modes"); - err = -EINVAL; @@ -357,7 +358,7 @@ index 2d45a86f09db2..0000000000000 - - tfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0); - if (IS_ERR(tfm)) { -- if (PTR_ERR(tfm) = -ENOENT) { +- if (PTR_ERR(tfm) == -ENOENT) { - fscrypt_warn(inode, - "Missing crypto API support for %s (API name: \"%s\")", - mode->friendly_name, mode->cipher_str); @@ -510,7 +511,7 @@ index 2d45a86f09db2..0000000000000 - - tfm = crypto_alloc_shash("sha256", 0, 0); - if (IS_ERR(tfm)) { -- if (PTR_ERR(tfm) = -ENOENT) { +- if (PTR_ERR(tfm) == -ENOENT) { - fscrypt_warn(NULL, - "Missing crypto API support for SHA-256"); - return -ENOPKG; @@ -710,10 +711,10 @@ index 2d45a86f09db2..0000000000000 - if (res) - goto out; - -- if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL) +- if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL) - crypt_info = NULL; -out: -- if (res = -ENOKEY) +- if (res == -ENOKEY) - res = 0; - put_crypt_info(crypt_info); - kzfree(raw_key); @@ -838,7 +839,7 @@ index 0000000000000..479128998ae7a + + tfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0); + if (IS_ERR(tfm)) { -+ if (PTR_ERR(tfm) = -ENOENT) { ++ if (PTR_ERR(tfm) == -ENOENT) { + fscrypt_warn(inode, + "Missing crypto API support for %s (API name: \"%s\")", + mode->friendly_name, mode->cipher_str); @@ -883,7 +884,7 @@ index 0000000000000..479128998ae7a + + tfm = crypto_alloc_shash("sha256", 0, 0); + if (IS_ERR(tfm)) { -+ if (PTR_ERR(tfm) = -ENOENT) { ++ if (PTR_ERR(tfm) == -ENOENT) { + fscrypt_warn(NULL, + "Missing crypto API support for SHA-256"); + return -ENOPKG; @@ -1063,10 +1064,10 @@ index 0000000000000..479128998ae7a + if (res) + goto out; + -+ if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL) ++ if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL) + crypt_info = NULL; +out: -+ if (res = -ENOKEY) ++ if (res == -ENOKEY) + res = 0; + put_crypt_info(crypt_info); + return res; @@ -1431,7 +1432,7 @@ index 0000000000000..b3c06322afa3c + key = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX, + ci->ci_master_key_descriptor, + ci->ci_mode->keysize, &payload); -+ if (key = ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) { ++ if (key == ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) { + key = find_and_lock_process_key(ci->ci_inode->i_sb->s_cop->key_prefix, + ci->ci_master_key_descriptor, + ci->ci_mode->keysize, &payload); diff --git a/a/content_digest b/N1/content_digest index 6ef78de..5c3e66b 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,7 +1,7 @@ "ref\020190726224141.14044-1-ebiggers@kernel.org\0" "From\0Eric Biggers <ebiggers@kernel.org>\0" "Subject\0[PATCH v7 05/16] fscrypt: refactor v1 policy key setup into keysetup_legacy.c\0" - "Date\0Fri, 26 Jul 2019 22:41:30 +0000\0" + "Date\0Fri, 26 Jul 2019 15:41:30 -0700\0" "To\0linux-fscrypt@vger.kernel.org\0" "Cc\0Satya Tangirala <satyat@google.com>" linux-api@vger.kernel.org @@ -332,7 +332,7 @@ "-\tkey = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX,\n" "-\t\t\t\t\tctx->master_key_descriptor,\n" "-\t\t\t\t\tmode->keysize, &payload);\n" - "-\tif (key = ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) {\n" + "-\tif (key == ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) {\n" "-\t\tkey = find_and_lock_process_key(inode->i_sb->s_cop->key_prefix,\n" "-\t\t\t\t\t\tctx->master_key_descriptor,\n" "-\t\t\t\t\t\tmode->keysize, &payload);\n" @@ -346,7 +346,8 @@ "-\t\t\t\t \"Direct key mode not allowed with %s\",\n" "-\t\t\t\t mode->friendly_name);\n" "-\t\t\terr = -EINVAL;\n" - "-\t\t} else if (ctx->contents_encryption_mode !-\t\t\t ctx->filenames_encryption_mode) {\n" + "-\t\t} else if (ctx->contents_encryption_mode !=\n" + "-\t\t\t ctx->filenames_encryption_mode) {\n" "-\t\t\tfscrypt_warn(inode,\n" "-\t\t\t\t \"Direct key mode not allowed with different contents and filenames modes\");\n" "-\t\t\terr = -EINVAL;\n" @@ -373,7 +374,7 @@ "-\n" "-\ttfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0);\n" "-\tif (IS_ERR(tfm)) {\n" - "-\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "-\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "-\t\t\tfscrypt_warn(inode,\n" "-\t\t\t\t \"Missing crypto API support for %s (API name: \\\"%s\\\")\",\n" "-\t\t\t\t mode->friendly_name, mode->cipher_str);\n" @@ -526,7 +527,7 @@ "-\n" "-\t\ttfm = crypto_alloc_shash(\"sha256\", 0, 0);\n" "-\t\tif (IS_ERR(tfm)) {\n" - "-\t\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "-\t\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "-\t\t\t\tfscrypt_warn(NULL,\n" "-\t\t\t\t\t \"Missing crypto API support for SHA-256\");\n" "-\t\t\t\treturn -ENOPKG;\n" @@ -726,10 +727,10 @@ "-\tif (res)\n" "-\t\tgoto out;\n" "-\n" - "-\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL)\n" + "-\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL)\n" "-\t\tcrypt_info = NULL;\n" "-out:\n" - "-\tif (res = -ENOKEY)\n" + "-\tif (res == -ENOKEY)\n" "-\t\tres = 0;\n" "-\tput_crypt_info(crypt_info);\n" "-\tkzfree(raw_key);\n" @@ -854,7 +855,7 @@ "+\n" "+\ttfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0);\n" "+\tif (IS_ERR(tfm)) {\n" - "+\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "+\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "+\t\t\tfscrypt_warn(inode,\n" "+\t\t\t\t \"Missing crypto API support for %s (API name: \\\"%s\\\")\",\n" "+\t\t\t\t mode->friendly_name, mode->cipher_str);\n" @@ -899,7 +900,7 @@ "+\n" "+\t\ttfm = crypto_alloc_shash(\"sha256\", 0, 0);\n" "+\t\tif (IS_ERR(tfm)) {\n" - "+\t\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "+\t\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "+\t\t\t\tfscrypt_warn(NULL,\n" "+\t\t\t\t\t \"Missing crypto API support for SHA-256\");\n" "+\t\t\t\treturn -ENOPKG;\n" @@ -1079,10 +1080,10 @@ "+\tif (res)\n" "+\t\tgoto out;\n" "+\n" - "+\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL)\n" + "+\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL)\n" "+\t\tcrypt_info = NULL;\n" "+out:\n" - "+\tif (res = -ENOKEY)\n" + "+\tif (res == -ENOKEY)\n" "+\t\tres = 0;\n" "+\tput_crypt_info(crypt_info);\n" "+\treturn res;\n" @@ -1447,7 +1448,7 @@ "+\tkey = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX,\n" "+\t\t\t\t\tci->ci_master_key_descriptor,\n" "+\t\t\t\t\tci->ci_mode->keysize, &payload);\n" - "+\tif (key = ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) {\n" + "+\tif (key == ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) {\n" "+\t\tkey = find_and_lock_process_key(ci->ci_inode->i_sb->s_cop->key_prefix,\n" "+\t\t\t\t\t\tci->ci_master_key_descriptor,\n" "+\t\t\t\t\t\tci->ci_mode->keysize, &payload);\n" @@ -1485,4 +1486,4 @@ "-- \n" 2.22.0 -ca570378a56a7ef0262b0af8bdce24814670e3f66d6f5965379466faee44af2f +a16c0cf2507795b44880245e37fd0ae7ae1ab22d9e384dfda2b7b94476df5b84
diff --git a/a/1.txt b/N2/1.txt index e55f236..4a188d8 100644 --- a/a/1.txt +++ b/N2/1.txt @@ -316,7 +316,7 @@ index 2d45a86f09db2..0000000000000 - key = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX, - ctx->master_key_descriptor, - mode->keysize, &payload); -- if (key = ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) { +- if (key == ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) { - key = find_and_lock_process_key(inode->i_sb->s_cop->key_prefix, - ctx->master_key_descriptor, - mode->keysize, &payload); @@ -330,7 +330,8 @@ index 2d45a86f09db2..0000000000000 - "Direct key mode not allowed with %s", - mode->friendly_name); - err = -EINVAL; -- } else if (ctx->contents_encryption_mode !- ctx->filenames_encryption_mode) { +- } else if (ctx->contents_encryption_mode != +- ctx->filenames_encryption_mode) { - fscrypt_warn(inode, - "Direct key mode not allowed with different contents and filenames modes"); - err = -EINVAL; @@ -357,7 +358,7 @@ index 2d45a86f09db2..0000000000000 - - tfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0); - if (IS_ERR(tfm)) { -- if (PTR_ERR(tfm) = -ENOENT) { +- if (PTR_ERR(tfm) == -ENOENT) { - fscrypt_warn(inode, - "Missing crypto API support for %s (API name: \"%s\")", - mode->friendly_name, mode->cipher_str); @@ -510,7 +511,7 @@ index 2d45a86f09db2..0000000000000 - - tfm = crypto_alloc_shash("sha256", 0, 0); - if (IS_ERR(tfm)) { -- if (PTR_ERR(tfm) = -ENOENT) { +- if (PTR_ERR(tfm) == -ENOENT) { - fscrypt_warn(NULL, - "Missing crypto API support for SHA-256"); - return -ENOPKG; @@ -710,10 +711,10 @@ index 2d45a86f09db2..0000000000000 - if (res) - goto out; - -- if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL) +- if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL) - crypt_info = NULL; -out: -- if (res = -ENOKEY) +- if (res == -ENOKEY) - res = 0; - put_crypt_info(crypt_info); - kzfree(raw_key); @@ -838,7 +839,7 @@ index 0000000000000..479128998ae7a + + tfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0); + if (IS_ERR(tfm)) { -+ if (PTR_ERR(tfm) = -ENOENT) { ++ if (PTR_ERR(tfm) == -ENOENT) { + fscrypt_warn(inode, + "Missing crypto API support for %s (API name: \"%s\")", + mode->friendly_name, mode->cipher_str); @@ -883,7 +884,7 @@ index 0000000000000..479128998ae7a + + tfm = crypto_alloc_shash("sha256", 0, 0); + if (IS_ERR(tfm)) { -+ if (PTR_ERR(tfm) = -ENOENT) { ++ if (PTR_ERR(tfm) == -ENOENT) { + fscrypt_warn(NULL, + "Missing crypto API support for SHA-256"); + return -ENOPKG; @@ -1063,10 +1064,10 @@ index 0000000000000..479128998ae7a + if (res) + goto out; + -+ if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL) ++ if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL) + crypt_info = NULL; +out: -+ if (res = -ENOKEY) ++ if (res == -ENOKEY) + res = 0; + put_crypt_info(crypt_info); + return res; @@ -1431,7 +1432,7 @@ index 0000000000000..b3c06322afa3c + key = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX, + ci->ci_master_key_descriptor, + ci->ci_mode->keysize, &payload); -+ if (key = ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) { ++ if (key == ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) { + key = find_and_lock_process_key(ci->ci_inode->i_sb->s_cop->key_prefix, + ci->ci_master_key_descriptor, + ci->ci_mode->keysize, &payload); diff --git a/a/content_digest b/N2/content_digest index 6ef78de..0f22a52 100644 --- a/a/content_digest +++ b/N2/content_digest @@ -1,17 +1,17 @@ "ref\020190726224141.14044-1-ebiggers@kernel.org\0" "From\0Eric Biggers <ebiggers@kernel.org>\0" "Subject\0[PATCH v7 05/16] fscrypt: refactor v1 policy key setup into keysetup_legacy.c\0" - "Date\0Fri, 26 Jul 2019 22:41:30 +0000\0" + "Date\0Fri, 26 Jul 2019 15:41:30 -0700\0" "To\0linux-fscrypt@vger.kernel.org\0" - "Cc\0Satya Tangirala <satyat@google.com>" - linux-api@vger.kernel.org + "Cc\0linux-fsdevel@vger.kernel.org" + linux-ext4@vger.kernel.org linux-f2fs-devel@lists.sourceforge.net - keyrings@vger.kernel.org linux-mtd@lists.infradead.org + linux-api@vger.kernel.org linux-crypto@vger.kernel.org - linux-fsdevel@vger.kernel.org - linux-ext4@vger.kernel.org - " Paul Crowley <paulcrowley@google.com>\0" + keyrings@vger.kernel.org + Paul Crowley <paulcrowley@google.com> + " Satya Tangirala <satyat@google.com>\0" "\00:1\0" "b\0" "From: Eric Biggers <ebiggers@google.com>\n" @@ -332,7 +332,7 @@ "-\tkey = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX,\n" "-\t\t\t\t\tctx->master_key_descriptor,\n" "-\t\t\t\t\tmode->keysize, &payload);\n" - "-\tif (key = ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) {\n" + "-\tif (key == ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) {\n" "-\t\tkey = find_and_lock_process_key(inode->i_sb->s_cop->key_prefix,\n" "-\t\t\t\t\t\tctx->master_key_descriptor,\n" "-\t\t\t\t\t\tmode->keysize, &payload);\n" @@ -346,7 +346,8 @@ "-\t\t\t\t \"Direct key mode not allowed with %s\",\n" "-\t\t\t\t mode->friendly_name);\n" "-\t\t\terr = -EINVAL;\n" - "-\t\t} else if (ctx->contents_encryption_mode !-\t\t\t ctx->filenames_encryption_mode) {\n" + "-\t\t} else if (ctx->contents_encryption_mode !=\n" + "-\t\t\t ctx->filenames_encryption_mode) {\n" "-\t\t\tfscrypt_warn(inode,\n" "-\t\t\t\t \"Direct key mode not allowed with different contents and filenames modes\");\n" "-\t\t\terr = -EINVAL;\n" @@ -373,7 +374,7 @@ "-\n" "-\ttfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0);\n" "-\tif (IS_ERR(tfm)) {\n" - "-\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "-\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "-\t\t\tfscrypt_warn(inode,\n" "-\t\t\t\t \"Missing crypto API support for %s (API name: \\\"%s\\\")\",\n" "-\t\t\t\t mode->friendly_name, mode->cipher_str);\n" @@ -526,7 +527,7 @@ "-\n" "-\t\ttfm = crypto_alloc_shash(\"sha256\", 0, 0);\n" "-\t\tif (IS_ERR(tfm)) {\n" - "-\t\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "-\t\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "-\t\t\t\tfscrypt_warn(NULL,\n" "-\t\t\t\t\t \"Missing crypto API support for SHA-256\");\n" "-\t\t\t\treturn -ENOPKG;\n" @@ -726,10 +727,10 @@ "-\tif (res)\n" "-\t\tgoto out;\n" "-\n" - "-\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL)\n" + "-\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL)\n" "-\t\tcrypt_info = NULL;\n" "-out:\n" - "-\tif (res = -ENOKEY)\n" + "-\tif (res == -ENOKEY)\n" "-\t\tres = 0;\n" "-\tput_crypt_info(crypt_info);\n" "-\tkzfree(raw_key);\n" @@ -854,7 +855,7 @@ "+\n" "+\ttfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0);\n" "+\tif (IS_ERR(tfm)) {\n" - "+\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "+\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "+\t\t\tfscrypt_warn(inode,\n" "+\t\t\t\t \"Missing crypto API support for %s (API name: \\\"%s\\\")\",\n" "+\t\t\t\t mode->friendly_name, mode->cipher_str);\n" @@ -899,7 +900,7 @@ "+\n" "+\t\ttfm = crypto_alloc_shash(\"sha256\", 0, 0);\n" "+\t\tif (IS_ERR(tfm)) {\n" - "+\t\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "+\t\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "+\t\t\t\tfscrypt_warn(NULL,\n" "+\t\t\t\t\t \"Missing crypto API support for SHA-256\");\n" "+\t\t\t\treturn -ENOPKG;\n" @@ -1079,10 +1080,10 @@ "+\tif (res)\n" "+\t\tgoto out;\n" "+\n" - "+\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL)\n" + "+\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL)\n" "+\t\tcrypt_info = NULL;\n" "+out:\n" - "+\tif (res = -ENOKEY)\n" + "+\tif (res == -ENOKEY)\n" "+\t\tres = 0;\n" "+\tput_crypt_info(crypt_info);\n" "+\treturn res;\n" @@ -1447,7 +1448,7 @@ "+\tkey = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX,\n" "+\t\t\t\t\tci->ci_master_key_descriptor,\n" "+\t\t\t\t\tci->ci_mode->keysize, &payload);\n" - "+\tif (key = ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) {\n" + "+\tif (key == ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) {\n" "+\t\tkey = find_and_lock_process_key(ci->ci_inode->i_sb->s_cop->key_prefix,\n" "+\t\t\t\t\t\tci->ci_master_key_descriptor,\n" "+\t\t\t\t\t\tci->ci_mode->keysize, &payload);\n" @@ -1485,4 +1486,4 @@ "-- \n" 2.22.0 -ca570378a56a7ef0262b0af8bdce24814670e3f66d6f5965379466faee44af2f +f74f5019b1ef141cc99ee4858cff4735a598f1e832722a2e032eaacdcd702592
diff --git a/a/1.txt b/N3/1.txt index e55f236..878d950 100644 --- a/a/1.txt +++ b/N3/1.txt @@ -316,7 +316,7 @@ index 2d45a86f09db2..0000000000000 - key = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX, - ctx->master_key_descriptor, - mode->keysize, &payload); -- if (key = ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) { +- if (key == ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) { - key = find_and_lock_process_key(inode->i_sb->s_cop->key_prefix, - ctx->master_key_descriptor, - mode->keysize, &payload); @@ -330,7 +330,8 @@ index 2d45a86f09db2..0000000000000 - "Direct key mode not allowed with %s", - mode->friendly_name); - err = -EINVAL; -- } else if (ctx->contents_encryption_mode !- ctx->filenames_encryption_mode) { +- } else if (ctx->contents_encryption_mode != +- ctx->filenames_encryption_mode) { - fscrypt_warn(inode, - "Direct key mode not allowed with different contents and filenames modes"); - err = -EINVAL; @@ -357,7 +358,7 @@ index 2d45a86f09db2..0000000000000 - - tfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0); - if (IS_ERR(tfm)) { -- if (PTR_ERR(tfm) = -ENOENT) { +- if (PTR_ERR(tfm) == -ENOENT) { - fscrypt_warn(inode, - "Missing crypto API support for %s (API name: \"%s\")", - mode->friendly_name, mode->cipher_str); @@ -510,7 +511,7 @@ index 2d45a86f09db2..0000000000000 - - tfm = crypto_alloc_shash("sha256", 0, 0); - if (IS_ERR(tfm)) { -- if (PTR_ERR(tfm) = -ENOENT) { +- if (PTR_ERR(tfm) == -ENOENT) { - fscrypt_warn(NULL, - "Missing crypto API support for SHA-256"); - return -ENOPKG; @@ -710,10 +711,10 @@ index 2d45a86f09db2..0000000000000 - if (res) - goto out; - -- if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL) +- if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL) - crypt_info = NULL; -out: -- if (res = -ENOKEY) +- if (res == -ENOKEY) - res = 0; - put_crypt_info(crypt_info); - kzfree(raw_key); @@ -838,7 +839,7 @@ index 0000000000000..479128998ae7a + + tfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0); + if (IS_ERR(tfm)) { -+ if (PTR_ERR(tfm) = -ENOENT) { ++ if (PTR_ERR(tfm) == -ENOENT) { + fscrypt_warn(inode, + "Missing crypto API support for %s (API name: \"%s\")", + mode->friendly_name, mode->cipher_str); @@ -883,7 +884,7 @@ index 0000000000000..479128998ae7a + + tfm = crypto_alloc_shash("sha256", 0, 0); + if (IS_ERR(tfm)) { -+ if (PTR_ERR(tfm) = -ENOENT) { ++ if (PTR_ERR(tfm) == -ENOENT) { + fscrypt_warn(NULL, + "Missing crypto API support for SHA-256"); + return -ENOPKG; @@ -1063,10 +1064,10 @@ index 0000000000000..479128998ae7a + if (res) + goto out; + -+ if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL) ++ if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL) + crypt_info = NULL; +out: -+ if (res = -ENOKEY) ++ if (res == -ENOKEY) + res = 0; + put_crypt_info(crypt_info); + return res; @@ -1431,7 +1432,7 @@ index 0000000000000..b3c06322afa3c + key = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX, + ci->ci_master_key_descriptor, + ci->ci_mode->keysize, &payload); -+ if (key = ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) { ++ if (key == ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) { + key = find_and_lock_process_key(ci->ci_inode->i_sb->s_cop->key_prefix, + ci->ci_master_key_descriptor, + ci->ci_mode->keysize, &payload); @@ -1468,3 +1469,10 @@ index 81c0c754f8b21..583802cb2e35d 100644 return -EOPNOTSUPP; -- 2.22.0 + + + +_______________________________________________ +Linux-f2fs-devel mailing list +Linux-f2fs-devel@lists.sourceforge.net +https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel diff --git a/a/content_digest b/N3/content_digest index 6ef78de..5fb340d 100644 --- a/a/content_digest +++ b/N3/content_digest @@ -1,7 +1,7 @@ "ref\020190726224141.14044-1-ebiggers@kernel.org\0" "From\0Eric Biggers <ebiggers@kernel.org>\0" - "Subject\0[PATCH v7 05/16] fscrypt: refactor v1 policy key setup into keysetup_legacy.c\0" - "Date\0Fri, 26 Jul 2019 22:41:30 +0000\0" + "Subject\0[f2fs-dev] [PATCH v7 05/16] fscrypt: refactor v1 policy key setup into keysetup_legacy.c\0" + "Date\0Fri, 26 Jul 2019 15:41:30 -0700\0" "To\0linux-fscrypt@vger.kernel.org\0" "Cc\0Satya Tangirala <satyat@google.com>" linux-api@vger.kernel.org @@ -332,7 +332,7 @@ "-\tkey = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX,\n" "-\t\t\t\t\tctx->master_key_descriptor,\n" "-\t\t\t\t\tmode->keysize, &payload);\n" - "-\tif (key = ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) {\n" + "-\tif (key == ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) {\n" "-\t\tkey = find_and_lock_process_key(inode->i_sb->s_cop->key_prefix,\n" "-\t\t\t\t\t\tctx->master_key_descriptor,\n" "-\t\t\t\t\t\tmode->keysize, &payload);\n" @@ -346,7 +346,8 @@ "-\t\t\t\t \"Direct key mode not allowed with %s\",\n" "-\t\t\t\t mode->friendly_name);\n" "-\t\t\terr = -EINVAL;\n" - "-\t\t} else if (ctx->contents_encryption_mode !-\t\t\t ctx->filenames_encryption_mode) {\n" + "-\t\t} else if (ctx->contents_encryption_mode !=\n" + "-\t\t\t ctx->filenames_encryption_mode) {\n" "-\t\t\tfscrypt_warn(inode,\n" "-\t\t\t\t \"Direct key mode not allowed with different contents and filenames modes\");\n" "-\t\t\terr = -EINVAL;\n" @@ -373,7 +374,7 @@ "-\n" "-\ttfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0);\n" "-\tif (IS_ERR(tfm)) {\n" - "-\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "-\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "-\t\t\tfscrypt_warn(inode,\n" "-\t\t\t\t \"Missing crypto API support for %s (API name: \\\"%s\\\")\",\n" "-\t\t\t\t mode->friendly_name, mode->cipher_str);\n" @@ -526,7 +527,7 @@ "-\n" "-\t\ttfm = crypto_alloc_shash(\"sha256\", 0, 0);\n" "-\t\tif (IS_ERR(tfm)) {\n" - "-\t\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "-\t\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "-\t\t\t\tfscrypt_warn(NULL,\n" "-\t\t\t\t\t \"Missing crypto API support for SHA-256\");\n" "-\t\t\t\treturn -ENOPKG;\n" @@ -726,10 +727,10 @@ "-\tif (res)\n" "-\t\tgoto out;\n" "-\n" - "-\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL)\n" + "-\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL)\n" "-\t\tcrypt_info = NULL;\n" "-out:\n" - "-\tif (res = -ENOKEY)\n" + "-\tif (res == -ENOKEY)\n" "-\t\tres = 0;\n" "-\tput_crypt_info(crypt_info);\n" "-\tkzfree(raw_key);\n" @@ -854,7 +855,7 @@ "+\n" "+\ttfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0);\n" "+\tif (IS_ERR(tfm)) {\n" - "+\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "+\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "+\t\t\tfscrypt_warn(inode,\n" "+\t\t\t\t \"Missing crypto API support for %s (API name: \\\"%s\\\")\",\n" "+\t\t\t\t mode->friendly_name, mode->cipher_str);\n" @@ -899,7 +900,7 @@ "+\n" "+\t\ttfm = crypto_alloc_shash(\"sha256\", 0, 0);\n" "+\t\tif (IS_ERR(tfm)) {\n" - "+\t\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "+\t\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "+\t\t\t\tfscrypt_warn(NULL,\n" "+\t\t\t\t\t \"Missing crypto API support for SHA-256\");\n" "+\t\t\t\treturn -ENOPKG;\n" @@ -1079,10 +1080,10 @@ "+\tif (res)\n" "+\t\tgoto out;\n" "+\n" - "+\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL)\n" + "+\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL)\n" "+\t\tcrypt_info = NULL;\n" "+out:\n" - "+\tif (res = -ENOKEY)\n" + "+\tif (res == -ENOKEY)\n" "+\t\tres = 0;\n" "+\tput_crypt_info(crypt_info);\n" "+\treturn res;\n" @@ -1447,7 +1448,7 @@ "+\tkey = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX,\n" "+\t\t\t\t\tci->ci_master_key_descriptor,\n" "+\t\t\t\t\tci->ci_mode->keysize, &payload);\n" - "+\tif (key = ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) {\n" + "+\tif (key == ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) {\n" "+\t\tkey = find_and_lock_process_key(ci->ci_inode->i_sb->s_cop->key_prefix,\n" "+\t\t\t\t\t\tci->ci_master_key_descriptor,\n" "+\t\t\t\t\t\tci->ci_mode->keysize, &payload);\n" @@ -1483,6 +1484,13 @@ " {\n" " \treturn -EOPNOTSUPP;\n" "-- \n" - 2.22.0 + "2.22.0\n" + "\n" + "\n" + "\n" + "_______________________________________________\n" + "Linux-f2fs-devel mailing list\n" + "Linux-f2fs-devel@lists.sourceforge.net\n" + https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel -ca570378a56a7ef0262b0af8bdce24814670e3f66d6f5965379466faee44af2f +031ee325f7301cc1d86a93054d6a70cda895dea7c76194a55c125d54625c1031
diff --git a/a/1.txt b/N4/1.txt index e55f236..b8a98cf 100644 --- a/a/1.txt +++ b/N4/1.txt @@ -316,7 +316,7 @@ index 2d45a86f09db2..0000000000000 - key = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX, - ctx->master_key_descriptor, - mode->keysize, &payload); -- if (key = ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) { +- if (key == ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) { - key = find_and_lock_process_key(inode->i_sb->s_cop->key_prefix, - ctx->master_key_descriptor, - mode->keysize, &payload); @@ -330,7 +330,8 @@ index 2d45a86f09db2..0000000000000 - "Direct key mode not allowed with %s", - mode->friendly_name); - err = -EINVAL; -- } else if (ctx->contents_encryption_mode !- ctx->filenames_encryption_mode) { +- } else if (ctx->contents_encryption_mode != +- ctx->filenames_encryption_mode) { - fscrypt_warn(inode, - "Direct key mode not allowed with different contents and filenames modes"); - err = -EINVAL; @@ -357,7 +358,7 @@ index 2d45a86f09db2..0000000000000 - - tfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0); - if (IS_ERR(tfm)) { -- if (PTR_ERR(tfm) = -ENOENT) { +- if (PTR_ERR(tfm) == -ENOENT) { - fscrypt_warn(inode, - "Missing crypto API support for %s (API name: \"%s\")", - mode->friendly_name, mode->cipher_str); @@ -510,7 +511,7 @@ index 2d45a86f09db2..0000000000000 - - tfm = crypto_alloc_shash("sha256", 0, 0); - if (IS_ERR(tfm)) { -- if (PTR_ERR(tfm) = -ENOENT) { +- if (PTR_ERR(tfm) == -ENOENT) { - fscrypt_warn(NULL, - "Missing crypto API support for SHA-256"); - return -ENOPKG; @@ -710,10 +711,10 @@ index 2d45a86f09db2..0000000000000 - if (res) - goto out; - -- if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL) +- if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL) - crypt_info = NULL; -out: -- if (res = -ENOKEY) +- if (res == -ENOKEY) - res = 0; - put_crypt_info(crypt_info); - kzfree(raw_key); @@ -838,7 +839,7 @@ index 0000000000000..479128998ae7a + + tfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0); + if (IS_ERR(tfm)) { -+ if (PTR_ERR(tfm) = -ENOENT) { ++ if (PTR_ERR(tfm) == -ENOENT) { + fscrypt_warn(inode, + "Missing crypto API support for %s (API name: \"%s\")", + mode->friendly_name, mode->cipher_str); @@ -883,7 +884,7 @@ index 0000000000000..479128998ae7a + + tfm = crypto_alloc_shash("sha256", 0, 0); + if (IS_ERR(tfm)) { -+ if (PTR_ERR(tfm) = -ENOENT) { ++ if (PTR_ERR(tfm) == -ENOENT) { + fscrypt_warn(NULL, + "Missing crypto API support for SHA-256"); + return -ENOPKG; @@ -1063,10 +1064,10 @@ index 0000000000000..479128998ae7a + if (res) + goto out; + -+ if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL) ++ if (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL) + crypt_info = NULL; +out: -+ if (res = -ENOKEY) ++ if (res == -ENOKEY) + res = 0; + put_crypt_info(crypt_info); + return res; @@ -1431,7 +1432,7 @@ index 0000000000000..b3c06322afa3c + key = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX, + ci->ci_master_key_descriptor, + ci->ci_mode->keysize, &payload); -+ if (key = ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) { ++ if (key == ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) { + key = find_and_lock_process_key(ci->ci_inode->i_sb->s_cop->key_prefix, + ci->ci_master_key_descriptor, + ci->ci_mode->keysize, &payload); @@ -1468,3 +1469,8 @@ index 81c0c754f8b21..583802cb2e35d 100644 return -EOPNOTSUPP; -- 2.22.0 + + +______________________________________________________ +Linux MTD discussion mailing list +http://lists.infradead.org/mailman/listinfo/linux-mtd/ diff --git a/a/content_digest b/N4/content_digest index 6ef78de..d8de0dc 100644 --- a/a/content_digest +++ b/N4/content_digest @@ -1,7 +1,7 @@ "ref\020190726224141.14044-1-ebiggers@kernel.org\0" "From\0Eric Biggers <ebiggers@kernel.org>\0" "Subject\0[PATCH v7 05/16] fscrypt: refactor v1 policy key setup into keysetup_legacy.c\0" - "Date\0Fri, 26 Jul 2019 22:41:30 +0000\0" + "Date\0Fri, 26 Jul 2019 15:41:30 -0700\0" "To\0linux-fscrypt@vger.kernel.org\0" "Cc\0Satya Tangirala <satyat@google.com>" linux-api@vger.kernel.org @@ -332,7 +332,7 @@ "-\tkey = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX,\n" "-\t\t\t\t\tctx->master_key_descriptor,\n" "-\t\t\t\t\tmode->keysize, &payload);\n" - "-\tif (key = ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) {\n" + "-\tif (key == ERR_PTR(-ENOKEY) && inode->i_sb->s_cop->key_prefix) {\n" "-\t\tkey = find_and_lock_process_key(inode->i_sb->s_cop->key_prefix,\n" "-\t\t\t\t\t\tctx->master_key_descriptor,\n" "-\t\t\t\t\t\tmode->keysize, &payload);\n" @@ -346,7 +346,8 @@ "-\t\t\t\t \"Direct key mode not allowed with %s\",\n" "-\t\t\t\t mode->friendly_name);\n" "-\t\t\terr = -EINVAL;\n" - "-\t\t} else if (ctx->contents_encryption_mode !-\t\t\t ctx->filenames_encryption_mode) {\n" + "-\t\t} else if (ctx->contents_encryption_mode !=\n" + "-\t\t\t ctx->filenames_encryption_mode) {\n" "-\t\t\tfscrypt_warn(inode,\n" "-\t\t\t\t \"Direct key mode not allowed with different contents and filenames modes\");\n" "-\t\t\terr = -EINVAL;\n" @@ -373,7 +374,7 @@ "-\n" "-\ttfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0);\n" "-\tif (IS_ERR(tfm)) {\n" - "-\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "-\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "-\t\t\tfscrypt_warn(inode,\n" "-\t\t\t\t \"Missing crypto API support for %s (API name: \\\"%s\\\")\",\n" "-\t\t\t\t mode->friendly_name, mode->cipher_str);\n" @@ -526,7 +527,7 @@ "-\n" "-\t\ttfm = crypto_alloc_shash(\"sha256\", 0, 0);\n" "-\t\tif (IS_ERR(tfm)) {\n" - "-\t\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "-\t\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "-\t\t\t\tfscrypt_warn(NULL,\n" "-\t\t\t\t\t \"Missing crypto API support for SHA-256\");\n" "-\t\t\t\treturn -ENOPKG;\n" @@ -726,10 +727,10 @@ "-\tif (res)\n" "-\t\tgoto out;\n" "-\n" - "-\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL)\n" + "-\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL)\n" "-\t\tcrypt_info = NULL;\n" "-out:\n" - "-\tif (res = -ENOKEY)\n" + "-\tif (res == -ENOKEY)\n" "-\t\tres = 0;\n" "-\tput_crypt_info(crypt_info);\n" "-\tkzfree(raw_key);\n" @@ -854,7 +855,7 @@ "+\n" "+\ttfm = crypto_alloc_skcipher(mode->cipher_str, 0, 0);\n" "+\tif (IS_ERR(tfm)) {\n" - "+\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "+\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "+\t\t\tfscrypt_warn(inode,\n" "+\t\t\t\t \"Missing crypto API support for %s (API name: \\\"%s\\\")\",\n" "+\t\t\t\t mode->friendly_name, mode->cipher_str);\n" @@ -899,7 +900,7 @@ "+\n" "+\t\ttfm = crypto_alloc_shash(\"sha256\", 0, 0);\n" "+\t\tif (IS_ERR(tfm)) {\n" - "+\t\t\tif (PTR_ERR(tfm) = -ENOENT) {\n" + "+\t\t\tif (PTR_ERR(tfm) == -ENOENT) {\n" "+\t\t\t\tfscrypt_warn(NULL,\n" "+\t\t\t\t\t \"Missing crypto API support for SHA-256\");\n" "+\t\t\t\treturn -ENOPKG;\n" @@ -1079,10 +1080,10 @@ "+\tif (res)\n" "+\t\tgoto out;\n" "+\n" - "+\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) = NULL)\n" + "+\tif (cmpxchg_release(&inode->i_crypt_info, NULL, crypt_info) == NULL)\n" "+\t\tcrypt_info = NULL;\n" "+out:\n" - "+\tif (res = -ENOKEY)\n" + "+\tif (res == -ENOKEY)\n" "+\t\tres = 0;\n" "+\tput_crypt_info(crypt_info);\n" "+\treturn res;\n" @@ -1447,7 +1448,7 @@ "+\tkey = find_and_lock_process_key(FSCRYPT_KEY_DESC_PREFIX,\n" "+\t\t\t\t\tci->ci_master_key_descriptor,\n" "+\t\t\t\t\tci->ci_mode->keysize, &payload);\n" - "+\tif (key = ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) {\n" + "+\tif (key == ERR_PTR(-ENOKEY) && ci->ci_inode->i_sb->s_cop->key_prefix) {\n" "+\t\tkey = find_and_lock_process_key(ci->ci_inode->i_sb->s_cop->key_prefix,\n" "+\t\t\t\t\t\tci->ci_master_key_descriptor,\n" "+\t\t\t\t\t\tci->ci_mode->keysize, &payload);\n" @@ -1483,6 +1484,11 @@ " {\n" " \treturn -EOPNOTSUPP;\n" "-- \n" - 2.22.0 + "2.22.0\n" + "\n" + "\n" + "______________________________________________________\n" + "Linux MTD discussion mailing list\n" + http://lists.infradead.org/mailman/listinfo/linux-mtd/ -ca570378a56a7ef0262b0af8bdce24814670e3f66d6f5965379466faee44af2f +8b81c58e2729c7ca6c11a23136c38f9b038c1e48b64e2de896aebe7e10191623
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.