Lines Matching refs:req_ctx
1569 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(req);
1583 unsigned int rx_channel_id = req_ctx->rxqidx / ctx->rxq_perchan;
1587 req_ctx->hctx_wr.imm = (transhdr_len + param->bfr_len +
1589 nents = sg_nents_xlen(req_ctx->hctx_wr.srcsg, param->sg_len,
1590 CHCR_SRC_SG_SIZE, req_ctx->hctx_wr.src_ofst);
1592 transhdr_len += req_ctx->hctx_wr.imm ? roundup(param->bfr_len +
1617 memcpy(chcr_req->key_ctx.key, req_ctx->partial_hash,
1635 req_ctx->hctx_wr.dma_addr =
1636 dma_map_single(&u_ctx->lldi.pdev->dev, req_ctx->reqbfr,
1639 req_ctx->hctx_wr. dma_addr)) {
1643 req_ctx->hctx_wr.dma_len = param->bfr_len;
1645 req_ctx->hctx_wr.dma_addr = 0;
1649 temp = param->kctx_len + DUMMY_BYTES + (req_ctx->hctx_wr.imm ?
1652 create_wreq(h_ctx(tfm), chcr_req, &req->base, req_ctx->hctx_wr.imm,
1655 req_ctx->hctx_wr.skb = skb;
1664 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(req);
1677 req_ctx->txqidx = cpu % ctx->ntxq;
1678 req_ctx->rxqidx = cpu % ctx->nrxq;
1683 if (nbytes + req_ctx->reqlen >= bs) {
1684 remainder = (nbytes + req_ctx->reqlen) % bs;
1685 nbytes = nbytes + req_ctx->reqlen - remainder;
1687 sg_pcopy_to_buffer(req->src, sg_nents(req->src), req_ctx->reqbfr
1688 + req_ctx->reqlen, nbytes, 0);
1689 req_ctx->reqlen += nbytes;
1699 req_ctx->txqidx) &&
1705 chcr_init_hctx_per_wr(req_ctx);
1713 params.sg_len = chcr_hash_ent_in_wr(req->src, !!req_ctx->reqlen,
1717 params.sg_len = rounddown(params.sg_len + req_ctx->reqlen, bs) -
1718 req_ctx->reqlen;
1722 params.bfr_len = req_ctx->reqlen;
1724 req_ctx->hctx_wr.srcsg = req->src;
1727 req_ctx->data_len += params.sg_len + params.bfr_len;
1734 req_ctx->hctx_wr.processed += params.sg_len;
1737 swap(req_ctx->reqbfr, req_ctx->skbfr);
1739 req_ctx->reqbfr, remainder, req->nbytes -
1742 req_ctx->reqlen = remainder;
1744 set_wr_txq(skb, CPL_PRIORITY_DATA, req_ctx->txqidx);
1766 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(req);
1778 req_ctx->txqidx = cpu % ctx->ntxq;
1779 req_ctx->rxqidx = cpu % ctx->nrxq;
1786 chcr_init_hctx_per_wr(req_ctx);
1792 req_ctx->hctx_wr.isfinal = 1;
1802 req_ctx->hctx_wr.result = 1;
1803 params.bfr_len = req_ctx->reqlen;
1804 req_ctx->data_len += params.bfr_len + params.sg_len;
1805 req_ctx->hctx_wr.srcsg = req->src;
1806 if (req_ctx->reqlen == 0) {
1807 create_last_hash_block(req_ctx->reqbfr, bs, req_ctx->data_len);
1814 params.scmd1 = req_ctx->data_len;
1824 req_ctx->reqlen = 0;
1826 set_wr_txq(skb, CPL_PRIORITY_DATA, req_ctx->txqidx);
1836 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(req);
1848 req_ctx->txqidx = cpu % ctx->ntxq;
1849 req_ctx->rxqidx = cpu % ctx->nrxq;
1858 req_ctx->txqidx) &&
1863 chcr_init_hctx_per_wr(req_ctx);
1879 params.sg_len = chcr_hash_ent_in_wr(req->src, !!req_ctx->reqlen,
1888 params.sg_len = rounddown(params.sg_len + req_ctx->reqlen, bs)
1889 - req_ctx->reqlen;
1897 params.scmd1 = req_ctx->data_len + req_ctx->reqlen +
1900 params.bfr_len = req_ctx->reqlen;
1901 req_ctx->data_len += params.bfr_len + params.sg_len;
1902 req_ctx->hctx_wr.result = 1;
1903 req_ctx->hctx_wr.srcsg = req->src;
1904 if ((req_ctx->reqlen + req->nbytes) == 0) {
1905 create_last_hash_block(req_ctx->reqbfr, bs, req_ctx->data_len);
1916 req_ctx->reqlen = 0;
1917 req_ctx->hctx_wr.processed += params.sg_len;
1919 set_wr_txq(skb, CPL_PRIORITY_DATA, req_ctx->txqidx);
1931 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(req);
1943 req_ctx->txqidx = cpu % ctx->ntxq;
1944 req_ctx->rxqidx = cpu % ctx->nrxq;
1954 req_ctx->txqidx) &&
1960 chcr_init_hctx_per_wr(req_ctx);
1975 params.sg_len = chcr_hash_ent_in_wr(req->src, !!req_ctx->reqlen,
1992 params.scmd1 = req->nbytes + req_ctx->data_len;
1996 req_ctx->hctx_wr.result = 1;
1997 req_ctx->hctx_wr.srcsg = req->src;
1998 req_ctx->data_len += params.bfr_len + params.sg_len;
2001 create_last_hash_block(req_ctx->reqbfr, bs, req_ctx->data_len);
2011 req_ctx->hctx_wr.processed += params.sg_len;
2013 set_wr_txq(skb, CPL_PRIORITY_DATA, req_ctx->txqidx);
2172 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(areq);
2175 state->reqlen = req_ctx->reqlen;
2176 state->data_len = req_ctx->data_len;
2177 memcpy(state->bfr1, req_ctx->reqbfr, req_ctx->reqlen);
2178 memcpy(state->partial_hash, req_ctx->partial_hash,
2186 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(areq);
2189 req_ctx->reqlen = state->reqlen;
2190 req_ctx->data_len = state->data_len;
2191 req_ctx->reqbfr = req_ctx->bfr1;
2192 req_ctx->skbfr = req_ctx->bfr2;
2193 memcpy(req_ctx->bfr1, state->bfr1, CHCR_HASH_MAX_BLOCK_SIZE_128);
2194 memcpy(req_ctx->partial_hash, state->partial_hash,
2196 chcr_init_hctx_per_wr(req_ctx);
2299 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(areq);
2303 req_ctx->data_len = 0;
2304 req_ctx->reqlen = 0;
2305 req_ctx->reqbfr = req_ctx->bfr1;
2306 req_ctx->skbfr = req_ctx->bfr2;
2307 copy_hash_init_values(req_ctx->partial_hash, digestsize);
2321 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(areq);
2328 req_ctx->data_len = bs;
2331 memcpy(req_ctx->partial_hash, hmacctx->ipad,
2334 memcpy(req_ctx->partial_hash, hmacctx->ipad,
2337 memcpy(req_ctx->partial_hash, hmacctx->ipad,
2809 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(req);
2818 req_ctx->hctx_wr.is_sg_map = 1;
2825 struct chcr_ahash_req_ctx *req_ctx = ahash_request_ctx(req);
2832 req_ctx->hctx_wr.is_sg_map = 0;