netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: iwlwifi initial bugs/thanks
       [not found] <1171382436.12035.38.camel@localhost>
@ 2007-02-13 19:13 ` Jason Lunz
  2007-02-13 20:18   ` Pavel Roskin
  0 siblings, 1 reply; 2+ messages in thread
From: Jason Lunz @ 2007-02-13 19:13 UTC (permalink / raw)
  To: Ben Gamari; +Cc: ipw3945-devel, netdev

On Tue, Feb 13, 2007 at 04:00:36PM +0000, Ben Gamari wrote:
> That being said, now come the problems. When I first loaded the driver,
> I found that it had created two interfaces as mentioned in earlier
> threads. On my machine these are named eth1 and wlan0_rename (can
> someone confirm what the names are supposed to be and which interface
> does what?). Strangely, it appears that wlan0_rename is the actual
> wireless adapter as evidenced by the attached console session. In that

The "_rename" suffix is an indication that you have udev rules that are
attempting to assign the same name to two different netdevs. Try to
disable udev device renaming, or make the rules more specific.

The attached kernel patch makes it easier to figure out what udev is
trying to do in situations like yours. It keeps getting rejected from
linux upstream, but that could change with enough encouragement.

Jason


---

Keep track about which network interface names were renamed after the
network device driver printed its banner.

Signed-off-by: Olaf Hering <olaf@aepfle.de>

---
 net/core/dev.c |    4 ++++
 1 file changed, 4 insertions(+)

Index: linux-2.6.20-uml/net/core/dev.c
===================================================================
--- linux-2.6.20-uml.orig/net/core/dev.c
+++ linux-2.6.20-uml/net/core/dev.c
@@ -754,7 +754,11 @@
 	else if (__dev_get_by_name(newname))
 		return -EEXIST;
 	else
+	{
+		if (strncmp(newname, dev->name, IFNAMSIZ))
+			printk(KERN_INFO "%s renamed to %s\n", dev->name, newname);
 		strlcpy(dev->name, newname, IFNAMSIZ);
+	}
 
 	err = class_device_rename(&dev->class_dev, dev->name);
 	if (!err) {

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: iwlwifi initial bugs/thanks
  2007-02-13 19:13 ` iwlwifi initial bugs/thanks Jason Lunz
@ 2007-02-13 20:18   ` Pavel Roskin
  0 siblings, 0 replies; 2+ messages in thread
From: Pavel Roskin @ 2007-02-13 20:18 UTC (permalink / raw)
  To: Jason Lunz; +Cc: netdev, ipw3945-devel

On Tue, 2007-02-13 at 14:13 -0500, Jason Lunz wrote:
> The "_rename" suffix is an indication that you have udev rules that are
> attempting to assign the same name to two different netdevs. Try to
> disable udev device renaming, or make the rules more specific.
> 
> The attached kernel patch makes it easier to figure out what udev is
> trying to do in situations like yours. It keeps getting rejected from
> linux upstream, but that could change with enough encouragement.

I think it's a good idea.  Many drivers use the device name in the
diagnostic messages.  What's the point in seeing "wlan0: buffer
overflow" if there is no way to find out from the log what that "wlan0"
used to be?

> +		if (strncmp(newname, dev->name, IFNAMSIZ))
> +			printk(KERN_INFO "%s renamed to %s\n", dev->name, newname);

I think KERN_INFO is the right level, but maybe KERN_DEBUG would be more
readily accepted.

-- 
Regards,
Pavel Roskin


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-02-13 20:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <1171382436.12035.38.camel@localhost>
2007-02-13 19:13 ` iwlwifi initial bugs/thanks Jason Lunz
2007-02-13 20:18   ` Pavel Roskin

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).