Messages in this thread Patch in this message | | | From | Weifeng Voon <> | Subject | [PATCH 6/7] net: stmmac: add xPCS platform data for EHL | Date | Thu, 25 Apr 2019 01:17:20 +0800 |
| |
Enable xPCS capability inside EHL platform data.
Signed-off-by: Weifeng Voon <weifeng.voon@intel.com> --- drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c | 5 +++++ 1 file changed, 5 insertions(+)
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c index b454a97..daac2eb 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c @@ -23,6 +23,7 @@ #include <linux/dmi.h> #include "stmmac.h" +#include "dw_xpcs.h" /* * This struct is used to associate PCI Function of MAC controller on a board, @@ -128,6 +129,8 @@ static int ehl_common_data(struct pci_dev *pdev, plat->clk_csr = 5; plat->has_gmac = 0; plat->has_gmac4 = 1; + plat->xpcs_phy_addr = 0x16; + plat->pcs_mode = AN_CTRL_PCS_MD_C37_SGMII; plat->force_sf_dma_mode = 0; plat->tso_en = 1; @@ -211,6 +214,7 @@ static int ehl_sgmii1g_data(struct pci_dev *pdev, return ret; plat->interface = PHY_INTERFACE_MODE_SGMII; + plat->has_xpcs = 1; return 0; } @@ -387,6 +391,7 @@ static int stmmac_pci_probe(struct pci_dev *pdev, res.addr = pcim_iomap_table(pdev)[i]; res.wol_irq = pdev->irq; res.irq = pdev->irq; + res.xpcs_irq = 0; return stmmac_dvr_probe(&pdev->dev, plat, &res); } -- 1.9.1
| |