netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tobias Klauser <tklauser@distanz.ch>
To: "David S. Miller" <davem@davemloft.net>
Cc: netdev@vger.kernel.org, Tobias Klauser <tklauser@distanz.ch>
Subject: [PATCH] dm9000: Remove unnecessary memset of netdev private data
Date: Wed,  9 Sep 2009 13:07:44 +0200	[thread overview]
Message-ID: <1252494464-4633-2-git-send-email-tklauser@distanz.ch> (raw)
In-Reply-To: <1252494464-4633-1-git-send-email-tklauser@distanz.ch>

The memory for the private data is allocated using kzalloc in
alloc_etherdev (or alloc_netdev_mq respectively) so there is no need to
set it to 0 again.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
---
 drivers/net/dm9000.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/net/dm9000.c b/drivers/net/dm9000.c
index 00a9db8..11995ad 100644
--- a/drivers/net/dm9000.c
+++ b/drivers/net/dm9000.c
@@ -1213,7 +1213,6 @@ dm9000_probe(struct platform_device *pdev)
 
 	/* setup board info structure */
 	db = netdev_priv(ndev);
-	memset(db, 0, sizeof(*db));
 
 	db->dev = &pdev->dev;
 	db->ndev = ndev;
-- 
1.6.0.4


  reply	other threads:[~2009-09-09 11:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-09 11:07 [PATCH] dm9000: Use resource_size instead of private macro Tobias Klauser
2009-09-09 11:07 ` Tobias Klauser [this message]
2009-09-10  1:55   ` [PATCH] dm9000: Remove unnecessary memset of netdev private data David Miller
2009-09-10  1:55 ` [PATCH] dm9000: Use resource_size instead of private macro 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=1252494464-4633-2-git-send-email-tklauser@distanz.ch \
    --to=tklauser@distanz.ch \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    /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).