Lines Matching refs:sgt
475 struct sg_table *sgt, void *buf, size_t len, in spi_map_buf() argument
486 ret = sg_alloc_table(sgt, sgs, GFP_KERNEL); in spi_map_buf()
496 sg_free_table(sgt); in spi_map_buf()
499 sg_set_page(&sgt->sgl[i], vm_page, in spi_map_buf()
503 sg_set_buf(&sgt->sgl[i], sg_buf, min); in spi_map_buf()
511 ret = dma_map_sg(dev, sgt->sgl, sgt->nents, dir); in spi_map_buf()
515 sg_free_table(sgt); in spi_map_buf()
519 sgt->nents = ret; in spi_map_buf()
525 struct sg_table *sgt, enum dma_data_direction dir) in spi_unmap_buf() argument
527 if (sgt->orig_nents) { in spi_unmap_buf()
528 dma_unmap_sg(dev, sgt->sgl, sgt->orig_nents, dir); in spi_unmap_buf()
529 sg_free_table(sgt); in spi_unmap_buf()