lightnvm: fix missing grown bad block type
[firefly-linux-kernel-4.4.55.git] / include / linux / dmapool.h
index e1043f79122f827405afbb7b176d14611702098a..53ba737505df31c7673c814d8d00884f72a17cb1 100644 (file)
@@ -24,6 +24,12 @@ void dma_pool_destroy(struct dma_pool *pool);
 void *dma_pool_alloc(struct dma_pool *pool, gfp_t mem_flags,
                     dma_addr_t *handle);
 
+static inline void *dma_pool_zalloc(struct dma_pool *pool, gfp_t mem_flags,
+                                   dma_addr_t *handle)
+{
+       return dma_pool_alloc(pool, mem_flags | __GFP_ZERO, handle);
+}
+
 void dma_pool_free(struct dma_pool *pool, void *vaddr, dma_addr_t addr);
 
 /*