From: Amitoj Kaur Chawla Date: Thu, 23 Jun 2016 05:00:55 +0000 (+0530) Subject: i40e: Remove redundant memset X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=4dec7d045d6d20afe794adbda5b6da2fe5d63a35;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git i40e: Remove redundant memset 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 Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher --- diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c index 2351a08fb986..753c3b1fb476 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);