[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20221116144305.2317573-1-xiaolei.wang@windriver.com>
Date: Wed, 16 Nov 2022 22:43:03 +0800
From: Xiaolei Wang <xiaolei.wang@...driver.com>
To: andrew@...n.ch, hkallweit1@...il.com, linux@...linux.org.uk,
davem@...emloft.net, edumazet@...gle.com, kuba@...nel.org,
pabeni@...hat.com
Cc: netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH 0/2] Add link between phy dev and mac dev
On imx6sx, there are two fec interfaces, but the external
phys can only be configured by fec0 mii_bus. That means
the fec1 can't work independently, it only work when the
fec0 is active. It is alright in the normal boot since the
fec0 will be probed first. But then the fec0 maybe moved
behind of fec1 in the dpm_list due to various device link.
So in system suspend and resume, we would get the following
warning when configuring the external phy of fec1 via the
fec0 mii_bus due to the inactive of fec0. In order to fix
this issue, we create a device link between phy dev and fec0.
This will make sure that fec0 is always active when fec1
is in active mode.
Therefore, in order to solve this kind of problem, an interface
function phy_mac_link_add is added to establish a link relationship
between phy dev and mac dev.
Xiaolei Wang (2):
net: phy: Add netdev link when multiple phys share a mdio
net: fec: net: fec: Create device link between fec0 and fec1
drivers/net/ethernet/freescale/fec_main.c | 4 +++-
drivers/net/phy/phy.c | 21 +++++++++++++++++++++
include/linux/phy.h | 1 +
3 files changed, 25 insertions(+), 1 deletion(-)
--
2.25.1
Powered by blists - more mailing lists