From patchwork Wed Aug 24 09:33:14 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jitendra Bhivare X-Patchwork-Id: 9297333 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id A93F4607F0 for ; Wed, 24 Aug 2016 09:36:12 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 99AF128EC1 for ; Wed, 24 Aug 2016 09:36:12 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8E5A928EC6; Wed, 24 Aug 2016 09:36:12 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8514B28EC1 for ; Wed, 24 Aug 2016 09:36:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754394AbcHXJgK (ORCPT ); Wed, 24 Aug 2016 05:36:10 -0400 Received: from mail-pf0-f171.google.com ([209.85.192.171]:33161 "EHLO mail-pf0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754015AbcHXJgK (ORCPT ); Wed, 24 Aug 2016 05:36:10 -0400 Received: by mail-pf0-f171.google.com with SMTP id y134so5224180pfg.0 for ; Wed, 24 Aug 2016 02:36:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=g+pYu7V9WOhNaqStkSpDMWxwWdwYKJ7s9NRv+UyFMG4=; b=LAdtMn9GRewr9mAXg1vloZBbOpJy2dYNLPyvdypoL3KcVaiGzifbxNzyWp2zlHP3Ny bCotuhOTKgH4/Fo+c43b9PtOhkkct62no+Ty8Od30ARgeEu9pMFgpIs9L0A6J5+Bn+MR y2MXG4gKL2nLhNMoTKCDplqQmWFNd5TNrJPeY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=g+pYu7V9WOhNaqStkSpDMWxwWdwYKJ7s9NRv+UyFMG4=; b=XLdJKXn3wCcGtMmLl6vYDMzZC1MBihAkRxq3vpGX/YPbGf/+9otgUaFm37l91E4a28 HFdQMrxXuBnteI2LCDEGw7/uHe2Po7tapmEONkPJxQgKWhzQBNe/JK+fiYyoqJJXxqtf w5ewcSjBaNo5/mneMmGwp02yAZYEK3N5zmvT7nGPcFexqyCgB/xJsNOy32l6gqKkzyzE 8S4Oross3/Ym5c9ZG0s0/7IRcYCk4geCLBfLiFB4VQnhQQwpm+tXmuXMabESkjs/FV+o CwR02+HdUlMuBAkII89nFBFlUaFGzwvK58GHei8nejoOwu869k4PwwuVPSw6Ltc5Ek3j Gx1g== X-Gm-Message-State: AE9vXwMIXBGlEHSIHfmRls3FAlU6f+7yKVz0a7DF0rnjxLGZjN9XjfpgSC0KcgxCXvXpABQ3 X-Received: by 10.98.216.199 with SMTP id e190mr3814605pfg.123.1472031368981; Wed, 24 Aug 2016 02:36:08 -0700 (PDT) Received: from android.dhcp.avagotech.net ([192.19.239.250]) by smtp.gmail.com with ESMTPSA id m24sm11922446pfi.34.2016.08.24.02.36.06 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 24 Aug 2016 02:36:08 -0700 (PDT) From: Jitendra Bhivare To: christophe.jaillet@wanadoo.fr, julia.lawall@lip6.fr, martin.petersen@oracle.com Cc: linux-scsi@vger.kernel.org, Jitendra Bhivare Subject: [PATCH 2/3] be2iscsi: Remove redundant iscsi_wrb desc memset Date: Wed, 24 Aug 2016 15:03:14 +0530 Message-Id: <1472031195-14556-3-git-send-email-jitendra.bhivare@broadcom.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1472031195-14556-1-git-send-email-jitendra.bhivare@broadcom.com> References: <1472031195-14556-1-git-send-email-jitendra.bhivare@broadcom.com> Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP alloc_wrb_handle already does memset zero of iscsi_wrb descriptor so remove redundant memset in WRB submission paths. Signed-off-by: Jitendra Bhivare --- drivers/scsi/be2iscsi/be_main.c | 1 - drivers/scsi/be2iscsi/be_mgmt.c | 3 --- 2 files changed, 4 deletions(-) diff --git a/drivers/scsi/be2iscsi/be_main.c b/drivers/scsi/be2iscsi/be_main.c index b30db87..edea89f 100644 --- a/drivers/scsi/be2iscsi/be_main.c +++ b/drivers/scsi/be2iscsi/be_main.c @@ -4718,7 +4718,6 @@ static int beiscsi_mtask(struct iscsi_task *task) cid = beiscsi_conn->beiscsi_conn_cid; pwrb = io_task->pwrb_handle->pwrb; - memset(pwrb, 0, sizeof(*pwrb)); if (is_chip_be2_be3r(phba)) { AMAP_SET_BITS(struct amap_iscsi_wrb, cmdsn_itt, pwrb, diff --git a/drivers/scsi/be2iscsi/be_mgmt.c b/drivers/scsi/be2iscsi/be_mgmt.c index 3ac7b88..b9ff939 100644 --- a/drivers/scsi/be2iscsi/be_mgmt.c +++ b/drivers/scsi/be2iscsi/be_mgmt.c @@ -1350,7 +1350,6 @@ void beiscsi_offload_cxn_v0(struct beiscsi_offload_params *params, { struct iscsi_wrb *pwrb = pwrb_handle->pwrb; - memset(pwrb, 0, sizeof(*pwrb)); AMAP_SET_BITS(struct amap_iscsi_target_context_update_wrb, max_send_data_segment_length, pwrb, params->dw[offsetof(struct amap_beiscsi_offload_params, @@ -1422,8 +1421,6 @@ void beiscsi_offload_cxn_v2(struct beiscsi_offload_params *params, { struct iscsi_wrb *pwrb = pwrb_handle->pwrb; - memset(pwrb, 0, sizeof(*pwrb)); - AMAP_SET_BITS(struct amap_iscsi_target_context_update_wrb_v2, max_burst_length, pwrb, params->dw[offsetof (struct amap_beiscsi_offload_params,