]> git.baikalelectronics.ru Git - kernel.git/commitdiff
dma-direct: remove the dma_handle argument to __dma_direct_alloc_pages
authorChristoph Hellwig <hch@lst.de>
Tue, 29 Oct 2019 08:57:32 +0000 (09:57 +0100)
committerChristoph Hellwig <hch@lst.de>
Thu, 7 Nov 2019 16:25:57 +0000 (17:25 +0100)
The argument isn't used anywhere, so stop passing it.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Max Filippov <jcmvbkbc@gmail.com>
include/linux/dma-direct.h
kernel/dma/direct.c
kernel/dma/remap.c

index dec3b3bb121da39e94367b0bf1a5db914c6507e0..ff3d5edc44b9fd6dd44918892eed5e9d9f7d3140 100644 (file)
@@ -67,6 +67,6 @@ void *dma_direct_alloc_pages(struct device *dev, size_t size,
 void dma_direct_free_pages(struct device *dev, size_t size, void *cpu_addr,
                dma_addr_t dma_addr, unsigned long attrs);
 struct page *__dma_direct_alloc_pages(struct device *dev, size_t size,
-               dma_addr_t *dma_handle, gfp_t gfp, unsigned long attrs);
+               gfp_t gfp, unsigned long attrs);
 int dma_direct_supported(struct device *dev, u64 mask);
 #endif /* _LINUX_DMA_DIRECT_H */
index a7a2739fb7475df03c7912dc5129fdd7f4f15b22..724c282dd943c09ebc896f146d8d600814a1cd86 100644 (file)
@@ -83,7 +83,7 @@ static bool dma_coherent_ok(struct device *dev, phys_addr_t phys, size_t size)
 }
 
 struct page *__dma_direct_alloc_pages(struct device *dev, size_t size,
-               dma_addr_t *dma_handle, gfp_t gfp, unsigned long attrs)
+               gfp_t gfp, unsigned long attrs)
 {
        size_t alloc_size = PAGE_ALIGN(size);
        int node = dev_to_node(dev);
@@ -131,7 +131,7 @@ void *dma_direct_alloc_pages(struct device *dev, size_t size,
        struct page *page;
        void *ret;
 
-       page = __dma_direct_alloc_pages(dev, size, dma_handle, gfp, attrs);
+       page = __dma_direct_alloc_pages(dev, size, gfp, attrs);
        if (!page)
                return NULL;
 
index fb1e50c2d48a19194c7f0c75a65506d1cfddceb2..90d5ce77c189c4a8f9a51991b7eb57355092cccc 100644 (file)
@@ -226,7 +226,7 @@ void *arch_dma_alloc(struct device *dev, size_t size, dma_addr_t *dma_handle,
                goto done;
        }
 
-       page = __dma_direct_alloc_pages(dev, size, dma_handle, flags, attrs);
+       page = __dma_direct_alloc_pages(dev, size, flags, attrs);
        if (!page)
                return NULL;