Lines Matching refs:pk

113 	struct pkey_protkey pk;  member
120 struct pkey_protkey pk[2]; member
126 struct pkey_protkey *pk) in __paes_keyblob2pkey() argument
135 ret = pkey_keyblob2pkey(kb->key, kb->keylen, pk); in __paes_keyblob2pkey()
153 memcpy(&ctx->pk, &pkey, sizeof(pkey)); in __paes_convert_key()
186 fc = (ctx->pk.type == PKEY_KEYTYPE_AES_128) ? CPACF_KM_PAES_128 : in __ecb_paes_set_key()
187 (ctx->pk.type == PKEY_KEYTYPE_AES_192) ? CPACF_KM_PAES_192 : in __ecb_paes_set_key()
188 (ctx->pk.type == PKEY_KEYTYPE_AES_256) ? CPACF_KM_PAES_256 : 0; in __ecb_paes_set_key()
226 memcpy(param.key, ctx->pk.protkey, MAXPROTKEYSIZE); in ecb_paes_crypt()
240 memcpy(param.key, ctx->pk.protkey, MAXPROTKEYSIZE); in ecb_paes_crypt()
301 fc = (ctx->pk.type == PKEY_KEYTYPE_AES_128) ? CPACF_KMC_PAES_128 : in __cbc_paes_set_key()
302 (ctx->pk.type == PKEY_KEYTYPE_AES_192) ? CPACF_KMC_PAES_192 : in __cbc_paes_set_key()
303 (ctx->pk.type == PKEY_KEYTYPE_AES_256) ? CPACF_KMC_PAES_256 : 0; in __cbc_paes_set_key()
343 memcpy(param.key, ctx->pk.protkey, MAXPROTKEYSIZE); in cbc_paes_crypt()
359 memcpy(param.key, ctx->pk.protkey, MAXPROTKEYSIZE); in cbc_paes_crypt()
422 memcpy(&ctx->pk[0], &pkey0, sizeof(pkey0)); in __xts_paes_convert_key()
423 memcpy(&ctx->pk[1], &pkey1, sizeof(pkey1)); in __xts_paes_convert_key()
436 if (ctx->pk[0].type != ctx->pk[1].type) in __xts_paes_set_key()
440 fc = (ctx->pk[0].type == PKEY_KEYTYPE_AES_128) ? CPACF_KM_PXTS_128 : in __xts_paes_set_key()
441 (ctx->pk[0].type == PKEY_KEYTYPE_AES_256) ? in __xts_paes_set_key()
481 ckey_len = (ctx->pk[0].type == PKEY_KEYTYPE_AES_128) ? in xts_paes_set_key()
483 memcpy(ckey, ctx->pk[0].protkey, ckey_len); in xts_paes_set_key()
484 memcpy(ckey + ckey_len, ctx->pk[1].protkey, ckey_len); in xts_paes_set_key()
511 keylen = (ctx->pk[0].type == PKEY_KEYTYPE_AES_128) ? 48 : 64; in xts_paes_crypt()
512 offset = (ctx->pk[0].type == PKEY_KEYTYPE_AES_128) ? 16 : 0; in xts_paes_crypt()
517 memcpy(pcc_param.key + offset, ctx->pk[1].protkey, keylen); in xts_paes_crypt()
518 memcpy(xts_param.key + offset, ctx->pk[0].protkey, keylen); in xts_paes_crypt()
535 ctx->pk[0].protkey, keylen); in xts_paes_crypt()
598 fc = (ctx->pk.type == PKEY_KEYTYPE_AES_128) ? CPACF_KMCTR_PAES_128 : in __ctr_paes_set_key()
599 (ctx->pk.type == PKEY_KEYTYPE_AES_192) ? CPACF_KMCTR_PAES_192 : in __ctr_paes_set_key()
600 (ctx->pk.type == PKEY_KEYTYPE_AES_256) ? in __ctr_paes_set_key()
655 memcpy(param.key, ctx->pk.protkey, MAXPROTKEYSIZE); in ctr_paes_crypt()
681 memcpy(param.key, ctx->pk.protkey, MAXPROTKEYSIZE); in ctr_paes_crypt()
699 memcpy(param.key, ctx->pk.protkey, MAXPROTKEYSIZE); in ctr_paes_crypt()