* [PATCH] ata: sata_mv: Replacing dma_pool_alloc and memset with a single call dma_pool_zalloc.
@ 2016-09-20 19:44 Harman Kalra
2016-09-20 20:08 ` Tejun Heo
0 siblings, 1 reply; 2+ messages in thread
From: Harman Kalra @ 2016-09-20 19:44 UTC (permalink / raw)
To: tj, linux-ide; +Cc: Harman Kalra
Replacing dma_pool_alloc and memset with a single call to dma_pool_zalloc
Signed-off-by: Harman Kalra <harman4linux@gmail.com>
---
drivers/ata/sata_mv.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c
index 745489a..efc48bf 100644
--- a/drivers/ata/sata_mv.c
+++ b/drivers/ata/sata_mv.c
@@ -1727,15 +1727,13 @@ static int mv_port_start(struct ata_port *ap)
return -ENOMEM;
ap->private_data = pp;
- pp->crqb = dma_pool_alloc(hpriv->crqb_pool, GFP_KERNEL, &pp->crqb_dma);
+ pp->crqb = dma_pool_zalloc(hpriv->crqb_pool, GFP_KERNEL, &pp->crqb_dma);
if (!pp->crqb)
return -ENOMEM;
- memset(pp->crqb, 0, MV_CRQB_Q_SZ);
- pp->crpb = dma_pool_alloc(hpriv->crpb_pool, GFP_KERNEL, &pp->crpb_dma);
+ pp->crpb = dma_pool_zalloc(hpriv->crpb_pool, GFP_KERNEL, &pp->crpb_dma);
if (!pp->crpb)
goto out_port_free_dma_mem;
- memset(pp->crpb, 0, MV_CRPB_Q_SZ);
/* 6041/6081 Rev. "C0" (and newer) are okay with async notify */
if (hpriv->hp_flags & MV_HP_ERRATA_60X1C0)
--
1.7.9.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] ata: sata_mv: Replacing dma_pool_alloc and memset with a single call dma_pool_zalloc.
2016-09-20 19:44 [PATCH] ata: sata_mv: Replacing dma_pool_alloc and memset with a single call dma_pool_zalloc Harman Kalra
@ 2016-09-20 20:08 ` Tejun Heo
0 siblings, 0 replies; 2+ messages in thread
From: Tejun Heo @ 2016-09-20 20:08 UTC (permalink / raw)
To: Harman Kalra; +Cc: linux-ide
On Wed, Sep 21, 2016 at 01:14:40AM +0530, Harman Kalra wrote:
> Replacing dma_pool_alloc and memset with a single call to dma_pool_zalloc
>
> Signed-off-by: Harman Kalra <harman4linux@gmail.com>
Applied to libata/for-4.9.
Thanks.
--
tejun
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-09-20 20:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-20 19:44 [PATCH] ata: sata_mv: Replacing dma_pool_alloc and memset with a single call dma_pool_zalloc Harman Kalra
2016-09-20 20:08 ` Tejun Heo
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.