From: Christoph Hellwig Date: Tue, 4 Dec 2018 16:04:31 +0000 (-0800) Subject: dma-mapping: remove a pointless memset in dma_atomic_pool_init X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=20b105feda8d42360bd690b8fdf6b2f00ba4a993;p=linux.git dma-mapping: remove a pointless memset in dma_atomic_pool_init We already zero the memory after allocating it from the pool that this function fills, and having the memset here in this form means we can't support CMA highmem allocations. Signed-off-by: Christoph Hellwig Reported-by: Russell King - ARM Linux --- diff --git a/kernel/dma/remap.c b/kernel/dma/remap.c index 8a44317cfc1ae..18cc09fc27b92 100644 --- a/kernel/dma/remap.c +++ b/kernel/dma/remap.c @@ -121,7 +121,6 @@ int __init dma_atomic_pool_init(gfp_t gfp, pgprot_t prot) if (!page) goto out; - memset(page_address(page), 0, atomic_pool_size); arch_dma_prep_coherent(page, atomic_pool_size); atomic_pool = gen_pool_create(PAGE_SHIFT, -1);