mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
net: dsa: allow switches driver to implement get/set EEE
Allow switches driver to query and enable/disable EEE on a per-port
basis by implementing the ethtool_{get,set}_eee settings and delegating
these operations to the switch driver.
set_eee() will need to coordinate with the PHY driver to make sure that
EEE is enabled, the link-partner supports it and the auto-negotiation
result is satisfactory.
Signed-off-by: Florian Fainelli <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
parent
b6d045db59
commit
7905288f09
2 changed files with 49 additions and 0 deletions
|
|
@ -232,6 +232,15 @@ struct dsa_switch_driver {
|
|||
struct phy_device *phy);
|
||||
void (*port_disable)(struct dsa_switch *ds, int port,
|
||||
struct phy_device *phy);
|
||||
|
||||
/*
|
||||
* EEE setttings
|
||||
*/
|
||||
int (*set_eee)(struct dsa_switch *ds, int port,
|
||||
struct phy_device *phydev,
|
||||
struct ethtool_eee *e);
|
||||
int (*get_eee)(struct dsa_switch *ds, int port,
|
||||
struct ethtool_eee *e);
|
||||
};
|
||||
|
||||
void register_switch_driver(struct dsa_switch_driver *type);
|
||||
|
|
|
|||
Loading…
Reference in a new issue