Lines Matching refs:cipher_sz
910 const struct tls_cipher_size_desc *cipher_sz; in tls_device_reencrypt() local
924 cipher_sz = &tls_cipher_size_desc[tls_ctx->crypto_recv.info.cipher_type]; in tls_device_reencrypt()
927 orig_buf = kmalloc(rxm->full_len + TLS_HEADER_SIZE + cipher_sz->iv, in tls_device_reencrypt()
943 rxm->full_len + TLS_HEADER_SIZE + cipher_sz->iv); in tls_device_reencrypt()
944 err = skb_copy_bits(skb, offset, buf, TLS_HEADER_SIZE + cipher_sz->iv); in tls_device_reencrypt()
955 data_len = rxm->full_len - cipher_sz->tag; in tls_device_reencrypt()
1078 const struct tls_cipher_size_desc *cipher_sz; in tls_set_device_offload() local
1126 cipher_sz = &tls_cipher_size_desc[crypto_info->cipher_type]; in tls_set_device_offload()
1129 if (cipher_sz->rec_seq > TLS_MAX_REC_SEQ_SIZE) { in tls_set_device_offload()
1136 prot->prepend_size = TLS_HEADER_SIZE + cipher_sz->iv; in tls_set_device_offload()
1137 prot->tag_size = cipher_sz->tag; in tls_set_device_offload()
1139 prot->iv_size = cipher_sz->iv; in tls_set_device_offload()
1140 prot->salt_size = cipher_sz->salt; in tls_set_device_offload()
1141 ctx->tx.iv = kmalloc(cipher_sz->iv + cipher_sz->salt, GFP_KERNEL); in tls_set_device_offload()
1147 memcpy(ctx->tx.iv + cipher_sz->salt, iv, cipher_sz->iv); in tls_set_device_offload()
1149 prot->rec_seq_size = cipher_sz->rec_seq; in tls_set_device_offload()
1150 ctx->tx.rec_seq = kmemdup(rec_seq, cipher_sz->rec_seq, GFP_KERNEL); in tls_set_device_offload()