summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@armlinux.org.uk>2019-08-26 12:19:35 +0100
committerRussell King (Oracle) <rmk+kernel@armlinux.org.uk>2024-04-27 16:55:04 +0100
commit32d3af5918487438ec7aa5f61816389d84ad7b88 (patch)
tree0221231ebb32d7a642381f4defad27eb5facd981 /include/linux
parent7caea64f42f5d98c074b46a3168c291f30b7d0c7 (diff)
net: phy: provide phy driver start/stop hooks
Provide phy driver start/stop hooks so that the PHY driver knows when the network driver is starting or stopping. This will be used for the Marvell 10G driver so that we can sanely refuse to start if the PHYs firmware is not present, and also so that we can sanely support SFPs behind the PHY. Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/phy.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/phy.h b/include/linux/phy.h
index f45e5a059412..f6dcbd071637 100644
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
@@ -977,6 +977,9 @@ struct phy_driver {
/** @resume: Resume the hardware, restoring state if needed */
int (*resume)(struct phy_device *phydev);
+ int (*start)(struct phy_device *phydev);
+ void (*stop)(struct phy_device *phydev);
+
/**
* @config_aneg: Configures the advertisement and resets
* autonegotiation if phydev->autoneg is on,