Lines Matching defs:ret
127 int ret;
132 ret = mpi_powm(val, y, ctx->q, ctx->p);
134 if (ret) {
136 return ret;
139 ret = mpi_cmp_ui(val, 1);
143 if (ret != 0)
155 int ret = 0;
162 ret = -EINVAL;
169 ret = -EINVAL;
172 ret = dh_is_pubkey_valid(ctx, base);
173 if (ret)
179 ret = _compute_val(ctx, base, val);
180 if (ret)
190 ret = -EBADMSG;
198 ret = -ENOMEM;
202 ret = mpi_sub_ui(pone, ctx->p, 1);
203 if (!ret && !mpi_cmp(pone, val))
204 ret = -EBADMSG;
208 if (ret)
214 ret = -EAGAIN;
220 ret = mpi_write_to_sgl(val, req->dst, req->dst_len, &sign);
221 if (ret)
225 ret = -EBADMSG;
231 return ret;