Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=0d661327a7578c3fca43db78f32e92a902237e7a Commit: 0d661327a7578c3fca43db78f32e92a902237e7a Parent: 08547354c17a50a54906b7936d6ecb05ea39bedd Author: Swen Schillig <[EMAIL PROTECTED]> AuthorDate: Wed Jul 18 10:55:08 2007 +0200 Committer: James Bottomley <[EMAIL PROTECTED]> CommitDate: Wed Jul 18 11:32:33 2007 -0500
[SCSI] zfcp: Replace kmalloc/memset with kzalloc Memory allocated with kmalloc is always initialzed to 0 with memset. Replace the two calls with kzalloc, that already does both steps. Signed-off-by: Swen Schillig <[EMAIL PROTECTED]> Signed-off-by: James Bottomley <[EMAIL PROTECTED]> --- drivers/s390/scsi/zfcp_erp.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/drivers/s390/scsi/zfcp_erp.c b/drivers/s390/scsi/zfcp_erp.c index 4e7cb6d..d8cd75c 100644 --- a/drivers/s390/scsi/zfcp_erp.c +++ b/drivers/s390/scsi/zfcp_erp.c @@ -1626,7 +1626,7 @@ zfcp_erp_schedule_work(struct zfcp_unit *unit) { struct zfcp_erp_add_work *p; - p = kmalloc(sizeof(*p), GFP_KERNEL); + p = kzalloc(sizeof(*p), GFP_KERNEL); if (!p) { ZFCP_LOG_NORMAL("error: Out of resources. Could not register " "the FCP-LUN 0x%Lx connected to " @@ -1639,7 +1639,6 @@ zfcp_erp_schedule_work(struct zfcp_unit *unit) } zfcp_unit_get(unit); - memset(p, 0, sizeof(*p)); atomic_set_mask(ZFCP_STATUS_UNIT_SCSI_WORK_PENDING, &unit->status); INIT_WORK(&p->work, zfcp_erp_scsi_scan); p->unit = unit; - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html