Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3764025pxj; Mon, 21 Jun 2021 06:10:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwr7IIkcU5BJClKBMVGzOVWkOIH4AsAxc/e7YPZXkJzdrZpzs2BqkL1/Ec6DYHQnUiA2AzA X-Received: by 2002:a17:906:74a:: with SMTP id z10mr22750454ejb.107.1624281029377; Mon, 21 Jun 2021 06:10:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624281029; cv=none; d=google.com; s=arc-20160816; b=HE2IFa9LuX6xWPKN6SE4c2CXDLkSxiCBBuOCFNpCQZ/58MJv/DRQu3OWe5LLX2440j Phsm0oJbhAfsIboEBbOImDezQ5sKfZJYmRZ+X7DvNoM+lWo1L1YNsV/U8fZCd+iykg2g 3c++SWcMOkttaUNRU/UNhIXjtg4USXOdt52U6ebW8OB+bQ7Z1R3KSTXYCg1E+w1+wxbS Df5G/jcwGT/CqBlMl/MwEpetaOzinI0YXPMdKbXYtKfX5iV54Ax+kocexWQXPOs+0SD5 Gk61LrN1n0Mg/X4DcZ3Bt/SgotMF89GZltwbbnFSenX7j+Z67c9X3JQ6GknTqjQVOh3z KIgQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=htXr5+GTGyZJxaugUXnZ7e7qviUalTTBhF0Oq+fysqM=; b=rKMI+ULJmcFCgZowvOxVHpbm+ghbUzuRa/ech7mTH7OH9i9EYueY/M8PRQDMfNe1Cx V9xooISNeBaif9e1R1Q1/+lCBq+ejArqOYHBecqyg17+uFiJTEuEFOviI65peM2bDfTt VPopHiqAUeNw7SiZAq9JukutmyoqPy24YjXS1H+b35IOyxMfqkH740K1WdWxeF5FY5Dg CJwxL7BhoD8IE5L95+UGgeY0Uz0ElJHtO8f5oJdVpEDNQFrEbnAFr6OxGto4LBqGr6tq Wc/LAmNJ27CQseC8LDMg/DDlAKm/SJCw8qMsskvZ049ZzwHg3EoVg1efVOl2KijWZe+z 1VxQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b="Zvslj/ZM"; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m5si10747332ejn.23.2021.06.21.06.10.06; Mon, 21 Jun 2021 06:10:29 -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=@lunn.ch header.s=20171124 header.b="Zvslj/ZM"; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229876AbhFUNLY (ORCPT + 99 others); Mon, 21 Jun 2021 09:11:24 -0400 Received: from vps0.lunn.ch ([185.16.172.187]:47570 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229651AbhFUNLX (ORCPT ); Mon, 21 Jun 2021 09:11:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Disposition:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:From:Sender:Reply-To:Subject: Date:Message-ID:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Content-Disposition:In-Reply-To:References; bh=htXr5+GTGyZJxaugUXnZ7e7qviUalTTBhF0Oq+fysqM=; b=Zvslj/ZMkVwvvFB19uFwtxtMfg j0OFcxF9euXqDrFnWNpF3XQMa3P8cliizUOAPYr0OPW9R+A4hoM1s/Npa6wSf5N02ihrs+fpC9Agr Bnk6J1q5cE35jzkXlz4pX7l6PRTpD5DPiMCv5BwPr9E4i7TPHGpiOXZKPNhVXgR38npQ=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1lvJfm-00AVQD-FV; Mon, 21 Jun 2021 15:09:06 +0200 Date: Mon, 21 Jun 2021 15:09:06 +0200 From: Andrew Lunn To: Jian-Hong Pan Cc: Doug Berger , Florian Fainelli , Stefan Wahren , bcm-kernel-feedback-list@broadcom.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux@endlessos.org, linux-rpi-kernel@lists.infradead.org Subject: Re: [PATCH] net: bcmgenet: Fix attaching to PYH failed on RPi 4B Message-ID: References: <20210621103310.186334-1-jhp@endlessos.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210621103310.186334-1-jhp@endlessos.org> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 21, 2021 at 06:33:11PM +0800, Jian-Hong Pan wrote: > The Broadcom UniMAC MDIO bus comes too late. So, GENET cannot find the > ethernet PHY on UniMAC MDIO bus. This leads GENET fail to attach the > PHY. > > bcmgenet fd580000.ethernet: GENET 5.0 EPHY: 0x0000 > ... > could not attach to PHY > bcmgenet fd580000.ethernet eth0: failed to connect to PHY > uart-pl011 fe201000.serial: no DMA platform data > libphy: bcmgenet MII bus: probed > ... > unimac-mdio unimac-mdio.-19: Broadcom UniMAC MDIO bus > > This patch makes GENET try to connect the PHY up to 3 times. Also, waits > a while between each time for mdio-bcm-unimac module's loading and > probing. Don't loop. Return -EPROBE_DEFER. The driver core will then probed the driver again later, by which time, the MDIO bus driver should of probed. Andrew