Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp4052254ybi; Tue, 18 Jun 2019 10:55:48 -0700 (PDT) X-Google-Smtp-Source: APXvYqwvG5KRa8HSjPDyCab5GMkC9dn4ncfoNy4mEXTgINvYpk/Z7ozgcUVgF6c39us1iViLa1x+ X-Received: by 2002:a63:3008:: with SMTP id w8mr3836400pgw.11.1560880548431; Tue, 18 Jun 2019 10:55:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560880548; cv=none; d=google.com; s=arc-20160816; b=YLdFdnONq0WVAnJ8x4VRed/H2oThNuTt0VL47yxzE7mqFNlXMwsLpJoriI8UYIzNGe 0kDbUA4rNPTkZhQH356t4N3VIHm+ZfjiKFL77xqv/D/7xjIo5UBF5L4sIn2fUnczg21A QFa+byh85q6xMhv/5yAqIul/ZLJJ/b77aT9ZKlKKUijZPtRfNJAmAEicfSevAkkLVSN/ kJ9CQnSPSoB2/7ONhWV3yYz4uKbjfTOoKT9tHIfLpY6ot/yPeHoj5x15LwFnt/7q7VXT 8R3q8a30ns18lowSDe1HPZ+R3SAfeN2VroV8M+cXKsWjaKuYmhr/GSZkO0WxKDzU+Gli KlpA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:content-disposition :mime-version:message-id:subject:to:from:date:dkim-signature; bh=sZQNDbvRCX1/xmAgz48y9nkM0uP28/QjVvVkkR3CQOA=; b=o5OdKXtAgKeaB0mr/Ig74X2l5nLQ5emjcWgeCcMzHEfvdRLJpCL/m9RYT7rr9Zsw5l SvfehbttH6rzayMbGO0UJAbHOLWz+BFqG4y8oJvz1w6vK2tWIDE0q8SokY5V7F0r+DtV 5QBvG/aZSSvKTpydvBOhAFRLciZQWBdah3j6trM/RZAvf7VHOlQTbvhyfFG+rJE5Tysq Wf7BsxbGBMNwpREzxBsxogUXvfH4OIxJV1sG/fNeeZzuZ2ejZ53L0QzxHqIHCfVapfvu zr4y/GRMVKC5gUws/9obg4lXThkr+ReHUPSQiiUEWjy70ti8VQJQF3ccl6BYXyySPLpz YhOQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=C4Iz1IGy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m7si2692328pjs.63.2019.06.18.10.55.32; Tue, 18 Jun 2019 10:55:48 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=C4Iz1IGy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729922AbfFRRzV (ORCPT + 99 others); Tue, 18 Jun 2019 13:55:21 -0400 Received: from mail-pg1-f194.google.com ([209.85.215.194]:35371 "EHLO mail-pg1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729285AbfFRRzV (ORCPT ); Tue, 18 Jun 2019 13:55:21 -0400 Received: by mail-pg1-f194.google.com with SMTP id s27so8108822pgl.2 for ; Tue, 18 Jun 2019 10:55:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:mime-version:content-disposition :user-agent; bh=sZQNDbvRCX1/xmAgz48y9nkM0uP28/QjVvVkkR3CQOA=; b=C4Iz1IGyiHO+KxnxVZJMXrvK0VMpgE0VV8M58ezWEBhGaMJqGoxNPncfAY9jQXro1a q2Dzr43f5dlfHfhfUcftvrpCzA/BC3JWfBqDig80Yi+GH7GTGVcyEBvjlU4h93NUMTU2 +Vklf+mbjyEb6tgJFqATVI5ElgnQ8aZb5U95w6io2EoG9i6QBhq77xIblzZdHUys2JRy 0LBU6WNQ2ZZsau9C761+3HwY60Nx2/yUBgCKfAonztX4KVHD1vomR22vIfTmFOCMSPqV q6Gl2llLemRxkoD0x8cQq0zZfmEQmxMSNapLKLrpIX0CTkoiBtCm7l+1eaHX3ykn+one WwpA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:mime-version :content-disposition:user-agent; bh=sZQNDbvRCX1/xmAgz48y9nkM0uP28/QjVvVkkR3CQOA=; b=JeilnJL+XHr+xAsdDy5Er7eZcuXh2BMyhchCCJNHdfvQkSPE1t8JIeDsTcoOpFfd1n H0oQ6BL5vsi+IjoorrQhdDts4KYpiXcDtYoQEvbDP77fMb94KU5G+cKZrz6M9LhptPyv SU7aBT5ymQnhIxE2e1vDFXsVwlS3tQYU4pjN7M2dlSC7415LirHyg952y+SfYH0s+/UE TYE/XdvyzCWjk3rtDZOYNymhJ97vVgRXzJDuFGsZcK2Jd8QUdlItTs6SKWSDhyVMBBdd 3MwQOYmneKGDCpwPL0rsh/O6mEQwYfqJNwRCIpv6TqDfuShZibrqj0Pxz66DLd/azo+p PpsQ== X-Gm-Message-State: APjAAAWu7zd8S329jvYCgscJjwnRDeO4da77TdfB99fcVdB4P0fsK0+3 aatugqAtcRBo5WkL8wJikNQ= X-Received: by 2002:a17:90a:e397:: with SMTP id b23mr6347869pjz.140.1560880520698; Tue, 18 Jun 2019 10:55:20 -0700 (PDT) Received: from hari-Inspiron-1545 ([183.83.92.187]) by smtp.gmail.com with ESMTPSA id c18sm17498763pfc.180.2019.06.18.10.55.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 18 Jun 2019 10:55:20 -0700 (PDT) Date: Tue, 18 Jun 2019 23:25:16 +0530 From: Hariprasad Kelam To: Greg Kroah-Hartman , John Whitmore , Hariprasad Kelam , Puranjay Mohan , devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: [PATCH] staging: rtl8192u: ieee80211: Remove redundant memset Message-ID: <20190618175516.GA6518@hari-Inspiron-1545> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org alloc_etherdev function internally calls kvzalloc . So we may not need explicit memset after this call. Signed-off-by: Hariprasad Kelam --- drivers/staging/rtl8192u/ieee80211/ieee80211_module.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/staging/rtl8192u/ieee80211/ieee80211_module.c b/drivers/staging/rtl8192u/ieee80211/ieee80211_module.c index 3532ea9..4a6c3f6 100644 --- a/drivers/staging/rtl8192u/ieee80211/ieee80211_module.c +++ b/drivers/staging/rtl8192u/ieee80211/ieee80211_module.c @@ -109,7 +109,6 @@ struct net_device *alloc_ieee80211(int sizeof_priv) } ieee = netdev_priv(dev); - memset(ieee, 0, sizeof(struct ieee80211_device) + sizeof_priv); ieee->dev = dev; err = ieee80211_networks_allocate(ieee); -- 2.7.4