Lines Matching refs:req_ctx

1582 	struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq);  in common_nonsnoop_hash_unmap()  local
1595 talitos_sg_unmap(dev, edesc, req_ctx->psrc, NULL); in common_nonsnoop_hash_unmap()
1610 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_done() local
1612 if (!req_ctx->last && req_ctx->to_hash_later) { in ahash_done()
1614 memcpy(req_ctx->buf, req_ctx->bufnext, req_ctx->to_hash_later); in ahash_done()
1615 req_ctx->nbuf = req_ctx->to_hash_later; in ahash_done()
1632 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in common_nonsnoop_hash() local
1641 if (!req_ctx->first || req_ctx->swinit) { in common_nonsnoop_hash()
1643 req_ctx->hw_context_size, in common_nonsnoop_hash()
1644 (char *)req_ctx->hw_context, 0, in common_nonsnoop_hash()
1646 req_ctx->swinit = 0; in common_nonsnoop_hash()
1650 req_ctx->first = 0; in common_nonsnoop_hash()
1666 sg_count = talitos_map_sg(dev, req_ctx->psrc, in common_nonsnoop_hash()
1672 to_talitos_ptr(&desc->ptr[3], sg_dma_address(req_ctx->psrc)); in common_nonsnoop_hash()
1674 sg_count = sg_to_link_tbl(req_ctx->psrc, sg_count, length, in common_nonsnoop_hash()
1686 sg_dma_address(req_ctx->psrc)); in common_nonsnoop_hash()
1694 if (req_ctx->last) in common_nonsnoop_hash()
1700 req_ctx->hw_context_size, in common_nonsnoop_hash()
1701 req_ctx->hw_context, 0, DMA_FROM_DEVICE); in common_nonsnoop_hash()
1719 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_edesc_alloc() local
1721 return talitos_edesc_alloc(ctx->dev, req_ctx->psrc, NULL, 1, in ahash_edesc_alloc()
1728 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_init() local
1731 req_ctx->nbuf = 0; in ahash_init()
1732 req_ctx->first = 1; /* first indicates h/w must init its context */ in ahash_init()
1733 req_ctx->swinit = 0; /* assume h/w init of context */ in ahash_init()
1734 req_ctx->hw_context_size = in ahash_init()
1748 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_init_sha224_swinit() local
1751 req_ctx->swinit = 1;/* prevent h/w initting context with sha256 values*/ in ahash_init_sha224_swinit()
1753 req_ctx->hw_context[0] = SHA224_H0; in ahash_init_sha224_swinit()
1754 req_ctx->hw_context[1] = SHA224_H1; in ahash_init_sha224_swinit()
1755 req_ctx->hw_context[2] = SHA224_H2; in ahash_init_sha224_swinit()
1756 req_ctx->hw_context[3] = SHA224_H3; in ahash_init_sha224_swinit()
1757 req_ctx->hw_context[4] = SHA224_H4; in ahash_init_sha224_swinit()
1758 req_ctx->hw_context[5] = SHA224_H5; in ahash_init_sha224_swinit()
1759 req_ctx->hw_context[6] = SHA224_H6; in ahash_init_sha224_swinit()
1760 req_ctx->hw_context[7] = SHA224_H7; in ahash_init_sha224_swinit()
1763 req_ctx->hw_context[8] = 0; in ahash_init_sha224_swinit()
1764 req_ctx->hw_context[9] = 0; in ahash_init_sha224_swinit()
1773 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_process_req() local
1782 if (!req_ctx->last && (nbytes + req_ctx->nbuf <= blocksize)) { in ahash_process_req()
1786 req_ctx->buf + req_ctx->nbuf, nbytes); in ahash_process_req()
1787 req_ctx->nbuf += nbytes; in ahash_process_req()
1792 nbytes_to_hash = nbytes + req_ctx->nbuf; in ahash_process_req()
1795 if (req_ctx->last) in ahash_process_req()
1807 if (req_ctx->nbuf) { in ahash_process_req()
1808 nsg = (req_ctx->nbuf < nbytes_to_hash) ? 2 : 1; in ahash_process_req()
1809 sg_init_table(req_ctx->bufsl, nsg); in ahash_process_req()
1810 sg_set_buf(req_ctx->bufsl, req_ctx->buf, req_ctx->nbuf); in ahash_process_req()
1812 scatterwalk_sg_chain(req_ctx->bufsl, 2, areq->src); in ahash_process_req()
1813 req_ctx->psrc = req_ctx->bufsl; in ahash_process_req()
1815 req_ctx->psrc = areq->src; in ahash_process_req()
1820 req_ctx->bufnext, in ahash_process_req()
1824 req_ctx->to_hash_later = to_hash_later; in ahash_process_req()
1834 if (req_ctx->last) in ahash_process_req()
1840 if (req_ctx->first && !req_ctx->swinit) in ahash_process_req()
1846 if (ctx->keylen && (req_ctx->first || req_ctx->last)) in ahash_process_req()
1855 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_update() local
1857 req_ctx->last = 0; in ahash_update()
1864 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_final() local
1866 req_ctx->last = 1; in ahash_final()
1873 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_finup() local
1875 req_ctx->last = 1; in ahash_finup()
1882 struct talitos_ahash_req_ctx *req_ctx = ahash_request_ctx(areq); in ahash_digest() local
1886 req_ctx->last = 1; in ahash_digest()