Lines Matching refs:ret
59 int ret = 0; in rsa_enc() local
66 ret = -EINVAL; in rsa_enc()
70 ret = -ENOMEM; in rsa_enc()
75 ret = _rsa_enc(pkey, c, m); in rsa_enc()
76 if (ret) in rsa_enc()
79 ret = mpi_write_to_sgl(c, req->dst, req->dst_len, &sign); in rsa_enc()
80 if (ret) in rsa_enc()
84 ret = -EBADMSG; in rsa_enc()
90 return ret; in rsa_enc()
98 int ret = 0; in rsa_dec() local
105 ret = -EINVAL; in rsa_dec()
109 ret = -ENOMEM; in rsa_dec()
114 ret = _rsa_dec(pkey, m, c); in rsa_dec()
115 if (ret) in rsa_dec()
118 ret = mpi_write_to_sgl(m, req->dst, req->dst_len, &sign); in rsa_dec()
119 if (ret) in rsa_dec()
123 ret = -EBADMSG; in rsa_dec()
128 return ret; in rsa_dec()
161 int ret; in rsa_set_pub_key() local
166 ret = rsa_parse_pub_key(&raw_key, key, keylen); in rsa_set_pub_key()
167 if (ret) in rsa_set_pub_key()
168 return ret; in rsa_set_pub_key()
195 int ret; in rsa_set_priv_key() local
200 ret = rsa_parse_priv_key(&raw_key, key, keylen); in rsa_set_priv_key()
201 if (ret) in rsa_set_priv_key()
202 return ret; in rsa_set_priv_key()