#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/delay.h>
#include <linux/bitfield.h>
#include <linux/phy.h>
#include "aquantia.h"
#define PHY_ID_AQ1202 …
#define PHY_ID_AQ2104 …
#define PHY_ID_AQR105 …
#define PHY_ID_AQR106 …
#define PHY_ID_AQR107 …
#define PHY_ID_AQCS109 …
#define PHY_ID_AQR405 …
#define PHY_ID_AQR111 …
#define PHY_ID_AQR111B0 …
#define PHY_ID_AQR112 …
#define PHY_ID_AQR412 …
#define PHY_ID_AQR113 …
#define PHY_ID_AQR113C …
#define PHY_ID_AQR114C …
#define PHY_ID_AQR115C …
#define PHY_ID_AQR813 …
#define MDIO_PHYXS_VEND_IF_STATUS …
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_MASK …
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_KR …
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_KX …
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_XFI …
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_USXGMII …
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_XAUI …
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_SGMII …
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_RXAUI …
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_OCSGMII …
#define MDIO_AN_VEND_PROV …
#define MDIO_AN_VEND_PROV_1000BASET_FULL …
#define MDIO_AN_VEND_PROV_1000BASET_HALF …
#define MDIO_AN_VEND_PROV_5000BASET_FULL …
#define MDIO_AN_VEND_PROV_2500BASET_FULL …
#define MDIO_AN_VEND_PROV_DOWNSHIFT_EN …
#define MDIO_AN_VEND_PROV_DOWNSHIFT_MASK …
#define MDIO_AN_VEND_PROV_DOWNSHIFT_DFLT …
#define MDIO_AN_TX_VEND_STATUS1 …
#define MDIO_AN_TX_VEND_STATUS1_RATE_MASK …
#define MDIO_AN_TX_VEND_STATUS1_10BASET …
#define MDIO_AN_TX_VEND_STATUS1_100BASETX …
#define MDIO_AN_TX_VEND_STATUS1_1000BASET …
#define MDIO_AN_TX_VEND_STATUS1_10GBASET …
#define MDIO_AN_TX_VEND_STATUS1_2500BASET …
#define MDIO_AN_TX_VEND_STATUS1_5000BASET …
#define MDIO_AN_TX_VEND_STATUS1_FULL_DUPLEX …
#define MDIO_AN_TX_VEND_INT_STATUS1 …
#define MDIO_AN_TX_VEND_INT_STATUS1_DOWNSHIFT …
#define MDIO_AN_TX_VEND_INT_STATUS2 …
#define MDIO_AN_TX_VEND_INT_STATUS2_MASK …
#define MDIO_AN_TX_VEND_INT_MASK2 …
#define MDIO_AN_TX_VEND_INT_MASK2_LINK …
#define MDIO_AN_RX_LP_STAT1 …
#define MDIO_AN_RX_LP_STAT1_1000BASET_FULL …
#define MDIO_AN_RX_LP_STAT1_1000BASET_HALF …
#define MDIO_AN_RX_LP_STAT1_SHORT_REACH …
#define MDIO_AN_RX_LP_STAT1_AQRATE_DOWNSHIFT …
#define MDIO_AN_RX_LP_STAT1_AQ_PHY …
#define MDIO_AN_RX_LP_STAT4 …
#define MDIO_AN_RX_LP_STAT4_FW_MAJOR …
#define MDIO_AN_RX_LP_STAT4_FW_MINOR …
#define MDIO_AN_RX_VEND_STAT3 …
#define MDIO_AN_RX_VEND_STAT3_AFR …
#define AQR107_OP_IN_PROG_SLEEP …
#define AQR107_OP_IN_PROG_TIMEOUT …
static int aqr107_get_sset_count(struct phy_device *phydev)
{ … }
static void aqr107_get_strings(struct phy_device *phydev, u8 *data)
{ … }
static u64 aqr107_get_stat(struct phy_device *phydev, int index)
{ … }
static void aqr107_get_stats(struct phy_device *phydev,
struct ethtool_stats *stats, u64 *data)
{ … }
static int aqr_config_aneg(struct phy_device *phydev)
{ … }
static int aqr_config_intr(struct phy_device *phydev)
{ … }
static irqreturn_t aqr_handle_interrupt(struct phy_device *phydev)
{ … }
static int aqr_read_status(struct phy_device *phydev)
{ … }
static int aqr107_read_rate(struct phy_device *phydev)
{ … }
static int aqr107_read_status(struct phy_device *phydev)
{ … }
static int aqr107_get_downshift(struct phy_device *phydev, u8 *data)
{ … }
static int aqr107_set_downshift(struct phy_device *phydev, u8 cnt)
{ … }
static int aqr107_get_tunable(struct phy_device *phydev,
struct ethtool_tunable *tuna, void *data)
{ … }
static int aqr107_set_tunable(struct phy_device *phydev,
struct ethtool_tunable *tuna, const void *data)
{ … }
#define AQR_FW_WAIT_SLEEP_US …
#define AQR_FW_WAIT_TIMEOUT_US …
int aqr_wait_reset_complete(struct phy_device *phydev)
{ … }
static void aqr107_chip_info(struct phy_device *phydev)
{ … }
static int aqr107_config_init(struct phy_device *phydev)
{ … }
static int aqcs109_config_init(struct phy_device *phydev)
{ … }
static void aqr107_link_change_notify(struct phy_device *phydev)
{ … }
static int aqr107_wait_processor_intensive_op(struct phy_device *phydev)
{ … }
static int aqr107_get_rate_matching(struct phy_device *phydev,
phy_interface_t iface)
{ … }
static int aqr107_suspend(struct phy_device *phydev)
{ … }
static int aqr107_resume(struct phy_device *phydev)
{ … }
static const u16 aqr_global_cfg_regs[] = …;
static int aqr107_fill_interface_modes(struct phy_device *phydev)
{ … }
static int aqr113c_fill_interface_modes(struct phy_device *phydev)
{ … }
static int aqr115c_get_features(struct phy_device *phydev)
{ … }
static int aqr111_get_features(struct phy_device *phydev)
{ … }
static int aqr113c_config_init(struct phy_device *phydev)
{ … }
static int aqr107_probe(struct phy_device *phydev)
{ … }
static struct phy_driver aqr_driver[] = …;
module_phy_driver(aqr_driver);
static struct mdio_device_id __maybe_unused aqr_tbl[] = …;
MODULE_DEVICE_TABLE(mdio, aqr_tbl);
MODULE_DESCRIPTION(…) …;
MODULE_AUTHOR(…) …;
MODULE_LICENSE(…) …;