From patchwork Mon Aug 7 11:00:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: MD Danish Anwar X-Patchwork-Id: 13343301 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 F133EEB64DD for ; Mon, 7 Aug 2023 11:01:39 +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=hkhaYAItWKQ+eJVFdSjooCNL+xVEdULKcslkBD0s1P8=; b=xH72YInxHPJp/E u9n8tFutVBJ4OKWjQH8PdYfsxlbTH3BVDygihf2U6RPOSlrKECto2J+z8JofWzUXyNX1nlMW0G49w SnDz8RZLIcmEEkqI6dnVudVRTeyvyo40sYPxT5ibZ+Bs8fkP9BBYrUMqSNMqh+XFRYLFBZhunSk8z K9f0VHiOEYTzA3tGxod3lZjg0U65Rn3TUPJUQ8aAx4RibZN3yEJNL+R2N7GBZuJc1MvxQ7rYSsDe8 2YNxsrELeBPTk7KO7BOW9OvE1MmKopbdGz+VUZRbNRMnjPYdIGjk4MpOCtjUyYOcUqolReJv8Y73a pKnH3QKoMexBhCHgDk/g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qSxz7-00Gwox-1w; Mon, 07 Aug 2023 11:01:13 +0000 Received: from lelv0143.ext.ti.com ([198.47.23.248]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qSxz4-00Gwna-1T for linux-arm-kernel@lists.infradead.org; Mon, 07 Aug 2023 11:01:11 +0000 Received: from lelv0266.itg.ti.com ([10.180.67.225]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id 377B0sv8054566; Mon, 7 Aug 2023 06:00:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1691406054; bh=ZPjBvlXzHvxA+tZyjo1EWAU6idpL4b02GPU7dEiciNc=; h=From:To:CC:Subject:Date; b=JJfi7OJe4hTq6PPVdSKngRhg6A5ETI2B85fyTTkbpt325FLpe0oSWhri0dalRgyHa y9A2NMUnKxIDm9fImSJF2ek8hpnxvIsW4TrZt4+xJENJitEoXpPyVwrjkZuVbjGfVo MnA0m0aNQ555zY9DnMIa1PNDutcDKk7Qq7VxeINg= Received: from DFLE115.ent.ti.com (dfle115.ent.ti.com [10.64.6.36]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 377B0sZc074768 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 7 Aug 2023 06:00:54 -0500 Received: from DFLE111.ent.ti.com (10.64.6.32) by DFLE115.ent.ti.com (10.64.6.36) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Mon, 7 Aug 2023 06:00:54 -0500 Received: from lelv0327.itg.ti.com (10.180.67.183) by DFLE111.ent.ti.com (10.64.6.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Mon, 7 Aug 2023 06:00:54 -0500 Received: from fllv0122.itg.ti.com (fllv0122.itg.ti.com [10.247.120.72]) by lelv0327.itg.ti.com (8.15.2/8.15.2) with ESMTP id 377B0shg031533; Mon, 7 Aug 2023 06:00:54 -0500 Received: from localhost (uda0501179.dhcp.ti.com [172.24.227.217]) by fllv0122.itg.ti.com (8.14.7/8.14.7) with ESMTP id 377B0rUG028356; Mon, 7 Aug 2023 06:00:54 -0500 From: MD Danish Anwar To: Randy Dunlap , Roger Quadros , Simon Horman , Vignesh Raghavendra , Andrew Lunn , Richard Cochran , Conor Dooley , Krzysztof Kozlowski , Rob Herring , Paolo Abeni , Jakub Kicinski , Eric Dumazet , "David S. Miller" , MD Danish Anwar CC: , , , , , , Subject: [PATCH v2 0/5] Introduce IEP driver and packet timestamping support Date: Mon, 7 Aug 2023 16:30:43 +0530 Message-ID: <20230807110048.2611456-1-danishanwar@ti.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230807_040110_595188_672A77AE X-CRM114-Status: GOOD ( 14.17 ) 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 series introduces Industrial Ethernet Peripheral (IEP) driver to support timestamping of ethernet packets and thus support PTP and PPS for PRU ICSSG ethernet ports. This series also adds 10M full duplex support for ICSSG ethernet driver. There are two IEP instances. IEP0 is used for packet timestamping while IEP1 is used for 10M full duplex support. This is v2 of the series [v1]. It addresses comments made on [v1]. This series is based on linux-next(#next-20230807). Changes from v1 to v2: *) Addressed Simon's comment to fix reverse xmas tree declaration. Some APIs in patch 3 and 4 were not following reverse xmas tree variable declaration. Fixed it in this version. *) Addressed Conor's comments and removed unsupported SoCs from compatible comment in patch 1. *) Addded patch 2 which was not part of v1. Patch 2, adds IEP node to dt bindings for ICSSG. [v1] https://lore.kernel.org/all/20230803110153.3309577-1-danishanwar@ti.com/ Thanks and Regards, Md Danish Anwar Grygorii Strashko (1): net: ti: icssg-prueth: am65x SR2.0 add 10M full duplex support MD Danish Anwar (1): dt-bindings: net: Add iep node in ICSSG driver dt binding Md Danish Anwar (1): dt-bindings: net: Add ICSS IEP Roger Quadros (2): net: ti: icss-iep: Add IEP driver net: ti: icssg-prueth: add packet timestamping and ptp support .../devicetree/bindings/net/ti,icss-iep.yaml | 37 + .../bindings/net/ti,icssg-prueth.yaml | 7 + drivers/net/ethernet/ti/Kconfig | 12 + drivers/net/ethernet/ti/Makefile | 1 + drivers/net/ethernet/ti/icssg/icss_iep.c | 961 ++++++++++++++++++ drivers/net/ethernet/ti/icssg/icss_iep.h | 41 + drivers/net/ethernet/ti/icssg/icssg_config.c | 6 + drivers/net/ethernet/ti/icssg/icssg_ethtool.c | 21 + drivers/net/ethernet/ti/icssg/icssg_prueth.c | 433 +++++++- drivers/net/ethernet/ti/icssg/icssg_prueth.h | 28 +- 10 files changed, 1540 insertions(+), 7 deletions(-) create mode 100644 Documentation/devicetree/bindings/net/ti,icss-iep.yaml create mode 100644 drivers/net/ethernet/ti/icssg/icss_iep.c create mode 100644 drivers/net/ethernet/ti/icssg/icss_iep.h