ia64/xen-unstable

changeset 6233:7be2d754647d

have a useful line reporting when IOMMU_BUG_ON trigger

Signed-off-by: Vincent Hanquez <vincent@xensource.com>
author vh249@arcadians.cl.cam.ac.uk
date Wed Aug 17 15:09:31 2005 +0000 (2005-08-17)
parents 5b5d1a4a754a
children d4f6247b2a1b
files linux-2.6-xen-sparse/arch/xen/i386/kernel/pci-dma.c
line diff
     1.1 --- a/linux-2.6-xen-sparse/arch/xen/i386/kernel/pci-dma.c	Wed Aug 17 14:23:16 2005 +0000
     1.2 +++ b/linux-2.6-xen-sparse/arch/xen/i386/kernel/pci-dma.c	Wed Aug 17 15:09:31 2005 +0000
     1.3 @@ -24,13 +24,13 @@ struct dma_coherent_mem {
     1.4  	unsigned long	*bitmap;
     1.5  };
     1.6  
     1.7 -static void iommu_bug(void)
     1.8 -{
     1.9 -	printk(KERN_ALERT "Fatal DMA error! Please use 'swiotlb=force'\n");
    1.10 -	BUG();
    1.11 -}
    1.12 -
    1.13 -#define IOMMU_BUG_ON(test) do { if (unlikely(test)) iommu_bug(); } while(0)
    1.14 +#define IOMMU_BUG_ON(test) \
    1.15 +do { \
    1.16 +	if (unlikely(test)) { \
    1.17 +		printk(KERN_ALERT "Fatal DMA error! Please use 'swiotlb=force'\n"); \
    1.18 +		BUG(); \
    1.19 +	} \
    1.20 +} while(0)
    1.21  
    1.22  int
    1.23  dma_map_sg(struct device *hwdev, struct scatterlist *sg, int nents,