From: Ishai Rabinovitz Date: Tue, 10 Oct 2006 16:51:14 +0000 (-0700) Subject: IB/srp: Remove redundant memset() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9b0af401aae336975e620fccdd294bb763424f3f;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git IB/srp: Remove redundant memset() scsi_host_alloc() already allocates with kzalloc(), so the struct Scsi_Host is zeroed out, including the private data portion. Remove the redundant memset that zeros this out again in the SRP initiator. Signed-off-by: Ishai Rabinovitz Signed-off-by: Roland Dreier --- diff --git a/drivers/infiniband/ulp/srp/ib_srp.c b/drivers/infiniband/ulp/srp/ib_srp.c index 44b9e5be6687..f1b7a0f2beed 100644 --- a/drivers/infiniband/ulp/srp/ib_srp.c +++ b/drivers/infiniband/ulp/srp/ib_srp.c @@ -1708,7 +1708,6 @@ static ssize_t srp_create_target(struct class_device *class_dev, target_host->max_lun = SRP_MAX_LUN; target = host_to_target(target_host); - memset(target, 0, sizeof *target); target->io_class = SRP_REV16A_IB_IO_CLASS; target->scsi_host = target_host;