| .. | .. |
|---|
| 17 | 17 | |
|---|
| 18 | 18 | #include "sha.h" |
|---|
| 19 | 19 | |
|---|
| 20 | | -static int sha256_init(struct shash_desc *desc) |
|---|
| 20 | +static int s390_sha256_init(struct shash_desc *desc) |
|---|
| 21 | 21 | { |
|---|
| 22 | 22 | struct s390_sha_ctx *sctx = shash_desc_ctx(desc); |
|---|
| 23 | 23 | |
|---|
| .. | .. |
|---|
| 60 | 60 | |
|---|
| 61 | 61 | static struct shash_alg sha256_alg = { |
|---|
| 62 | 62 | .digestsize = SHA256_DIGEST_SIZE, |
|---|
| 63 | | - .init = sha256_init, |
|---|
| 63 | + .init = s390_sha256_init, |
|---|
| 64 | 64 | .update = s390_sha_update, |
|---|
| 65 | 65 | .final = s390_sha_final, |
|---|
| 66 | 66 | .export = sha256_export, |
|---|
| .. | .. |
|---|
| 76 | 76 | } |
|---|
| 77 | 77 | }; |
|---|
| 78 | 78 | |
|---|
| 79 | | -static int sha224_init(struct shash_desc *desc) |
|---|
| 79 | +static int s390_sha224_init(struct shash_desc *desc) |
|---|
| 80 | 80 | { |
|---|
| 81 | 81 | struct s390_sha_ctx *sctx = shash_desc_ctx(desc); |
|---|
| 82 | 82 | |
|---|
| .. | .. |
|---|
| 96 | 96 | |
|---|
| 97 | 97 | static struct shash_alg sha224_alg = { |
|---|
| 98 | 98 | .digestsize = SHA224_DIGEST_SIZE, |
|---|
| 99 | | - .init = sha224_init, |
|---|
| 99 | + .init = s390_sha224_init, |
|---|
| 100 | 100 | .update = s390_sha_update, |
|---|
| 101 | 101 | .final = s390_sha_final, |
|---|
| 102 | 102 | .export = sha256_export, |
|---|
| .. | .. |
|---|
| 117 | 117 | int ret; |
|---|
| 118 | 118 | |
|---|
| 119 | 119 | if (!cpacf_query_func(CPACF_KIMD, CPACF_KIMD_SHA_256)) |
|---|
| 120 | | - return -EOPNOTSUPP; |
|---|
| 120 | + return -ENODEV; |
|---|
| 121 | 121 | ret = crypto_register_shash(&sha256_alg); |
|---|
| 122 | 122 | if (ret < 0) |
|---|
| 123 | 123 | goto out; |
|---|