From 0c82d3ce2f479c728f99e228d9ae32a9cd853c5a Mon Sep 17 00:00:00 2001 From: David Woodhouse Date: Thu, 11 Mar 2010 09:25:14 -0800 Subject: mtd/nand/r852: Use pci_dma_mapping_error() ... instead of comparing with DMA_ERROR_CODE, which will only work on powerpc/sparc/x86. Reported-by: Geert Uytterhoeven Signed-off-by: David Woodhouse --- drivers/mtd/nand/r852.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/mtd/nand') diff --git a/drivers/mtd/nand/r852.c b/drivers/mtd/nand/r852.c index 06f07bb414a..96bfbd8e8fd 100644 --- a/drivers/mtd/nand/r852.c +++ b/drivers/mtd/nand/r852.c @@ -197,7 +197,7 @@ static void r852_do_dma(struct r852_device *dev, uint8_t *buf, int do_read) R852_DMA_LEN, (do_read ? PCI_DMA_FROMDEVICE : PCI_DMA_TODEVICE)); - if (dev->phys_dma_addr == DMA_ERROR_CODE) + if (pci_dma_mapping_error(dev->pci_dev, dev->phys_dma_addr)) bounce = 1; } -- cgit v1.2.3-18-g5258