From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ben Hutchings Date: Fri, 16 Oct 2009 15:33:13 +0000 Subject: Re: PATCH: Network Device Naming mechanism and policy Message-Id: <1255707193.2869.12.camel@achroite> List-Id: References: <20091009140000.GA18765@mock.linuxdev.us.dell.com> <20091013150839.GD32107@ldl.fc.hp.com> <20091013173638.GE1119@ldl.fc.hp.com> <20091016003245.GD29672@ldl.fc.hp.com> <20091016152053.GA9862@ldl.fc.hp.com> In-Reply-To: <20091016152053.GA9862@ldl.fc.hp.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: dann frazier Cc: Narendra_K@Dell.com, netdev@vger.kernel.org, linux-hotplug@vger.kernel.org, Matt_Domsch@Dell.com, Jordan_Hargrave@Dell.com, Charles_Rose@Dell.com On Fri, 2009-10-16 at 09:20 -0600, dann frazier wrote: > On Fri, Oct 16, 2009 at 07:32:50PM +0530, Narendra_K@Dell.com wrote: [...] > > And how would the regular file look like in terms of holding ifindex of > > the interface, which can be passed to libnetdevname. > > I can't think of anything we need to store in the regular file. If we > have the kernel name for the device, we can look up the ifindex in > /sys. Correct me if I'm wrong, but storing it ourselves seems > redundant. But the name of a netdev can change whereas its ifindex never does. Identifying netdevs by name would require additional work to update the links when a netdev is renamed and would still be prone to race conditions. This is why Narendra and Matt were proposing to store the ifindex in the node all along... Ben. -- Ben Hutchings, Senior Software Engineer, Solarflare Communications Not speaking for my employer; that's the marketing department's job. They asked us to note that Solarflare product names are trademarked.