login
Header Space

 
 

Re: udev can't name PS3's network devices correctly

Score:
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Marco d'Itri <md@...>
Cc: Harald Hoyer <harald@...>, <linux-hotplug@...>, <netdev@...>
Date: Monday, April 14, 2008 - 9:38 am

On Mon, 2008-04-14 at 14:51 +0200, Marco d'Itri wrote: 

And when they do, they change the name that userspace sees. Film at 11 :)


I wouldn't put it like that. We are looking for some way to tell the
difference between the two interfaces. If the kernel uses a different
basename (wlan%d vs. eth%d, or eth%d vs. msh%d), that's a fairly strong
hint about which is which -- and is fairly reliable to boot.

The dev_id provides _another_ strong hint which helps us tell which
device is which, but that doesn't mean that using the basename is wrong.


The low 64 bits of the autoconfigured IPv6 address are derived from the
MAC address, so for example a MAC address of 00:50:43:28:0A:FC would
give you an IPv6 link-local address of fe80::250:43ff:fe28:afc -- and a
corresponding global address like 2001:8b0:10b:1:250:43ff:fe28:afc.

When you set dev_id to anything other than zero, that 'ff:fe' in the
middle changes. So with my patches, the mesh device on the same libertas
hardware becomes fe80::50:4300:128:afc -- using the newly-provided
dev_id (0x0001) instead of 0xFFFE.

See net/ipv6/addrconf.c for more details. But basically, it means we are
changing the public IPv6 addresses of the affected machines, just to
help udev tell the difference between the interfaces -- when in fact, it
already _could_ tell the difference, due to the kernel's choice of name.

We should do the dev_id thing in sysfs and udev anyway, because there
are cases where it's the right thing to do (like S390, where I think
it'll let us drop the existing hack we have, and probably also the Sun
hardware you mention).

But I don't think we should add dev_id to the gelic and libertas
drivers. We should just make write_net_rules consistently include the
KERNEL criterion -- even when $INTERFACE_NAME is set. It does it in all
other cases anyway, now.


It's not a problem which is limited to PS3.

-- 
dwmw2

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: udev can't name PS3's network devices correctly, David Woodhouse, (Mon Apr 14, 6:08 am)
Re: udev can't name PS3's network devices correctly, Marco d'Itri, (Mon Apr 14, 8:51 am)
Re: udev can't name PS3's network devices correctly, David Woodhouse, (Mon Apr 14, 9:38 am)
Re: udev can't name PS3's network devices correctly, Kay Sievers, (Mon Apr 14, 8:03 am)
Re: udev can't name PS3's network devices correctly, David Woodhouse, (Mon Apr 14, 8:19 am)
Re: udev can't name PS3's network devices correctly, Kay Sievers, (Mon Apr 14, 8:52 am)
Re: udev can't name PS3's network devices correctly, David Woodhouse, (Mon Apr 14, 9:16 am)
Re: udev can't name PS3's network devices correctly, David Woodhouse, (Mon Apr 14, 7:11 am)
Re: udev can't name PS3's network devices correctly, Kay Sievers, (Mon Apr 14, 7:55 am)
Re: udev can't name PS3's network devices correctly, David Woodhouse, (Sun Apr 27, 1:37 pm)
Re: udev can't name PS3's network devices correctly, Kay Sievers, (Sun Apr 27, 2:28 pm)
[PATCH] Expose netdevice dev_id through sysfs, David Woodhouse, (Sun Apr 20, 7:22 am)
[PATCH] Expose netdevice dev_id through sysfs, David Woodhouse, (Mon Apr 14, 8:32 am)
Re: [PATCH] Expose netdevice dev_id through sysfs, David Miller, (Sat Apr 19, 9:33 pm)
Re: [PATCH] Expose netdevice dev_id through sysfs, David Woodhouse, (Sun Apr 20, 6:50 am)
Re: [PATCH] Expose netdevice dev_id through sysfs, David Miller, (Sun Apr 20, 6:55 am)
Re: [PATCH] Expose netdevice dev_id through sysfs, David Woodhouse, (Sun Apr 20, 7:12 am)
Re: [PATCH] Expose netdevice dev_id through sysfs, David Miller, (Sun Apr 20, 7:14 am)
Re: [PATCH] Expose netdevice dev_id through sysfs, Andrey Borzenkov, (Sun Apr 20, 1:21 am)
Re: [PATCH] Expose netdevice dev_id through sysfs, David Miller, (Sun Apr 20, 1:32 am)
speck-geostationary