From patchwork Mon Apr 25 17:35:48 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aaron Sierra X-Patchwork-Id: 614564 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ozlabs.org (Postfix) with ESMTP id 3qttgN19gdz9sXR for ; Tue, 26 Apr 2016 03:36:15 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id ECC9F8AACD; Mon, 25 Apr 2016 17:36:13 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id P1P4Pre1z0Gu; Mon, 25 Apr 2016 17:36:13 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 510F28AA92; Mon, 25 Apr 2016 17:36:13 +0000 (UTC) X-Original-To: intel-wired-lan@lists.osuosl.org Delivered-To: intel-wired-lan@lists.osuosl.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id AE80D1C16B0 for ; Mon, 25 Apr 2016 17:36:10 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 985F78863E for ; Mon, 25 Apr 2016 17:36:10 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id RdHFjAJPuJaE for ; Mon, 25 Apr 2016 17:36:08 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from xes-mad.com (xes-mad.com [216.165.139.218]) by whitealder.osuosl.org (Postfix) with ESMTPS id 10D1F8861B for ; Mon, 25 Apr 2016 17:36:07 +0000 (UTC) Received: from zimbra.xes-mad.com (zimbra.xes-mad.com [10.52.0.127]) by xes-mad.com (8.13.8/8.13.8) with ESMTP id u3PHZnFR027554; Mon, 25 Apr 2016 12:35:49 -0500 Date: Mon, 25 Apr 2016 12:35:48 -0500 (CDT) From: Aaron Sierra To: Jochen Henneberg Message-ID: <985237851.71212.1461605748986.JavaMail.zimbra@xes-inc.com> In-Reply-To: <1461600045.21920.10.camel@maxwell> References: <1461577586.24438.14.camel@maxwell> <9BBC4E0CF881AA4299206E2E1412B626501BC575@ORSMSX102.amr.corp.intel.com> <9B4A1B1917080E46B64F07F2989DADD65ABFD85F@ORSMSX114.amr.corp.intel.com> <1768814989.41697.1461598056358.JavaMail.zimbra@xes-inc.com> <1461600045.21920.10.camel@maxwell> MIME-Version: 1.0 X-Originating-IP: [10.52.16.65] X-Mailer: Zimbra 8.0.6_GA_5922 (ZimbraWebClient - FF45 (Linux)/8.0.6_GA_5922) Thread-Topic: issue with kernel patch 2a3cdead8b408351fa1e3079b220fa331480ffbc Thread-Index: DUFXmgvEHPjHSc4DaK+ozH/1C9MJZA== Cc: intel-wired-lan@lists.osuosl.org Subject: Re: [Intel-wired-lan] issue with kernel patch 2a3cdead8b408351fa1e3079b220fa331480ffbc X-BeenThere: intel-wired-lan@lists.osuosl.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Intel Wired Ethernet Linux Kernel Driver Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-wired-lan-bounces@lists.osuosl.org Sender: "Intel-wired-lan" Jochen, > I wonder if this is related to the modified register read/write > after the patch. Possibly. The GS40G functions explicitly set the PHY page with every access. I suspect that your external I210 PHY was left with some other page selected (by your BIOS?). Try adding the following debug to your driver to see which page is selected: This is the output that I get from an external I210 device attached to a Bay Trail SoC: igb 0000:02:00.0: added PHC on eth0 igb 0000:02:00.0: Intel(R) Gigabit Ethernet Network Connection igb 0000:02:00.0: eth0: (PCIe:2.5Gb/s:Width x1) 00:17:3c:02:88:56 igb 0000:02:00.0: eth0: PBA No: FFFFFF-0FF igb 0000:02:00.0: Using MSI-X interrupts. 2 rx queue(s), 2 tx queue(s) igb: igb_init_phy_params_82575: default page: 0 igb: igb_init_phy_params_82575: PHY ID: 1410c00 -Aaron diff --git a/drivers/net/ethernet/intel/igb/e1000_82575.c b/drivers/net/ethernet index a23aa67..5cd9e91 100644 --- a/drivers/net/ethernet/intel/igb/e1000_82575.c +++ b/drivers/net/ethernet/intel/igb/e1000_82575.c @@ -226,6 +226,7 @@ static s32 igb_init_phy_params_82575(struct e1000_hw *hw) phy->ops.read_reg = igb_read_phy_reg_sgmii_82575; phy->ops.write_reg = igb_write_phy_reg_sgmii_82575; } else { + u16 page; switch (hw->mac.type) { case e1000_82580: case e1000_i350: @@ -234,6 +235,8 @@ static s32 igb_init_phy_params_82575(struct e1000_hw *hw) case e1000_i211: phy->ops.read_reg = igb_read_phy_reg_82580; phy->ops.write_reg = igb_write_phy_reg_82580; + phy->ops.read_reg(hw, I347AT4_PAGE_SELECT, &page); + pr_info("%s: default page: %x\n", __func__, page); break; default: phy->ops.read_reg = igb_read_phy_reg_igp; @@ -251,6 +254,7 @@ static s32 igb_init_phy_params_82575(struct e1000_hw *hw) return ret_val; /* Verify phy id and set remaining function pointers */ + pr_info("%s: PHY ID: %x\n", __func__, phy->id); switch (phy->id) { case M88E1543_E_PHY_ID: case M88E1512_E_PHY_ID: