Pull crypto fixes from Herbert Xu: "This fixes the following issues: - a crash regression in the new skcipher walker - incorrect return value in public_key_verify_signature - fix for in-place signing in the sign-file utility" * 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: crypto: skcipher - fix crash in virtual walk sign-file: Fix inplace signing when src and dst names are both specified crypto: asymmetric_keys - set error code on failure
Unified · Split
| @@ -121,6 +121,7 @@ int public_key_verify_signature(const struct public_key *pkey, · 120 unmodified lines | ||
| 121 | 121 | if (ret) |
| 122 | 122 | goto error_free_req; |
| 123 | 123 | |
| 124 | + ret = -ENOMEM; | |
| 124 | 125 | outlen = crypto_akcipher_maxsize(tfm); |
| 125 | 126 | output = kmalloc(outlen, GFP_KERNEL); |
| 126 | 127 | if (!output) |
| @@ -226,7 +226,9 @@ static int skcipher_next_slow(struct skcipher_walk *walk, unsigned int bsize) · 225 unmodified lines | ||
| 226 | 226 | void *v; |
| 227 | 227 | |
| 228 | 228 | if (!phys) { |
| 229 | − buffer = walk->buffer ?: walk->page; | |
| 229 | + if (!walk->buffer) | |
| 230 | + walk->buffer = walk->page; | |
| 231 | + buffer = walk->buffer; | |
| 230 | 232 | if (buffer) |
| 231 | 233 | goto ok; |
| 232 | 234 | } |
| @@ -267,7 +267,7 @@ int main(int argc, char **argv) · 266 unmodified lines | ||
| 267 | 267 | } |
| 268 | 268 | x509_name = argv[2]; |
| 269 | 269 | module_name = argv[3]; |
| 270 | − if (argc == 5) { | |
| 270 | + if (argc == 5 && strcmp(argv[3], argv[4]) != 0) { | |
| 271 | 271 | dest_name = argv[4]; |
| 272 | 272 | replace_orig = false; |
| 273 | 273 | } else { |