Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp6016378ybe; Tue, 10 Sep 2019 12:11:48 -0700 (PDT) X-Google-Smtp-Source: APXvYqwed+14cDyA4bG0jQLeukhEK/A15tOrr/xsuhiRhQPAB6PaNv7jaf1CbF9pZFT36ZwwiZLI X-Received: by 2002:a50:f04e:: with SMTP id u14mr32549829edl.247.1568142708723; Tue, 10 Sep 2019 12:11:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568142708; cv=none; d=google.com; s=arc-20160816; b=aKMzKm0oZ8O5cbsdYa3LvB6m71ev4zkLzuCWqJ7haEtrm4f/MrBBV3/a/kJiu06TeG zBlXoggkKWtMmb6wpNY0FgPDlQlTICkLQQHxP6GIqSsQ05OzN5uf7eFDNnvtj3YCBs6/ qqWB2ZViUH6o/7Ut0XIeuookmYFqhd908275DDRlmImKFf6zv/8I1hUHSS+zixfr08a9 MAZPxW/ZK/Tc/fdsSJW4/Z/xLED6lM1hT3zMbkRxTzy/9Er/5HEhNhRs6o0wr9HW1ig9 zOde3iDAXIC5SAyDfLQvEQqAx4nepaUCU1NH1sQZxu6CijfJJE76XGw0GMDHQ2oiAI8F nCHQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:content-transfer-encoding:mime-version :message-id:date:subject:cc:from:dkim-signature; bh=YJ/xSRj04hb+Vjp0G8v57BGzk2RHL40NPxcaQuTTxb0=; b=I5gEjaRxRp/ix5IR2OyYsxApkTld2Mvc1oNW+wLiSARZZBE8OsfJ4tOEDGf1LVkZ9x WkDyRC+4q+QtZvr0tLzYqdXiFT191kY1xzGZUVL0Vc3vS6LjrP6fu9Frnq1emgECviaT 0CeX6apk1BkiSZbfvrawrOhsY6IDGIVNQK09K9iGSq/86bwt193SC9q2NrzhJcV0byYJ Bntvu4+yolKIeA1aSZEDaXlL/odFuGAokqND90V0n0VPzMToJ2TUYOPNXrl7M6MES+6o pj0qOoZ8YzAnUQmsg3XYtqcAaR0zxS7rhHSnny/aD057u/ahBnE3B5rpLLSem+YxHJmS kM5g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=NopmjHDf; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y34si12604768edc.276.2019.09.10.12.11.25; Tue, 10 Sep 2019 12:11:48 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=NopmjHDf; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391115AbfIJPze (ORCPT + 99 others); Tue, 10 Sep 2019 11:55:34 -0400 Received: from mail-wm1-f65.google.com ([209.85.128.65]:37661 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727457AbfIJPze (ORCPT ); Tue, 10 Sep 2019 11:55:34 -0400 Received: by mail-wm1-f65.google.com with SMTP id r195so163293wme.2; Tue, 10 Sep 2019 08:55:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=YJ/xSRj04hb+Vjp0G8v57BGzk2RHL40NPxcaQuTTxb0=; b=NopmjHDf1N0d3pOf0ECTnZpkWbC5PPwUogiwZsUwDTIwgEgQ47sCN/WtEU/LQLlPSv fZ9X9O89kZTEP6e7o3p9jm+rLnGIDG4++Rxp/zhxPi8gUhsz3x1lbkfKW3RtvUOKYtb/ Q53V94Qyzox2PxZnj6wzk0UiwSuCBZT1oQJ8M/mIyqnarV1hZuegeQj8J9SUyIV48f09 yVnsIrEGiUAWTJb81dWQdA9Y541KxvANRRMTlpY5vX1yHTjkB2/7v8ZvBXwQLqOXq7u9 uqboVrDdxLwGW1pquRt+1L+t0qtJ0+3ugritCgb7zcDdqRYZJTTFcaGyvz5stIAtXU/S J4KA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=YJ/xSRj04hb+Vjp0G8v57BGzk2RHL40NPxcaQuTTxb0=; b=kBwxLO9hEZVGswYPgvkRDae9JR139ZzRRdKln2dik7IX0/ks8gNe0I0vp06yZIjsG5 /cFds0QtSIjhiDL7ARb+Gt7LjBmsRUVXR7/WWd7mb2uztAp2DQlFPVF38PqwTrD4U8/p b2wf2nbZfnnO0HohrgiEdn6P2R7Bc1755QEgzQJx7FSQvNJdrrvKEdAzcuU8k/Ampf19 PjojXvCOTpYXWjl+LwKrpGsy8FPM+uuvPd9r5SrUoHFtE0hzEc19DQaIGNWs6BVf0wyZ QwxRoWidobP1TQHN23F9L76SwxL3PJ2F62u37/qW7AqP2TaCdV3VnxHcdF2XIo2ZPyRD 6npA== X-Gm-Message-State: APjAAAUsHnUemcjWzSRDey0wycsKw6GH4VgtsfsE9UkGfWHElxRhddcU MBzXvsiq+eTomsWzhEwdzxSjD8r5Uy8= X-Received: by 2002:a7b:c094:: with SMTP id r20mr143261wmh.134.1568130930147; Tue, 10 Sep 2019 08:55:30 -0700 (PDT) Received: from arch-dsk-01.twb ([77.126.41.65]) by smtp.gmail.com with ESMTPSA id y3sm17167133wrw.83.2019.09.10.08.55.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Sep 2019 08:55:29 -0700 (PDT) From: tinywrkb Cc: tinywrkb@gmail.com, Russell King , Rob Herring , Mark Rutland , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , devicetree@vger.kernel.org (open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS), linux-arm-kernel@lists.infradead.org (moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE), linux-kernel@vger.kernel.org (open list) Subject: [PATCH] ARM: dts: imx6dl: SolidRun: add phy node with 100Mb/s max-speed Date: Tue, 10 Sep 2019 18:55:07 +0300 Message-Id: <20190910155507.491230-1-tinywrkb@gmail.com> X-Mailer: git-send-email 2.23.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit To: unlisted-recipients:; (no To-header on input) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Cubox-i Solo/DualLite carrier board has 100Mb/s magnetics while the Atheros AR8035 PHY on the MicroSoM v1.3 CPU module is a 1GbE PHY device. Since commit 5502b218e001 ("net: phy: use phy_resolve_aneg_linkmode in genphy_read_status") ethernet is broken on Cubox-i Solo/DualLite devices. This adds a phy node to the MicroSoM DTS and a 100Mb/s max-speed limit to the Cubox-i Solo/DualLite carrier DTS. Signed-off-by: tinywrkb --- This patch fixes ethernet on my Cubox-i2-300-D which is limited to 100Mb/s, afaik due to the carrier board magnetics, and was since commit 5502b218e001 ("net: phy: use phy_resolve_aneg_linkmode in genphy_read_status") The AR8035 PHY on the CPU module reports to the driver as 1GbE capable via MII_BSMR's BMSR_ESTATEN status bit, the auto-negotiation sets the speed at 1GbE while the carrier board can't support it. Same behavior with the generic phy_device and the at803x drivers. While the PHY is on the CPU module board I added the max-speed limit to the cubox-i carrier DTS as I suspect that if the Solo or DualLite v1.3 MicroSoM will be connected to a 1GbE capable carrier board then it would work correctly with 1GbE. I can confirm that this commit doesn't break networking on the my Cubox-i4Pro Quad (i4P-300-D) with it's 1GbE capable carrier board, and was tested separately with the generic phy_device and at803x drivers. arch/arm/boot/dts/imx6dl-cubox-i.dts | 4 ++++ arch/arm/boot/dts/imx6qdl-sr-som.dtsi | 9 +++++++++ 2 files changed, 13 insertions(+) diff --git a/arch/arm/boot/dts/imx6dl-cubox-i.dts b/arch/arm/boot/dts/imx6dl-cubox-i.dts index 2b1b3e193f53..cfc82513c78c 100644 --- a/arch/arm/boot/dts/imx6dl-cubox-i.dts +++ b/arch/arm/boot/dts/imx6dl-cubox-i.dts @@ -49,3 +49,7 @@ model = "SolidRun Cubox-i Solo/DualLite"; compatible = "solidrun,cubox-i/dl", "fsl,imx6dl"; }; + +ðphy { + max-speed = <100>; +}; diff --git a/arch/arm/boot/dts/imx6qdl-sr-som.dtsi b/arch/arm/boot/dts/imx6qdl-sr-som.dtsi index 6d7f6b9035bc..969bc96c3f99 100644 --- a/arch/arm/boot/dts/imx6qdl-sr-som.dtsi +++ b/arch/arm/boot/dts/imx6qdl-sr-som.dtsi @@ -57,6 +57,15 @@ phy-reset-duration = <2>; phy-reset-gpios = <&gpio4 15 GPIO_ACTIVE_LOW>; status = "okay"; + phy-handle = <ðphy>; + mdio { + #address-cells = <1>; + #size-cells = <0>; + ethphy: ethernet-phy@0 { + compatible = "ethernet-phy-ieee802.3-c22"; + reg = <0>; + }; + }; }; &iomuxc { -- 2.23.0