Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 36948C05027 for ; Sun, 19 Feb 2023 14:27:44 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 3B19D85131; Sun, 19 Feb 2023 15:27:42 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1676816862; bh=v3CjIAP+FmCzE1NvM2ZcXzRGOMQ35llQ4wFQEnJs2sw=; h=Date:Subject:To:Cc:References:From:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=X4FCDDiWRrBZux0pEKVifiVT3bI3iobLu1NJ7R/ErvN/rKlZ2MVbhE7ZkzS2/Q61l x/REodWZwuMF8G3dQqnpNIlMNtDGYBCkwVjazs+x6kzdm8q3puRyMU1+VaPzVylAg1 7Bq4NobKuP/MbbfL7B2vJTSeMKamMBPHYHl88TOFmz8bpi5ybrUMVbumpNEAMSvX92 za0w4tKVANO8g+fMMBILFgNLLCs6XEdGRrgSRGY8KMg9NgFN2M2X4p/NyCdlLbFomI zE4tWe/qS9wyBlB08iBu81wyvE1eHsvUtKWaq4pY1s8/VRSs5uEBBoxtpAEnP6d3ET ++Ulcmg+pumzA== Received: from [127.0.0.1] (p578adb1c.dip0.t-ipconnect.de [87.138.219.28]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 9A64084227; Sun, 19 Feb 2023 15:27:40 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1676816860; bh=v3CjIAP+FmCzE1NvM2ZcXzRGOMQ35llQ4wFQEnJs2sw=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=HgsqJM+F4Xl33DWb6ftpZArAQJlNZqVG10mlCHuS++G8eBcL008fCsrYxorTN8AlU y7LEfRHLrmJJgOIeqoygBkCFh4UnWatBfvJWyCB4+Iba9bCMhoyFShIP725LBAOzP+ sPrPJd0MeyYdP77S1bODJR3+Of0RRlKmc89DBbSe8ZdbhkNITNj/eRnAowv5DVFxYd 896ekSZ3BGfuiDQYnUy8pPPcNBO0Uw+cXdl5602he0OHZAFLzErVgemfBCxBbh+EQc epVYjCU2ZHc0pzAz4drdTVSDQi7qJTPK28AohRHvlWrFRCyD02L0jogfY455kQJ3Rv 2ZJU/dgCXLUaw== Message-ID: <4b895bb2-704c-e8ec-b693-ff05373c6b35@denx.de> Date: Sun, 19 Feb 2023 15:27:40 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.8.0 Subject: Re: [PATCH v2] Let the EQoS in imx8mp handle fixed-phy too. To: Elmar Psilog , u-boot@lists.denx.de Cc: rfried.dev@gmail.com References: <20230219124826.15689-1-epsi@gmx.de> Content-Language: en-US From: Marek Vasut In-Reply-To: <20230219124826.15689-1-epsi@gmx.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean On 2/19/23 13:48, Elmar Psilog wrote: > Without that patch it lost track to the node to scan > speed and duplex. > Patch was created by Marek Vasut, just tested by me. > > Signed-off-by: Elmar Psilog > --- > changes v2: fix format issues > > drivers/net/dwc_eth_qos.c | 19 ++++++++++++++++--- > 1 file changed, 16 insertions(+), 3 deletions(-) > > diff --git a/drivers/net/dwc_eth_qos.c b/drivers/net/dwc_eth_qos.c > index 112deb546d..ff638b0f1e 100644 > --- a/drivers/net/dwc_eth_qos.c > +++ b/drivers/net/dwc_eth_qos.c > @@ -788,9 +788,22 @@ static int eqos_start(struct udevice *dev) > */ > if (!eqos->phy) { > int addr = -1; > - addr = eqos_get_phy_addr(eqos, dev); > - eqos->phy = phy_connect(eqos->mii, addr, dev, > - eqos->config->interface(dev)); > + ofnode fixed_node; > + > + if (IS_ENABLED(CONFIG_PHY_FIXED)) { > + fixed_node = ofnode_find_subnode(dev_ofnode(dev), > + "fixed-link"); > + if (ofnode_valid(fixed_node)) { > + eqos->phy = fixed_phy_create(dev_ofnode(dev)); > + } One more nitpick. Drop the curly brackets {} around this statement, i.e. keep only: if (ofnode_valid(fixed_node)) eqos->phy = fixed_phy_create(dev_ofnode(dev)); With that fixed in V3, add: Reviewed-by: Marek Vasut Thanks !