[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220511132221.pkvi3g7agjm2xuph@skbuf>
Date: Wed, 11 May 2022 13:22:22 +0000
From: Ioana Ciornei <ioana.ciornei@....com>
To: Josua Mayer <josua@...id-run.com>
CC: "Russell King (Oracle)" <linux@...linux.org.uk>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"David S. Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>,
Rob Herring <robh+dt@...nel.org>, Andrew Lunn <andrew@...n.ch>,
Heiner Kallweit <hkallweit1@...il.com>
Subject: Re: [PATCH RFC] net: sfp: support assigning status LEDs to SFP
connectors
On Tue, May 10, 2022 at 12:44:41PM +0300, Josua Mayer wrote:
> One issue is that the interfaces don't have stable names. It purely depends
> on probe order,
> which is controlled by sending commands to the networking coprocessor.
>
> We actually get asked this question sometimes how to have stable device
> names, and so far the answer has been systemd services with explicit sleep
> to force the order.
> But this is a different topic.
>
Stable names can be achieved using some udev rules based on the OF node.
For example, I am using the following rules on a Clearfog CX LX2:
[root@...arfog-cx-lx2 ~] # cat /etc/udev/rules.d/70-persistent-net.rules
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="fsl_dpaa2_eth", ENV{OF_FULLNAME}=="/soc/fsl-mc@...000000/dpmacs/ethernet@7", NAME="eth7"
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="fsl_dpaa2_eth", ENV{OF_FULLNAME}=="/soc/fsl-mc@...000000/dpmacs/ethernet@8", NAME="eth8"
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="fsl_dpaa2_eth", ENV{OF_FULLNAME}=="/soc/fsl-mc@...000000/dpmacs/ethernet@9", NAME="eth9"
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="fsl_dpaa2_eth", ENV{OF_FULLNAME}=="/soc/fsl-mc@...000000/dpmacs/ethernet@a", NAME="eth10"
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="fsl_dpaa2_eth", ENV{OF_FULLNAME}=="/soc/fsl-mc@...000000/dpmacs/ethernet@11", NAME="eth17"
Ioana
Powered by blists - more mailing lists