lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 2 Feb 2015 21:46:23 -0800
From:	Scott Feldman <sfeldma@...il.com>
To:	David Ahern <dsahern@...il.com>
Cc:	Florian Fainelli <f.fainelli@...il.com>,
	Netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH] net: rocker: Change netdev names to include slot number

On Mon, Feb 2, 2015 at 2:09 PM, David Ahern <dsahern@...il.com> wrote:
> On 2/2/15 3:03 PM, Florian Fainelli wrote:
>>
>> Why not? virtio and rocker interfaces are backed by different devices
>> drivers which should allow you to use that to name interfaces
>> differently. In the case of rocker, you would probably want to read the
>> phys_port_id sysfs attribute to name them after their parent switch id
>> too.
>
>
> [root@f21 ~]# cat /sys/devices/virtual/net/sw5p0/phys_port_id
> cat: /sys/devices/virtual/net/sw5p0/phys_port_id: Operation not supported

We should implement .ndo_get_phys_port_id in rocker to return a unique
name for the port, which can then be used in udev script to name
interface.  When rocker device is instantiated, a unique switch name
is given on qemu cmd line, for example "sw1".  Rocker device could
return that string to the driver, or even combine that string with the
port index to have "sw1p1".  The second instantiated rocker device
would give up "sw2px" port names.

A real switch with a physical port than can be split, or when multiple
ports are ganged to form one mega port, letting the device pick a
unique name is probably best.  For example, splitting a single
physical 40Gb port into 4 10Gb ports would present 4 kernel
interfaces, but we probably want to use the base port in the naming,
so we'd have something like "sw1p1s1" to mean switch 1, front panel
port 1, split port 1.  Letting the device name the ports on current
port configuration of the port will keep driver/kernel simple, and let
udev be the final name chooser.

>
> But in general I guess need to find time to figure out systemd-udev files.
>
> David
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ