linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch 23/30] drivers/scsi/lpfc/lpfc_scsi.c: kmalloc + memset conversion to kzalloc
@ 2007-08-10 21:50 akpm
  0 siblings, 0 replies; only message in thread
From: akpm @ 2007-08-10 21:50 UTC (permalink / raw)
  To: James.Bottomley; +Cc: linux-scsi, akpm, m.kozlowski, James.Smart

From: Mariusz Kozlowski <m.kozlowski@tuxland.pl>

 drivers/scsi/lpfc/lpfc_scsi.c | 42769 -> 42721 (-48 bytes)
 drivers/scsi/lpfc/lpfc_scsi.o | 191332 -> 191240 (-92 bytes)

Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
Acked-by: James Smart <James.Smart@Emulex.Com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 drivers/scsi/lpfc/lpfc_scsi.c |    3 +--
 1 files changed, 1 insertion(+), 2 deletions(-)

diff -puN drivers/scsi/lpfc/lpfc_scsi.c~drivers-scsi-lpfc-lpfc_scsic-kmalloc-memset-conversion-to-kzalloc drivers/scsi/lpfc/lpfc_scsi.c
--- a/drivers/scsi/lpfc/lpfc_scsi.c~drivers-scsi-lpfc-lpfc_scsic-kmalloc-memset-conversion-to-kzalloc
+++ a/drivers/scsi/lpfc/lpfc_scsi.c
@@ -202,10 +202,9 @@ lpfc_new_scsi_buf(struct lpfc_vport *vpo
 	dma_addr_t pdma_phys;
 	uint16_t iotag;
 
-	psb = kmalloc(sizeof(struct lpfc_scsi_buf), GFP_KERNEL);
+	psb = kzalloc(sizeof(struct lpfc_scsi_buf), GFP_KERNEL);
 	if (!psb)
 		return NULL;
-	memset(psb, 0, sizeof (struct lpfc_scsi_buf));
 
 	/*
 	 * Get memory from the pci pool to map the virt space to pci bus space
_

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-08-10 22:01 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-10 21:50 [patch 23/30] drivers/scsi/lpfc/lpfc_scsi.c: kmalloc + memset conversion to kzalloc akpm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).