mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@digeo.com>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: bunk@fs.tum.de, hch@infradead.org, linux-kernel@vger.kernel.org,
	linux-net@vger.kernel.org, fventuri@mediaone.net
Subject: Re: 2.5.69-mm5: sb1000.c: undefined reference to `alloc_netdev'
Date: Wed, 14 May 2003 12:41:06 -0700	[thread overview]
Message-ID: <20030514124106.5a13c199.akpm@digeo.com> (raw)
In-Reply-To: <1052936763.2492.57.camel@dhcp22.swansea.linux.org.uk>

Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:
>
> Its far from bogus. Its an rx only cable modem device. Your uplink is
> modem and you dont want to arp on it


diff -puN drivers/net/sb1000.c~sb1000-fix drivers/net/sb1000.c
--- 25/drivers/net/sb1000.c~sb1000-fix	Wed May 14 12:39:10 2003
+++ 25-akpm/drivers/net/sb1000.c	Wed May 14 12:40:20 2003
@@ -137,17 +137,6 @@ static const struct pnp_device_id sb1000
 };
 MODULE_DEVICE_TABLE(pnp, sb1000_pnp_ids);
 
-static void
-sb1000_setup(struct net_device *dev)
-{
-	dev->type		= ARPHRD_ETHER;
-	dev->mtu		= 1500;
-	dev->addr_len		= ETH_ALEN;
-
-	/* New-style flags. */
-	dev->flags		= IFF_POINTOPOINT|IFF_NOARP;
-}
-
 static int
 sb1000_probe_one(struct pnp_dev *pdev, const struct pnp_device_id *id)
 {
@@ -188,11 +177,18 @@ sb1000_probe_one(struct pnp_dev *pdev, c
 			"S/N %#8.8x, IRQ %d.\n", dev->name, dev->base_addr,
 			dev->mem_start, serial_number, dev->irq);
 
-	dev = alloc_netdev(sizeof(struct sb1000_private), "cm%d", sb1000_setup);
+	dev = alloc_etherdev(sizeof(struct sb1000_private));
 	if (!dev) {
 		error = -ENOMEM;
 		goto out_release_regions;
 	}
+
+	/*
+	 * The SB1000 is an rx-only cable modem device.  The uplink is a modem
+	 * and we do not want to arp on it.
+	 */
+	dev->flags = IFF_POINTOPOINT|IFF_NOARP;
+
 	SET_MODULE_OWNER(dev);
 
 	if (sb1000_debug > 0)

_


  reply	other threads:[~2003-05-14 19:32 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-14  8:29 2.5.69-mm5 Andrew Morton
2003-05-14 12:33 ` 2.5.69-mm5 Ed Tomlinson
2003-05-14 14:47 ` 2.5.69-mm5: sb1000.c: undefined reference to `alloc_netdev' Adrian Bunk
2003-05-14 17:31   ` Andrew Morton
2003-05-14 18:26     ` Alan Cox
2003-05-14 19:41       ` Andrew Morton [this message]
2003-05-15  1:49         ` David S. Miller
2003-05-14 21:45 ` 2.5.69-mm5: CONFIG_ACPI_SLEEP compile error Adrian Bunk
2003-05-14 22:51   ` Pavel Machek
2003-05-15  9:46     ` mikpe
2003-05-15 14:52       ` Pavel Machek
2003-05-15  9:29   ` mikpe
2003-05-15  8:59 ` 2.5.69-mm5 Helge Hafting
2003-05-15 19:51 ` 2.5.69-mm5 William Lee Irwin III

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=20030514124106.5a13c199.akpm@digeo.com \
    --to=akpm@digeo.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=bunk@fs.tum.de \
    --cc=fventuri@mediaone.net \
    --cc=hch@infradead.org \
    --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®