Received: by 2002:ac0:e350:0:0:0:0:0 with SMTP id g16csp347065imn; Fri, 29 Jul 2022 08:39:10 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tj6MbGkJJqQVwecrbvE71SghZhfWVqsmHRagyL8+YUfGqI3YfuUzpsHpcylZJ70pg3F0Zc X-Received: by 2002:a17:907:a075:b0:72b:33e7:d63a with SMTP id ia21-20020a170907a07500b0072b33e7d63amr3110899ejc.533.1659109140051; Fri, 29 Jul 2022 08:39:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659109140; cv=none; d=google.com; s=arc-20160816; b=sk3uWniWDZ0mqld4//PbiyljGaPdPwDzKDX8ppKr6jIqV73qiiWM/XPsQtkhXT7LFh lYBCKcYStvD0BuzarmU9gBQfj+m1jSitlGE5UT5Gb7uXtpLMCZ7pD92+xUNSzeDq4VHJ UJHmddMPggMmYYMzG4srpesWG0vCwAIyVBt+uS9br4a7DD5aWqeiJEq3sgXKa5tgntQK 1ldMrhkRbU+oaFVJW4YqPw37CbUjLkyZ3VuzwheMhQ7ZVhOrCvIIkXMj0jU+hxyGn2Jh Z1TOnND+fw46NXcsrOW64oAAteFAB4TGCMHk07135kAjkUQXJC7QjoYdJEy9A12sbN2+ +HVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=W8HzVP3f12jtZr7ZSlHrA7jmUrW5KGei/Y00G5BNdF8=; b=z06p9UZDBl2LVBvZtCgrkxkut1E1tXvHh8bxUa4qyu9fOqoc8/anKHml0badKWV1kN zusAoCs2BJ8vLapCKq1A0XLsJw0e/GM67acdWS49+EbOTx2ZzFKpha/5u7YI2znygERF iauXoxnro5ByTQdizuLFLcklvDBx/+AwtMzlaQA8OD35GfYQOUc7p/50OfTQkUkS/ERS Ef36PVa/HTrSD2RcnLB1uczmZ9AJDOJv5LgK7RniTnD6yikmd5aspkqitMGTtx9DIyBX wZUmFgy7vyzCjw0OILIdtPcd/KekFLWfG5Tgg3jD8zsr6tymsnPn5IMCAoTJr1CwubxC JzjQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=XJNp0Bp7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id fr1-20020a170906890100b007263178bac4si2941492ejc.638.2022.07.29.08.38.34; Fri, 29 Jul 2022 08:39:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=XJNp0Bp7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237628AbiG2PeI (ORCPT + 99 others); Fri, 29 Jul 2022 11:34:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34546 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232488AbiG2PeG (ORCPT ); Fri, 29 Jul 2022 11:34:06 -0400 Received: from relay10.mail.gandi.net (relay10.mail.gandi.net [217.70.178.230]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 11B096FA0C; Fri, 29 Jul 2022 08:34:04 -0700 (PDT) Received: (Authenticated sender: maxime.chevallier@bootlin.com) by mail.gandi.net (Postfix) with ESMTPSA id AF00A240003; Fri, 29 Jul 2022 15:33:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1659108843; 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=W8HzVP3f12jtZr7ZSlHrA7jmUrW5KGei/Y00G5BNdF8=; b=XJNp0Bp7SVJ5kKDdoYriSdiGFucOCO3WcPhxRjgoKwueodrAXjaQdmiYUIyrHWVTA2doRw SMxVb5m1+8euBAqcJZ2ixXoHSunv6cmESz0UdjsMDJ+vMDA8NgB9OmrYodmpEfDO0ZXfFX hh/xaSgKo+iJt9SCwtrO1rLQMZXrxo8k3iZZeXZQY13TSjfwb6bLsu8+dX136wtAs9flFB AkiL/ta7MtTj7uzHJ7kPCPU+hKHzq0ze0NEheEvhczkzafiHXc8hmFI15HSDq21wQ7FUAd PCw6hng81Ffl28F4VFaWLUtesFgkEYqyFqJOALZsJYj1sMT7WcEAQJL3Clrg9Q== From: Maxime Chevallier To: davem@davemloft.net, Rob Herring Cc: Maxime Chevallier , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, thomas.petazzoni@bootlin.com, Andrew Lunn , Florian Fainelli , Heiner Kallweit , Russell King , linux-arm-kernel@lists.infradead.org, Richard Cochran , Horatiu.Vultur@microchip.com, Allan.Nielsen@microchip.com, UNGLinuxDriver@microchip.com Subject: [PATCH net-next v3 0/4] net: Introduce QUSGMII phy mode Date: Fri, 29 Jul 2022 17:33:52 +0200 Message-Id: <20220729153356.581444-1-maxime.chevallier@bootlin.com> X-Mailer: git-send-email 2.37.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello everyone, This is the V3 of a previous series [1] initially aimed at introducing inband extensions, with modes like QUSGMII. This mode allows passing info in the ethernet preamble between the MAC and the PHY, such s timestamps. This series has now become a preliminary series, that simply introduces the new interface mode, without support for inband extensions, that will come later. The reasonning is that work will need to be done in the networking subsystem, but also in the generic phy driver subsystem to allow serdes configuration for qusgmii. This series add the mode, the relevant binding changes, adds support for it in the lan966x driver, and also introduces a small helper to get the number of links a given phy mode can carry (think 1 for SGMII and 4 for QSGMII). This allows for better readability and will prove useful when (if) we support PSGMII (5 links on 1 interface) and OUSGMII (8 links on one interface). V3 includes small fixups on the ports-per-interface assignment and some missing documentation, thanks Andrew and Florian for the review ! Best regards, Maxime [1] : https://lore.kernel.org/netdev/20220519135647.465653-1-maxime.chevallier@bootlin.com/ Maxime Chevallier (4): net: phy: Introduce QUSGMII PHY mode dt-bindings: net: ethernet-controller: add QUSGMII mode net: phy: Add helper to derive the number of ports from a phy mode net: lan966x: Add QUSGMII support for lan966x .../bindings/net/ethernet-controller.yaml | 1 + Documentation/networking/phy.rst | 9 ++++ .../ethernet/microchip/lan966x/lan966x_main.c | 2 + .../microchip/lan966x/lan966x_phylink.c | 3 +- .../ethernet/microchip/lan966x/lan966x_port.c | 22 +++++--- .../ethernet/microchip/lan966x/lan966x_regs.h | 6 +++ drivers/net/phy/phy-core.c | 52 +++++++++++++++++++ drivers/net/phy/phylink.c | 3 ++ include/linux/phy.h | 6 +++ 9 files changed, 97 insertions(+), 7 deletions(-) -- 2.37.1