Lines Matching refs:sg
83 struct scatterlist *sg; /* sg list head for this update*/ member
105 struct scatterlist *sg = NULL; in sg_get() local
108 for_each_sg(sg_list, sg, nents, i) in sg_get()
112 return sg; in sg_get()
167 struct scatterlist *sg; in bfin_crypto_crc_config_dma() local
176 dma_map_sg(crc->dev, ctx->sg, ctx->sg_nents, DMA_TO_DEVICE); in bfin_crypto_crc_config_dma()
178 for_each_sg(ctx->sg, sg, ctx->sg_nents, j) { in bfin_crypto_crc_config_dma()
179 dma_addr = sg_dma_address(sg); in bfin_crypto_crc_config_dma()
181 if (sg_is_last(sg)) in bfin_crypto_crc_config_dma()
182 dma_count = sg_dma_len(sg) - ctx->bufnext_len; in bfin_crypto_crc_config_dma()
184 dma_count = sg_dma_len(sg); in bfin_crypto_crc_config_dma()
192 sg_virt(sg), in bfin_crypto_crc_config_dma()
245 (u8*)sg_virt(sg) + (dma_count << 2), in bfin_crypto_crc_config_dma()
284 struct scatterlist *sg; in bfin_crypto_crc_handle_queue() local
313 ctx->sg = NULL; in bfin_crypto_crc_handle_queue()
354 ctx->sg = ctx->bufsl; in bfin_crypto_crc_handle_queue()
356 ctx->sg = req->src; in bfin_crypto_crc_handle_queue()
359 nsg = sg_nents(ctx->sg); in bfin_crypto_crc_handle_queue()
370 sg = sg_get(ctx->sg, nsg, i); in bfin_crypto_crc_handle_queue()
371 j = min(nextlen, sg_dma_len(sg)); in bfin_crypto_crc_handle_queue()
373 sg_virt(sg) + sg_dma_len(sg) - j, j); in bfin_crypto_crc_handle_queue()
374 if (j == sg_dma_len(sg)) in bfin_crypto_crc_handle_queue()