dma-mapping: remove unused gfp_t parameter to arch_dma_alloc_attrs
authorHuaisheng Ye <yehs1@lenovo.com>
Fri, 25 May 2018 05:00:00 +0000 (13:00 +0800)
committerChristoph Hellwig <hch@lst.de>
Fri, 25 May 2018 09:23:06 +0000 (11:23 +0200)
Signed-off-by: Huaisheng Ye <yehs1@lenovo.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
arch/x86/include/asm/dma-mapping.h
arch/x86/kernel/pci-dma.c
include/linux/dma-mapping.h

index 89ce4bfd241fb8aa97277946660148a0f060bed5..ef597478f0acc34d7550d6c981def583336e3074 100644 (file)
@@ -33,7 +33,7 @@ static inline const struct dma_map_ops *get_arch_dma_ops(struct bus_type *bus)
 int arch_dma_supported(struct device *dev, u64 mask);
 #define arch_dma_supported arch_dma_supported
 
-bool arch_dma_alloc_attrs(struct device **dev, gfp_t *gfp);
+bool arch_dma_alloc_attrs(struct device **dev);
 #define arch_dma_alloc_attrs arch_dma_alloc_attrs
 
 #endif
index bcbaa2e8031e6d8b0babfb5d81d5fbf18abed47e..c7113fd18e320b88a1146b38b6d3c181beb43493 100644 (file)
@@ -73,7 +73,7 @@ void __init pci_iommu_alloc(void)
        }
 }
 
-bool arch_dma_alloc_attrs(struct device **dev, gfp_t *gfp)
+bool arch_dma_alloc_attrs(struct device **dev)
 {
        if (!*dev)
                *dev = &x86_dma_fallback_dev;
index 4be070df5fc5f18ad453bfbf79434d840e8cc9da..15e4b4e9cc20de0c969f497837d2925cb41dcc28 100644 (file)
@@ -502,7 +502,7 @@ dma_get_sgtable_attrs(struct device *dev, struct sg_table *sgt, void *cpu_addr,
 #define dma_get_sgtable(d, t, v, h, s) dma_get_sgtable_attrs(d, t, v, h, s, 0)
 
 #ifndef arch_dma_alloc_attrs
-#define arch_dma_alloc_attrs(dev, flag)        (true)
+#define arch_dma_alloc_attrs(dev)      (true)
 #endif
 
 static inline void *dma_alloc_attrs(struct device *dev, size_t size,
@@ -521,7 +521,7 @@ static inline void *dma_alloc_attrs(struct device *dev, size_t size,
        /* let the implementation decide on the zone to allocate from: */
        flag &= ~(__GFP_DMA | __GFP_DMA32 | __GFP_HIGHMEM);
 
-       if (!arch_dma_alloc_attrs(&dev, &flag))
+       if (!arch_dma_alloc_attrs(&dev))
                return NULL;
        if (!ops->alloc)
                return NULL;