mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Greg Ungerer <gerg@snapgear.com>
To: torvalds@linux-foundation.org
Cc: akpm@linux-foundation.org, gerg@uclinux.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH] m68knommu: kill warnings in FEC driver
Date: Thu, 1 May 2008 14:04:02 +1000	[thread overview]
Message-ID: <200805010404.m41442Ef004838@goober> (raw)

From: Sebastian Siewior <bigeasy@linutronix.de>

linux-2.6-mk68/drivers/net/fec.c: In function 'fec_enet_module_init':
linux-2.6-mk68/drivers/net/fec.c:2627: warning: unused variable 'j'
linux-2.6-mk68/drivers/net/fec.c: At top level:
linux-2.6-mk68/drivers/net/fec.c:2136: warning: 'mii_link_interrupt' defined but not used

Signed-off-by: Sebastian Siewior <bigeasy@linutronix.de>
Signed-off-by: Greg Ungerer <gerg@uclinux.org>
---


diff -Naurp linux-2.6.25/drivers/net/fec.c linux-2.6.25-uc0/drivers/net/fec.c
--- linux-2.6.25/drivers/net/fec.c	2008-04-17 12:49:44.000000000 +1000
+++ linux-2.6.25-uc0/drivers/net/fec.c	2008-04-30 13:39:06.000000000 +1000
@@ -67,6 +67,10 @@
 #define	FEC_MAX_PORTS	1
 #endif
 
+#if defined(CONFIG_FADS) || defined(CONFIG_RPXCLASSIC) || defined(CONFIG_M5272)
+#define HAVE_mii_link_interrupt
+#endif
+
 /*
  * Define the fixed address of the FEC hardware.
  */
@@ -1222,7 +1226,7 @@ static phy_info_t const * const phy_info
 };
 
 /* ------------------------------------------------------------------------- */
-#if !defined(CONFIG_M532x)
+#ifdef HAVE_mii_link_interrupt
 #ifdef CONFIG_RPXCLASSIC
 static void
 mii_link_interrupt(void *dev_id);
@@ -2096,6 +2100,7 @@ mii_discover_phy(uint mii_reg, struct ne
 
 /* This interrupt occurs when the PHY detects a link change.
 */
+#ifdef HAVE_mii_link_interrupt
 #ifdef CONFIG_RPXCLASSIC
 static void
 mii_link_interrupt(void *dev_id)
@@ -2118,6 +2123,7 @@ mii_link_interrupt(int irq, void * dev_i
 
 	return IRQ_HANDLED;
 }
+#endif
 
 static int
 fec_enet_open(struct net_device *dev)
@@ -2596,7 +2602,7 @@ fec_stop(struct net_device *dev)
 static int __init fec_enet_module_init(void)
 {
 	struct net_device *dev;
-	int i, j, err;
+	int i, err;
 	DECLARE_MAC_BUF(mac);
 
 	printk("FEC ENET Version 0.2\n");

                 reply	other threads:[~2008-05-01  4:05 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=200805010404.m41442Ef004838@goober \
    --to=gerg@snapgear.com \
    --cc=akpm@linux-foundation.org \
    --cc=gerg@uclinux.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.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®