From: Weifeng Voon <weifeng.voon@intel.com>
To: "David S. Miller" <davem@davemloft.net>
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
Ong Boon Leong <boon.leong.ong@intel.com>,
Kweh Hock Leong <hock.leong.kweh@intel.com>,
Weifeng Voon <weifeng.voon@intel.com>
Subject: [PATCH 6/7] net: stmmac: add xPCS platform data for EHL
Date: Thu, 25 Apr 2019 01:17:20 +0800 [thread overview]
Message-ID: <1556126241-2774-7-git-send-email-weifeng.voon@intel.com> (raw)
In-Reply-To: <1556126241-2774-1-git-send-email-weifeng.voon@intel.com>
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
next prev parent reply other threads:[~2019-04-24 9:17 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-24 17:17 [PATCH 0/7] net: stmmac: enable EHL SGMII Weifeng Voon
2019-04-24 9:26 ` Jose Abreu
2019-04-24 13:48 ` Andrew Lunn
2019-04-25 7:27 ` Voon, Weifeng
2019-04-25 12:38 ` Andrew Lunn
2019-04-25 14:39 ` Ong, Boon Leong
2019-04-25 15:23 ` Andrew Lunn
2019-04-29 5:37 ` Ong, Boon Leong
2019-04-29 13:10 ` Andrew Lunn
2019-04-29 13:44 ` Jose Abreu
2019-04-24 17:17 ` [PATCH 1/7] net: stmmac: add EHL SGMII 1Gbps platform data and PCI ID Weifeng Voon
2019-04-25 7:04 ` Voon, Weifeng
2019-04-25 12:24 ` Andrew Lunn
2019-04-26 2:10 ` Voon, Weifeng
2019-04-24 17:17 ` [PATCH 2/7] net: stmmac: enable clause 45 mdio support Weifeng Voon
2019-04-24 13:18 ` Andrew Lunn
2019-04-25 7:12 ` Voon, Weifeng
2019-04-24 17:17 ` [PATCH 3/7] net: stmmac: dma channel control register need to be init first Weifeng Voon
2019-04-25 7:06 ` Voon, Weifeng
2019-04-29 10:25 ` Jose Abreu
2019-04-30 2:49 ` Voon, Weifeng
2019-04-24 17:17 ` [PATCH 4/7] net: stmmac: introducing support for DWC xPCS logics Weifeng Voon
2019-04-24 13:41 ` Andrew Lunn
2019-04-25 1:45 ` Ong, Boon Leong
2019-04-25 3:21 ` Andrew Lunn
2019-04-25 6:51 ` Ong, Boon Leong
2019-04-25 12:22 ` Andrew Lunn
2019-04-25 7:06 ` Voon, Weifeng
2019-04-29 13:23 ` Jose Abreu
2019-04-24 17:17 ` [PATCH 5/7] net: stmmac: add xpcs function hooks into main driver and ethtool Weifeng Voon
2019-04-25 7:07 ` Voon, Weifeng
2019-04-24 17:17 ` Weifeng Voon [this message]
2019-04-25 7:08 ` [PATCH 6/7] net: stmmac: add xPCS platform data for EHL Voon, Weifeng
2019-04-24 17:17 ` [PATCH 7/7] net: stmmac: add xPCS functions for device with DWMACv5.1 Weifeng Voon
2019-04-25 7:09 ` Voon, Weifeng
2019-04-25 7:00 ` [PATCH 0/7] net: stmmac: enable EHL SGMII Voon, Weifeng
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1556126241-2774-7-git-send-email-weifeng.voon@intel.com \
--to=weifeng.voon@intel.com \
--cc=boon.leong.ong@intel.com \
--cc=davem@davemloft.net \
--cc=hock.leong.kweh@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).