From: Logan Gunthorpe Date: Thu, 29 Jul 2021 20:15:31 +0000 (-0600) Subject: s390/pci: don't set failed sg dma_address to DMA_MAPPING_ERROR X-Git-Tag: v5.15-rc1~124^2~16 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7e4e7d4c54ecc9986041aae84e04280413f2435b;p=thirdparty%2Flinux.git s390/pci: don't set failed sg dma_address to DMA_MAPPING_ERROR Setting the ->dma_address to DMA_MAPPING_ERROR is not part of the ->map_sg calling convention, so remove it. Link: https://lore.kernel.org/linux-mips/20210716063241.GC13345@lst.de/ Suggested-by: Christoph Hellwig Signed-off-by: Logan Gunthorpe Cc: Niklas Schnelle Cc: Gerald Schaefer Cc: Heiko Carstens Cc: Vasily Gorbik Cc: Christian Borntraeger Signed-off-by: Christoph Hellwig --- diff --git a/arch/s390/pci/pci_dma.c b/arch/s390/pci/pci_dma.c index c78b020127648..be48e5b5bfcf6 100644 --- a/arch/s390/pci/pci_dma.c +++ b/arch/s390/pci/pci_dma.c @@ -492,7 +492,6 @@ static int s390_dma_map_sg(struct device *dev, struct scatterlist *sg, for (i = 1; i < nr_elements; i++) { s = sg_next(s); - s->dma_address = DMA_MAPPING_ERROR; s->dma_length = 0; if (s->offset || (size & ~PAGE_MASK) ||