From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
To: davem@davemloft.net
Cc: Amitoj Kaur Chawla <amitoj1606@gmail.com>,
netdev@vger.kernel.org, nhorman@redhat.com, sassmann@redhat.com,
jogreene@redhat.com, guru.anbalagane@oracle.com,
Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Subject: [net-next 08/11] i40e: Remove redundant memset
Date: Fri, 22 Jul 2016 00:36:36 -0700 [thread overview]
Message-ID: <1469172999-8969-9-git-send-email-jeffrey.t.kirsher@intel.com> (raw)
In-Reply-To: <1469172999-8969-1-git-send-email-jeffrey.t.kirsher@intel.com>
From: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Remove redundant call to memset before a call to memcpy.
The Coccinelle semantic patch used to make this change is as follows:
@@
expression e1,e2,e3,e4;
@@
- memset(e1,e2,e3);
memcpy(e1,e4,e3);
Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
---
drivers/net/ethernet/intel/i40e/i40e_main.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c
index 2351a08..753c3b1 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_main.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_main.c
@@ -7916,7 +7916,6 @@ static int i40e_config_rss_aq(struct i40e_vsi *vsi, const u8 *seed,
u8 *rss_lut;
int ret, i;
- memset(&rss_key, 0, sizeof(rss_key));
memcpy(&rss_key, seed, sizeof(rss_key));
rss_lut = kzalloc(pf->rss_table_size, GFP_KERNEL);
--
2.5.5
next prev parent reply other threads:[~2016-07-22 7:36 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-22 7:36 [net-next 00/11][pull request] 40GbE Intel Wired LAN Driver Updates 2016-07-22 Jeff Kirsher
2016-07-22 7:36 ` [net-next 01/11] i40e: avoid null pointer dereference Jeff Kirsher
2016-07-22 7:36 ` [net-next 02/11] i40e: Fix to show correct Advertised Link Modes when link is down Jeff Kirsher
2016-07-22 7:36 ` [net-next 03/11] i40e/i40evf: remove useless initializer Jeff Kirsher
2016-07-22 7:36 ` [net-next 04/11] i40e: Remove device ID 0x37D4 Jeff Kirsher
2016-07-22 7:36 ` [net-next 05/11] i40evf: add hyperv dev ids Jeff Kirsher
2016-07-22 7:36 ` [net-next 06/11] i40e: refactor Rx filter handling Jeff Kirsher
2016-07-22 7:36 ` [net-next 07/11] i40e/i40evf-bump version to 1.6.11 Jeff Kirsher
2016-07-22 7:36 ` Jeff Kirsher [this message]
2016-07-22 7:36 ` [net-next 09/11] i40e: Move the mutex lock in i40e_client_unregister Jeff Kirsher
2016-07-22 7:36 ` [net-next 10/11] i40e: add missing link advertise setting Jeff Kirsher
2016-07-22 7:36 ` [net-next 11/11] i40e: Explicitly write platform-specific mac address after PF reset Jeff Kirsher
2016-07-25 17:46 ` [net-next 00/11][pull request] 40GbE Intel Wired LAN Driver Updates 2016-07-22 David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1469172999-8969-9-git-send-email-jeffrey.t.kirsher@intel.com \
--to=jeffrey.t.kirsher@intel.com \
--cc=amitoj1606@gmail.com \
--cc=davem@davemloft.net \
--cc=guru.anbalagane@oracle.com \
--cc=jogreene@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=nhorman@redhat.com \
--cc=sassmann@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).