From patchwork Fri Jun 9 08:03:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Chevallier X-Patchwork-Id: 13273384 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 47757C7EE29 for ; Fri, 9 Jun 2023 08:03:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=7bUlUWIVjGIMAQ932JRfclb2hQ3JJV+aDOlX0OuXhiY=; b=m7JYdtM/6Yql5D qiwtsWoAs5LH68FANWnnhO+D5D0SzfsHIr5eby60W2IG84s2kja6x7DyLAXdzsimhLRqqAqsDbsro nh97atcwU8vZFlJfsoTFDne4plsbZQPzAS4bFsBcwHlQczZ90kU8SIXafSXT1eBcBvsdAI8qJf1y4 uQ++iyB5Nhkn0xC0wfh8aJuRzlP8zhfyReKCwWPFBdzRZPMmMHd/ni/YtRNvR7ZESFUwcvxtwr7o5 CIbAqNP2AWOSETRmwxC7whwMXS85XMYmOYDTW6ckVVLIFUQ7EkKHGGFzyDV2W8WvXKmIZhILvkoZZ AV/gl5oC52dqRMNHTsZQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1q7X5X-00CAGl-2V; Fri, 09 Jun 2023 08:03:15 +0000 Received: from relay6-d.mail.gandi.net ([2001:4b98:dc4:8::226]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1q7X5U-00CAFP-0a for linux-arm-kernel@lists.infradead.org; Fri, 09 Jun 2023 08:03:14 +0000 X-GND-Sasl: maxime.chevallier@bootlin.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1686297789; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=V1fjQgvADNeoYs1XNE6CaL9g0vQm/7IWTKb+iOiyp9U=; b=pCaH0AEfra0t+2HyuCPvIO5uveL7uMFWIGejcXukSlwSKDBKIP2vjoikFe7Uj6fKw+5EGf 5x6zxGvHH9S+SDcFol5H8sGkT7gpOztJIpm20XgP/Qt1WNOjiPCp8Nmfisu3rkPh+D69qv SG5F3fmQX4HfI3d8oLc9Zcn8CNGt+7kVZpnxQhv6LebT1QubIeLc5oQmOZC9NHoOJiJy+s ojdmbd0xR98KDunDkXDSfKxvCpio6Gb+VjRuxodZpCLnZflETss1jM60/Mz+/5CuLE+SyR yVhVNbtMEC8QkTL6LapK61qssSclqBba/0qUoZMU+2BnangOsZluKlJTLMyfAg== X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com X-GND-Sasl: maxime.chevallier@bootlin.com Received: by mail.gandi.net (Postfix) with ESMTPSA id C19A4C0011; Fri, 9 Jun 2023 08:03:07 +0000 (UTC) From: Maxime Chevallier To: davem@davemloft.net Cc: Maxime Chevallier , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, thomas.petazzoni@bootlin.com, Andrew Lunn , Florian Fainelli , Heiner Kallweit , Russell King , linux-arm-kernel@lists.infradead.org, Horatiu.Vultur@microchip.com, Allan.Nielsen@microchip.com, UNGLinuxDriver@microchip.com, Vladimir Oltean , Simon Horman Subject: [PATCH net v2 0/2] fixes for Q-USGMII speeds and autoneg Date: Fri, 9 Jun 2023 10:03:03 +0200 Message-Id: <20230609080305.546028-1-maxime.chevallier@bootlin.com> X-Mailer: git-send-email 2.40.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230609_010312_530279_63FC5AD7 X-CRM114-Status: UNSURE ( 8.37 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This is the second version of a small changeset for QUSGMII support, fixing inconsistencies in reported max speed and control word parsing. As reported here [1], there are some inconsistencies for the Q-USGMII mode speeds and configuration. The first patch in this fixup series makes so that we correctly report the max speed of 1Gbps for this mode. The second patch uses a dedicated helper to decode the control word. This is necessary as although USGMII control words are close to USXGMII, they don't support the same speeds. Thanks, Maxime [1] : https://lore.kernel.org/netdev/ZHnd+6FUO77XFJvQ@shell.armlinux.org.uk/ V1->V2: Fix decoding logic for usgmii control word, as per Russell's review Maxime Chevallier (2): net: phylink: report correct max speed for QUSGMII net: phylink: use a dedicated helper to parse usgmii control word drivers/net/phy/phylink.c | 41 +++++++++++++++++++++++++++++++++++++-- 1 file changed, 39 insertions(+), 2 deletions(-) Reviewed-by: Russell King (Oracle)