Home
last modified time | relevance | path

Searched refs:mex (Results 1 – 4 of 4) sorted by relevance

/linux/drivers/s390/crypto/
H A Dzcrypt_cca_key.h99 static inline int zcrypt_type6_mex_key_en(struct ica_rsa_modexpo *mex, void *p) in zcrypt_type6_mex_key_en() argument
121 if (WARN_ON_ONCE(mex->inputdatalength > 512)) in zcrypt_type6_mex_key_en()
131 if (copy_from_user(ptr, mex->b_key, mex->inputdatalength)) in zcrypt_type6_mex_key_en()
133 ptr += mex->inputdatalength; in zcrypt_type6_mex_key_en()
135 if (copy_from_user(ptr, mex->n_modulus, mex->inputdatalength)) in zcrypt_type6_mex_key_en()
138 key->pubsec.modulus_bit_len = 8 * mex->inputdatalength; in zcrypt_type6_mex_key_en()
139 key->pubsec.modulus_byte_len = mex->inputdatalength; in zcrypt_type6_mex_key_en()
140 key->pubsec.exponent_len = mex->inputdatalength; in zcrypt_type6_mex_key_en()
142 2 * mex->inputdatalength; in zcrypt_type6_mex_key_en()
148 return sizeof(*key) + 2 * mex->inputdatalength; in zcrypt_type6_mex_key_en()
H A Dzcrypt_msgtype6.c191 struct ica_rsa_modexpo *mex) in icamex_msg_to_type6mex_msgx() argument
218 if (WARN_ON_ONCE(mex->inputdatalength > PAGE_SIZE)) in icamex_msg_to_type6mex_msgx()
222 msg->length = mex->inputdatalength + 2; in icamex_msg_to_type6mex_msgx()
223 if (copy_from_user(msg->text, mex->inputdata, mex->inputdatalength)) in icamex_msg_to_type6mex_msgx()
227 size = zcrypt_type6_mex_key_en(mex, msg->text + mex->inputdatalength); in icamex_msg_to_type6mex_msgx()
230 size += sizeof(*msg) + mex->inputdatalength; in icamex_msg_to_type6mex_msgx()
1041 struct ica_rsa_modexpo *mex, in zcrypt_msgtype6_modexpo() argument
1050 rc = icamex_msg_to_type6mex_msgx(zq, ap_msg, mex); in zcrypt_msgtype6_modexpo()
1063 mex->outputdata, in zcrypt_msgtype6_modexpo()
1064 mex->outputdatalength); in zcrypt_msgtype6_modexpo()
H A Dzcrypt_api.c642 struct ica_rsa_modexpo *mex) in zcrypt_rsa_modexpo() argument
652 trace_s390_zcrypt_req(mex, TP_ICARSAMODEXPO); in zcrypt_rsa_modexpo()
658 if (mex->outputdatalength < mex->inputdatalength) { in zcrypt_rsa_modexpo()
668 mex->outputdatalength = mex->inputdatalength; in zcrypt_rsa_modexpo()
670 rc = get_rsa_modex_fc(mex, &func_code); in zcrypt_rsa_modexpo()
683 if (zc->min_mod_size > mex->inputdatalength || in zcrypt_rsa_modexpo()
684 zc->max_mod_size < mex->inputdatalength) in zcrypt_rsa_modexpo()
728 rc = pref_zq->ops->rsa_modexpo(pref_zq, mex, &ap_msg); in zcrypt_rsa_modexpo()
740 trace_s390_zcrypt_rep(mex, func_code, rc, in zcrypt_rsa_modexpo()
1484 struct ica_rsa_modexpo mex; in icarsamodexpo_ioctl() local
[all …]
H A Dzcrypt_msgtype50.h22 int get_rsa_modex_fc(struct ica_rsa_modexpo *mex, int *fc);