diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2013-12-11 10:58:00 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2013-12-11 10:58:02 +0100 |
commit | 33790253da63facab20f5ae664debba0627344df (patch) | |
tree | 5b1a255841bd950865c6bffd83aa832165f81426 /include | |
parent | d023d690fc6fd051faa77666777d9664e0e5e7e3 (diff) | |
download | barebox-33790253da63facab20f5ae664debba0627344df.tar.gz barebox-33790253da63facab20f5ae664debba0627344df.tar.xz |
net: phy: track registered state of a phy device
With this phy_device_connect only registers a phy device if it wasn't
registered already. This allows us to register phy devices outside
of ethernet drivers. phy_device_connect will now pick up an already
registered phy given that it's not attached to another ethernet device.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/phy.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/phy.h b/include/linux/phy.h index a1c629e9dc..19e4d20662 100644 --- a/include/linux/phy.h +++ b/include/linux/phy.h @@ -161,6 +161,8 @@ struct phy_device { int autoneg; int force; + int registered; + /* private data pointer */ /* For use by PHYs to maintain extra state */ void *priv; |