mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Adrian Bunk <bunk@stusta.de>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: linux-net@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [2.6 patch] drivers/net/lp486e.c: make some code static
Date: Mon, 21 Feb 2005 15:47:48 +0100	[thread overview]
Message-ID: <20050221144748.GB3187@stusta.de> (raw)
In-Reply-To: <42193DA2.9050606@pobox.com>

On Sun, Feb 20, 2005 at 08:47:14PM -0500, Jeff Garzik wrote:
>...
> >+#if 0
> >+static char *CUcmdnames[8] = { "NOP", "IASetup", "Configure", 
> >"MulticastList",
> >+			       "Tx", "TDR", "Dump", "Diagnose" };
> >+#endif
> 
> Need const.


Updated patch:


<--  snip  -->


This patch makes some needlessly global code static and makes
CUcmdnames const.

Signed-off-by: Adrian Bunk <bunk@stusta.de>

---

 drivers/net/lp486e.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

--- linux-2.6.11-rc3-mm2-full/drivers/net/lp486e.c.old	2005-02-16 16:08:34.000000000 +0100
+++ linux-2.6.11-rc3-mm2-full/drivers/net/lp486e.c	2005-02-16 16:15:33.000000000 +0100
@@ -112,8 +112,10 @@
 	CmdDiagnose = 7
 };
 
-char *CUcmdnames[8] = { "NOP", "IASetup", "Configure", "MulticastList",
-			"Tx", "TDR", "Dump", "Diagnose" };
+#if 0
+static const char *CUcmdnames[8] = { "NOP", "IASetup", "Configure", "MulticastList",
+				     "Tx", "TDR", "Dump", "Diagnose" };
+#endif
 
 /* Status word bits */
 #define	STAT_CX		0x8000	/* The CU finished executing a command
@@ -960,7 +962,7 @@
 		(unsigned char) add[12], (unsigned char) add[13]);
 }
 
-int __init lp486e_probe(struct net_device *dev) {
+static int __init lp486e_probe(struct net_device *dev) {
 	struct i596_private *lp;
 	unsigned char eth_addr[6] = { 0, 0xaa, 0, 0, 0, 0 };
 	unsigned char *bios;



      reply	other threads:[~2005-02-21 14:48 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-02-17 20:54 Adrian Bunk
2005-02-21  1:47 ` Jeff Garzik
2005-02-21 14:47   ` Adrian Bunk [this message]

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=20050221144748.GB3187@stusta.de \
    --to=bunk@stusta.de \
    --cc=jgarzik@pobox.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-net@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

all inboxes | Powered by JetHome®