]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
zynq_fpga: use sgtable-based scatterlist wrappers
authorMarek Szyprowski <m.szyprowski@samsung.com>
Mon, 16 Jun 2025 12:09:32 +0000 (14:09 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 28 Aug 2025 14:30:57 +0000 (16:30 +0200)
commitb7a840afe31ff2ba9ae4e6a74f6d3673abae98f2
tree790680e7b49f6aa1ae1f39246dbdd0a1cc749367
parent87bfabb3b2f46827639173f143aa43f7cfc0a7e6
zynq_fpga: use sgtable-based scatterlist wrappers

commit 37e00703228ab44d0aacc32a97809a4f6f58df1b upstream.

Use common wrappers operating directly on the struct sg_table objects to
fix incorrect use of statterlists related calls. dma_unmap_sg() function
has to be called with the number of elements originally passed to the
dma_map_sg() function, not the one returned in sgtable's nents.

CC: stable@vger.kernel.org
Fixes: 425902f5c8e3 ("fpga zynq: Use the scatterlist interface")
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Reviewed-by: Jason Gunthorpe <jgg@nvidia.com>
Reviewed-by: Xu Yilun <yilun.xu@intel.com>
Link: https://lore.kernel.org/r/20250616120932.1090614-1-m.szyprowski@samsung.com
Signed-off-by: Xu Yilun <yilun.xu@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/fpga/zynq-fpga.c