All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: netdev@oss.sgi.com
Subject: [PATCH] remove sdla from setup.c
Date: Wed, 28 May 2003 13:06:58 +0200	[thread overview]
Message-ID: <20030528110658.GA26411@lst.de> (raw)

sdla had calls from both Space.c and setup.c.  Leave the Space.c one
alone as per previous discussion but move over the setup.c one to
initcalls.  (and remove the prototype for a third one from setup.c!)


--- 1.14/drivers/net/setup.c	Tue May 27 01:32:22 2003
+++ edited/drivers/net/setup.c	Tue May 27 14:36:58 2003
@@ -13,8 +13,6 @@
 
 extern int scc_enet_init(void); 
 extern int fec_enet_init(void); 
-extern int sdla_setup(void); 
-extern int sdla_c_setup(void); 
 
 /*
  *	Devices in this list must do new style probing. That is they must
@@ -35,9 +33,6 @@
 #if defined(CONFIG_DMASCC)
 	{dmascc_init, 0},
 #endif	
-#if defined(CONFIG_SDLA)
-	{sdla_c_setup, 0},
-#endif
 #if defined(CONFIG_SCC_ENET)
         {scc_enet_init, 0},
 #endif
===== drivers/net/wan/sdla.c 1.10 vs edited =====
--- 1.10/drivers/net/wan/sdla.c	Sun May 18 17:18:07 2003
+++ edited/drivers/net/wan/sdla.c	Tue May 27 15:07:49 2003
@@ -1667,20 +1667,20 @@
 	.name = "sdla0",
 	.init = sdla_init
 };
+#endif /* MODULE */
 
-MODULE_LICENSE("GPL");
-
-int init_module(void)
+static int __init init_sdla(void)
 {
-	int result;
+	int result = 0;
 
 	sdla_c_setup();
-	if ((result = register_netdev(&sdla0)) != 0)
-		return result;
-	return 0;
+#ifdef MODULE
+	result = register_netdev(&sdla0);
+#endif
+	return result;
 }
 
-void cleanup_module(void)
+static void __exit exit_sdla(void)
 {
 	unregister_netdev(&sdla0);
 	if (sdla0.priv)
@@ -1688,4 +1688,8 @@
 	if (sdla0.irq)
 		free_irq(sdla0.irq, &sdla0);
 }
-#endif /* MODULE */
+
+MODULE_LICENSE("GPL");
+
+module_init(init_sdla);
+module_exit(exit_sdla);

             reply	other threads:[~2003-05-28 11:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-28 11:06 Christoph Hellwig [this message]
2003-05-29  9:57 ` [PATCH] remove sdla from setup.c David S. Miller
2003-05-29 15:36   ` Arnaldo Carvalho de Melo
2003-05-29 21:03     ` David S. 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=20030528110658.GA26411@lst.de \
    --to=hch@lst.de \
    --cc=netdev@oss.sgi.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.