Re: Ethernet interface naming problem in kernel 2.6.12.6

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> The normal flow for name is:
>
> 	alloc_etherdev creates net device with name "eth%d"
> 	register_netdev calls dev_alloc_name that changes it to "eth0"
> 		it first builds a bitmap of existing network devices
> 		then does snprintf to stack buffer
> 		followed by strlcpy
>
>
> You should also add printk to net/core/dev.c::dev_change_name(), there
> may be user space tools that are responding to hotplug event and
> doing something wacky.
>
> Since you are building from scratch, I would also make sure you
> aren't using a broken version of GCC. As I recall 4.0 was broken.

Hi!

Thanks for the leads. Will check out eth.c for alloc_etherdev and code paths 
using register_netdev, dev_alloc_name. Tricky bits. 

BTW, Used GCC 3.3.3 for the kernel compile, and yep I do use the hotplug 
subsystem on startup to load loadable modules. Also, my kernel is patched to 
use software suspend 2.1.9.5. Will try recompiling on a clean kernel tree 
using gcc 2.95.3 and see whether the problem goes away, and then repatch. 
Will also try building networking device driver modules into the kernel, and 
then fully modular kernel. 

Oh boy, it'll be a long weekend... :-D
-
: send the line "unsubscribe linux-net" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux 802.1Q VLAN]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Git]     [Bugtraq]     [Yosemite News and Information]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux PCI]     [Linux Admin]     [Samba]

  Powered by Linux