summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aic94xx
diff options
context:
space:
mode:
authorSouptick Joarder <jrdr.linux@gmail.com>2018-11-01 05:19:09 +0100
committerMartin K. Petersen <martin.petersen@oracle.com>2018-11-22 04:02:40 +0100
commit0e55892ea2e62c66fee24a3d73eea3ad0b287ba4 (patch)
treec92d4cb4512c28f8e4cdf0f08e4b30f2cb7c3b97 /drivers/scsi/aic94xx
parentscsi: zfcp: drop old default switch case which might paper over missing case (diff)
downloadlinux-0e55892ea2e62c66fee24a3d73eea3ad0b287ba4.tar.xz
linux-0e55892ea2e62c66fee24a3d73eea3ad0b287ba4.zip
scsi: aic94xx: Use dma_pool_zalloc
Replaced dma_pool_alloc + memset with dma_pool_zalloc. Signed-off-by: Brajeswar Ghosh <brajeswar.linux@gmail.com> Signed-off-by: Souptick Joarder <jrdr.linux@gmail.com> Reviewed-by: Kees Cook <keescook@chromium.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/aic94xx')
-rw-r--r--drivers/scsi/aic94xx/aic94xx_hwi.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/scsi/aic94xx/aic94xx_hwi.c b/drivers/scsi/aic94xx/aic94xx_hwi.c
index 3b8ad55e59de..2bc7615193bd 100644
--- a/drivers/scsi/aic94xx/aic94xx_hwi.c
+++ b/drivers/scsi/aic94xx/aic94xx_hwi.c
@@ -1057,14 +1057,13 @@ static struct asd_ascb *asd_ascb_alloc(struct asd_ha_struct *asd_ha,
if (ascb) {
ascb->dma_scb.size = sizeof(struct scb);
- ascb->dma_scb.vaddr = dma_pool_alloc(asd_ha->scb_pool,
+ ascb->dma_scb.vaddr = dma_pool_zalloc(asd_ha->scb_pool,
gfp_flags,
&ascb->dma_scb.dma_handle);
if (!ascb->dma_scb.vaddr) {
kmem_cache_free(asd_ascb_cache, ascb);
return NULL;
}
- memset(ascb->dma_scb.vaddr, 0, sizeof(struct scb));
asd_init_ascb(asd_ha, ascb);
spin_lock_irqsave(&seq->tc_index_lock, flags);