diff options
author | Igor Russkikh <irusskikh@marvell.com> | 2020-10-05 18:39:39 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-10-06 06:16:01 -0700 |
commit | 60db5e408e432d57f93e1eaec8fc9d7a05caa1f9 (patch) | |
tree | 6464701adb7436481e0df986de6f52897d31e352 /drivers/net/ethernet/aquantia/atlantic/aq_hw.h | |
parent | e193c3ab8302908b1378fc0606be561e976d2532 (diff) | |
download | linux-next-60db5e408e432d57f93e1eaec8fc9d7a05caa1f9.tar.gz |
net: atlantic: implement media detect feature via phy tunables
Mediadetect is another name for the EDPD (energy detect power down).
This feature allows device to save extra power when no link is available.
PHY goes into the extreme power saving mode and only periodically wakes up
and checks for the link.
AQC devices has fixed check period of 6 seconds
The feature may increase linkup time.
Signed-off-by: Igor Russkikh <irusskikh@marvell.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/aquantia/atlantic/aq_hw.h')
-rw-r--r-- | drivers/net/ethernet/aquantia/atlantic/aq_hw.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/ethernet/aquantia/atlantic/aq_hw.h b/drivers/net/ethernet/aquantia/atlantic/aq_hw.h index a17077b0dd49..bed481816ea3 100644 --- a/drivers/net/ethernet/aquantia/atlantic/aq_hw.h +++ b/drivers/net/ethernet/aquantia/atlantic/aq_hw.h @@ -143,6 +143,8 @@ struct aq_stats_s { #define AQ_HW_LED_BLINK 0x2U #define AQ_HW_LED_DEFAULT 0x0U +#define AQ_HW_MEDIA_DETECT_CNT 6000 + enum aq_priv_flags { AQ_HW_LOOPBACK_DMA_SYS, AQ_HW_LOOPBACK_PKT_SYS, @@ -388,6 +390,8 @@ struct aq_fw_ops { int (*set_downshift)(struct aq_hw_s *self, u32 counter); + int (*set_media_detect)(struct aq_hw_s *self, bool enable); + u32 (*get_link_capabilities)(struct aq_hw_s *self); int (*send_macsec_req)(struct aq_hw_s *self, |