Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp522418ybh; Wed, 15 Jul 2020 08:11:35 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxoRlioaJszM09qfVXQwM5AGv2GSJIpmaGO6mAsOyibXMwy7cgkKRwz82Cl19s7x2unCp6d X-Received: by 2002:a50:fe16:: with SMTP id f22mr46454edt.315.1594825895149; Wed, 15 Jul 2020 08:11:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594825895; cv=none; d=google.com; s=arc-20160816; b=XqMKXpDE3LJ4S6yutNgAP/rslwMHykWATrRhZUd7ce0wwxAFXrOM8SgVE5K4txkP/U 5zV6qobDWKQojrGv7aqI+21oGAzrXvZj+wgpbi1bko0krLNSdjsaWhxKlAxY+YfOOUrd kqseT/Hn5Sec/LlcBTreHoe5NnKWkr7FsawGtNXRtGXx7/wLSRYvk44pl7+BsHp1wVvW FlXf0jzr+U+3+zLviC0kybeUT5/JBa1eBT2+jJwryqvP/0EMQa5BG+5QBMaCUxAr0t3D L34am1vGugqozXI2BTABYQIF33v1PhZPVtpXfpxI0qmcYa9INuHPIexsoxc53WAcYdM6 5QAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=J4YLq7ad8Ku7+EWFa0/mgk39lvRv5vsUDuPSLGAmMis=; b=bWrNb0QXfXAyYaNNup330+LCV2c7dXr16uFPWuvKFrQCr9QGE6Z6+toJCC0rZwLOhY /4ktdpmUG6u4MJCr5/1UlbVObOus6EeNmaxPKtqIWbJyGFGNlSmRQsf3S35DDB8UzviN 2OSlTi6NAR38aDk/1Fkqu5NeVPS1a8HICoQKMT+32T8QHsMsnqC+t34KLa8+JcGA5wK2 FLYrKXCazRJXbNt1qoEACrucdK3FHmbgSn6mdwhOphKkH83eAaVBR15267cbIFb56m9U oiGvIHrXeUBRUjax0kVZ8m+eKdMaFG7w7cTMBmtQ3C4EgA/abLFNpUzheDrrnQHdXbUd V4dA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=lCcrKo0G; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h17si1275158ejl.514.2020.07.15.08.11.11; Wed, 15 Jul 2020 08:11:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=lCcrKo0G; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728277AbgGOOWN (ORCPT + 99 others); Wed, 15 Jul 2020 10:22:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50228 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728121AbgGOOWN (ORCPT ); Wed, 15 Jul 2020 10:22:13 -0400 Received: from mail-ed1-x543.google.com (mail-ed1-x543.google.com [IPv6:2a00:1450:4864:20::543]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A1DDEC061755; Wed, 15 Jul 2020 07:22:12 -0700 (PDT) Received: by mail-ed1-x543.google.com with SMTP id e22so1741283edq.8; Wed, 15 Jul 2020 07:22:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=J4YLq7ad8Ku7+EWFa0/mgk39lvRv5vsUDuPSLGAmMis=; b=lCcrKo0G+0r8E1QGKPPSeKTD6jPE8Sc6irv4/pOM95bnJP53927eRuCyYXGeGkV9fd 4mAETYDfMMhmValjwwKkzgyw6wNRUSM7HPaYym0azD4zlCU3nckTdg4+j1Wc53w3nOHA O1x4YZWvOSoxt6Ki5XkR4PxFJ2sl5ih71h1LHgcgiViNmWv4Groshm3PXgvKN4TJT7MH 8TG+hVZ4AaNClt0XH3+2cPGeaAwLX9Nb/XP5ixDGbggf5vtZTfFJFyppqTL9x3mDCHfO b4nFyNmrOU8X1KLO5q+5txBX/3CO8n6xnjqpC15H43ua/BRMEViLX4C0QztCHodDD7LN K3Lg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=J4YLq7ad8Ku7+EWFa0/mgk39lvRv5vsUDuPSLGAmMis=; b=QnnOxpkqv+u1t8KK3xMYa9Yrr8zxinQg/TiQhXW6HKaqXwTb8YDuxcwcpMg/uSMX8C mGJXWH7TrPxXfPxxzI2Y/L9CXae1Z+GCBQseMxcC/sWEe03Qi5pKjiPRxasWZpKlpOfA 68lV9obOIVHdNEa/A8f/qVSgeBi+0l6agET/daP1o4n7GdHJvGlm1KgmO52NAulYf7E3 P1nLpLCujJSq8f3c3bUZXr0Xw/XfaKjfU+WUcxmv4hDxB40X3C+p22FHKSiSn7hI2RKm ExQRNotLtXYo9lLhlhjG59xNTkCA73A+3qYwg2te5zU3k9tDXdaU3/0G63uhAyoZT7R0 KW/Q== X-Gm-Message-State: AOAM530TkmiGvG4+pfIc07Q4Nd9IQ9Ay98/lTwLnRsug4gZmdJm6JKgD PR0cQs8nBPpItyZb3qEDKqApGXadPN4DDq3Oxuo= X-Received: by 2002:aa7:c3d7:: with SMTP id l23mr9596809edr.18.1594822931168; Wed, 15 Jul 2020 07:22:11 -0700 (PDT) MIME-Version: 1.0 References: <20200629114927.17379-1-bruno.thomsen@gmail.com> <20200629114927.17379-2-bruno.thomsen@gmail.com> <20200713025246.GY21277@dragon> In-Reply-To: From: Bruno Thomsen Date: Wed, 15 Jul 2020 16:21:55 +0200 Message-ID: Subject: Re: [PATCH 2/3] ARM: dts: imx7: add support for kamstrup flex concentrator To: Fabio Estevam Cc: Shawn Guo , open list , "moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE" , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , Rob Herring , Pengutronix Kernel Team , NXP Linux Team , Bruno Thomsen , Mauro Carvalho Chehab Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Den tir. 14. jul. 2020 kl. 13.54 skrev Fabio Estevam : > > Hi Bruno, > > On Tue, Jul 14, 2020 at 7:03 AM Bruno Thomsen wrote: > > > I have not yet been successful in converting the deprecated properties > > to generic phy properties, so hoping I could get a hit. > > > > Kernel error messages: > > mdio_bus 30be0000.ethernet-1: MDIO device at address 1 is missing. > > Please double-check whether 1 is the correct address for the KSZ8051 > Ethernet PHY as per your schematics. Hi Fabio, Thanks for the hints. Yes, the address is correct and configured with external resistors, but just realised that I wrote the wrong device name in the comment, it's actually KSZ8081RNB. Ethernet has been working with multiple mainline kernel versions (latest being 5.7.8) for the last year or so when using the DTS in patch. So I am pretty sure hardware and setup of mux is correct'ish. Kernel trace from patch version: kernel: Micrel KSZ8081 or KSZ8091 30be0000.ethernet-1:01: attached PHY driver [Micrel KSZ8081 or KSZ8091] (mii_bus:phy_addr=30be0000.ethernet-1:01, irq=POLL) Error first occurs when switching from fec phy reset to mdio phy reset code path, I understand that the fec phy reset is obsolete as phy properties was wrongly added to the mac and of course should be part of the phy (separate chip). When debugging it I end up with the get_phy_device() call not working inside of_mdiobus_register_phy(). Workaround at the moment seems to be extending compatible with "ethernet-phy-id0022.1560" to disable auto detection of phy type, and then Ethernet works again. At least the same PHY driver trace can be found and full transmission speed can be used without packet errors/loss. > Are there external pull-up/pull-down resistors for strapping the > various configuration pins for the PHY? Or are the pull-up/pull-down > provided by the i.MX7D pins? Config strapping is done with external resistors. > If there are no external pull-ups, please make sure to configure the > pinctrl_enet1 accordingly, so that the Ethernet PHY address can be > properly configured and then mdio_bus driver can find it at the > correct address. > > Please check in arch/arm/boot/dts/imx6qdl-sr-som.dtsi for an example > on how to configure the Ethernet PHY pin strapping via iMX IOMUX. Thanks, good examples can be hard to find. /Bruno