From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tom Lendacky Subject: Re: C45 support and mdiobus_scan Date: Fri, 10 Aug 2018 10:20:56 -0500 Message-ID: References: <3bbd1d78-b896-2a81-83cf-7dad2f73bae9@synopsys.com> <20180809150309.GA20006@lunn.ch> <568ff5ce-02ac-40f9-ccf7-fa00fb9c6b2a@synopsys.com> <20180809152502.GC20006@lunn.ch> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Cc: "netdev@vger.kernel.org" To: Andrew Lunn , Jose Abreu Return-path: Received: from mail-cys01nam02on0077.outbound.protection.outlook.com ([104.47.37.77]:60900 "EHLO NAM02-CY1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727352AbeHJRvX (ORCPT ); Fri, 10 Aug 2018 13:51:23 -0400 In-Reply-To: <20180809152502.GC20006@lunn.ch> Content-Language: en-US Sender: netdev-owner@vger.kernel.org List-ID: On 8/9/2018 10:25 AM, Andrew Lunn wrote: >>> The PCIe core will look in the device tree and when it creates the >>> platform device for the i210 on the pcie bus, it points >>> pdev->dev.of_node at this node. So long as you are using a platform >>> with DT, you can do this. I hope you are not using x86.. >> >> Yes I am :( Any possible solution for this? I haven't looked too closely, but maybe you can add a new mdiobus_scan function for 10G that attempts get_phy_device() with is_c45 set to true and if nothing is found falls back to get_phy_device() with is_c45 set to false. I don't know what would happen if you have a non-c45 phy attached, but it's worth a shot to try it and see for each situation. Thanks, Tom > > Well, DT can be used with x86. I think Edison did that. But i assume > your PCIe host is in ACPI, not DT. So getting this linking working > will not be easy. > > There has been some work to add an ACPI binding for PHYs. I don't know > if it actually got far enough that you can hack your DSDT to add a > PHY. But i'm sure it did not get far enough that you can describe an > MDIO bus in DSDT, so it probably is not going to help you. > >> I guess in ultimate case I will have to switch to ARM based setup. > > Yes, or MIPS. > > Andrew >