Message ID | 20230928122427.313271-6-christophe.roullier@foss.st.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:cae8:0:b0:403:3b70:6f57 with SMTP id r8csp3608495vqu; Thu, 28 Sep 2023 14:25:11 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFAcMdLDfarUDszFeGugFp/d9IEH2Y6r7jMETLa5RjjcQljFjnDn8tzK/t8vzQtzBOdjv3I X-Received: by 2002:a9d:6b99:0:b0:6bd:c865:a618 with SMTP id b25-20020a9d6b99000000b006bdc865a618mr2608665otq.13.1695936311514; Thu, 28 Sep 2023 14:25:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695936311; cv=none; d=google.com; s=arc-20160816; b=ZqUlZy4sT7fdzcLsrXZ8wZvROsUUqUWm6kDr6lMdCsOizoK4+XGXxGrF851GqTsCdF lJ6STBSOYKwk4Qb0ohcR94nQK1lD7IdWZSIPIFZU8TK5TK2IwoHPEQ2rjk0kYKY23sC5 D4ht3r3FgQ0bmroR4S3oEe5h9RL+5k04/efqCEZPtmKjS/CfY29jBjG5MN+h1AVwJpKT 6nZriwMuh0UyRXdT+ylO1FXQ20RhgUPAG8SdCd96zbXvZf9zpavy1QWssJg6B98TiyLC 2VPaD5AKF9v/Gbe+vA2s9+OBq9UDCdJNcJJpMNWMj0avOMyS81hRN6EZU0FyCr/EFv/S gGAQ== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=tCZxZAAY+Gn9wAA1qw22DEBm15B9XqamItmDNiDWxRA=; fh=Nrq3/ZyqAmcldX4TnYQJDytRSUiD1vJeQNniXh+eWjo=; b=byrEEIi4q1+GrZPeuycb++hyWA1jGQIQvYQls3AF6FRDUndLg7RNkGjTwBS4pkgkq6 x0uHnRCxS1+/ESD1LoEMwwgE9fvQ5b0nabl9UWwdfeo/isZVp/rc0sUFmm6oFYsI5nfL nlTlLhoJ33QTmRorerOma+JSSIzXMw6zI07eJEXrUN+9FSK3fFc0fUXDa+sSxvITSh0W jB09TDaVepCnG77ra+AiX0M4OwvLNvJsza648emaaQNQvt/guI+0kOMod263iYMOZStj kupYxEZdaomv/PEwqp1jlG4r8y+ggUTsWizCsup3ym/RyBCnc/eWswq9xCbTHLDOYRE9 cLww== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@foss.st.com header.s=selector1 header.b=3ThKsGtN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=foss.st.com Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id by7-20020a056a00400700b0069022a03d42si2034767pfb.283.2023.09.28.14.25.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Sep 2023 14:25:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@foss.st.com header.s=selector1 header.b=3ThKsGtN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=foss.st.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 281988359B40; Thu, 28 Sep 2023 05:26:21 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231793AbjI1M0L (ORCPT <rfc822;pwkd43@gmail.com> + 21 others); Thu, 28 Sep 2023 08:26:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47318 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232345AbjI1M0J (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 28 Sep 2023 08:26:09 -0400 Received: from mx07-00178001.pphosted.com (mx08-00178001.pphosted.com [91.207.212.93]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 663A2198; Thu, 28 Sep 2023 05:26:07 -0700 (PDT) Received: from pps.filterd (m0046660.ppops.net [127.0.0.1]) by mx07-00178001.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 38S8kbbg029789; Thu, 28 Sep 2023 14:25:47 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foss.st.com; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s= selector1; bh=tCZxZAAY+Gn9wAA1qw22DEBm15B9XqamItmDNiDWxRA=; b=3T hKsGtN3FHsNkACWq8RTC+Eb//Ldd6YaKS2h5AWlZfUQQn/8GCAuA/1MNTDot/g0u jgy68t2kWg9lgiTXaL9o2RspXGDqVhtlGH2am2gjPTgEPl7TOqVBI0gajfbJlZ1y qp0GtBqaXDUHNx2S2XJ5cJ+lk58M5OGoPv1m+OPULIUHLG5PrGkl409S+l5kJ+og TyVJrW6V5y1bNZbQw1IgSHYKqhzt1/02hiRPX9+IqiC3tm3VbRQL3TgJ4pqYNI/H 1mKP/Ve0qPP2VGFpi/WF2hckTid1839AbESqi3RzaJzYOYZGjECTQ6eD1uCIzVgK L/Sj20hQhZxF8BMVFSHA== Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com (PPS) with ESMTPS id 3tcq63c405-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 28 Sep 2023 14:25:47 +0200 (MEST) Received: from euls16034.sgp.st.com (euls16034.sgp.st.com [10.75.44.20]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 0FA09100058; Thu, 28 Sep 2023 14:25:47 +0200 (CEST) Received: from Webmail-eu.st.com (shfdag1node2.st.com [10.75.129.70]) by euls16034.sgp.st.com (STMicroelectronics) with ESMTP id 04E202309E5; Thu, 28 Sep 2023 14:25:47 +0200 (CEST) Received: from localhost (10.201.21.249) by SHFDAG1NODE2.st.com (10.75.129.70) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Thu, 28 Sep 2023 14:25:46 +0200 From: Christophe Roullier <christophe.roullier@foss.st.com> To: "David S . Miller" <davem@davemloft.net>, Eric Dumazet <edumazet@google.com>, Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Conor Dooley <conor+dt@kernel.org>, Maxime Coquelin <mcoquelin.stm32@gmail.com>, Alexandre Torgue <alexandre.torgue@foss.st.com>, Richard Cochran <richardcochran@gmail.com>, Jose Abreu <joabreu@synopsys.com>, Liam Girdwood <lgirdwood@gmail.com>, Mark Brown <broonie@kernel.org>, Christophe Roullier <christophe.roullier@foss.st.com> CC: <netdev@vger.kernel.org>, <devicetree@vger.kernel.org>, <linux-stm32@st-md-mailman.stormreply.com>, <linux-arm-kernel@lists.infradead.org>, <linux-kernel@vger.kernel.org> Subject: [PATCH v2 05/12] net: ethernet: stmmac: add management of stm32mp13 for stm32 Date: Thu, 28 Sep 2023 14:24:20 +0200 Message-ID: <20230928122427.313271-6-christophe.roullier@foss.st.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230928122427.313271-1-christophe.roullier@foss.st.com> References: <20230928122427.313271-1-christophe.roullier@foss.st.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.201.21.249] X-ClientProxiedBy: SHFCAS1NODE2.st.com (10.75.129.73) To SHFDAG1NODE2.st.com (10.75.129.70) X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.267,Aquarius:18.0.980,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-09-28_11,2023-09-28_01,2023-05-22_02 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Thu, 28 Sep 2023 05:26:21 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1778318113950570196 X-GMAIL-MSGID: 1778318113950570196 |
Series |
Series to deliver Ethernets for STM32MP13
|
|
Commit Message
Christophe Roullier
Sept. 28, 2023, 12:24 p.m. UTC
From: Christophe Roullier <christophe.roullier@st.com> Add Ethernet support for STM32MP13. STM32MP13 is STM32 SOC with 2 GMACs instances. GMAC IP version is SNPS 4.20. GMAC IP configure with 1 RX and 1 TX queue. DMA HW capability register supported RX Checksum Offload Engine supported TX Checksum insertion supported Wake-Up On Lan supported TSO supported Signed-off-by: Christophe Roullier <christophe.roullier@foss.st.com> --- .../net/ethernet/stmicro/stmmac/dwmac-stm32.c | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+)
diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-stm32.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-stm32.c index 52106e0d7359f..a071dc6ffc95b 100644 --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-stm32.c +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-stm32.c @@ -537,9 +537,30 @@ static struct stm32_ops stm32mp1_dwmac_data = { } }; +static struct stm32_ops stm32mp13_dwmac_data = { + .set_mode = stm32mp1_set_mode, + .clk_prepare = stm32mp1_clk_prepare, + .suspend = stm32mp1_suspend, + .resume = stm32mp1_resume, + .parse_data = stm32mp1_parse_data, + .syscfg_clr_off = 0x08, + .pmcsetr = { + .eth1_clk_sel = BIT(16), + .eth1_ref_clk_sel = BIT(17), + .eth1_selmii = 0, + .eth1_sel_rgmii = BIT(21), + .eth1_sel_rmii = BIT(23), + .eth2_clk_sel = BIT(24), + .eth2_ref_clk_sel = BIT(25), + .eth2_sel_rgmii = BIT(29), + .eth2_sel_rmii = BIT(31) + } +}; + static const struct of_device_id stm32_dwmac_match[] = { { .compatible = "st,stm32-dwmac", .data = &stm32mcu_dwmac_data}, { .compatible = "st,stm32mp1-dwmac", .data = &stm32mp1_dwmac_data}, + { .compatible = "st,stm32mp13-dwmac", .data = &stm32mp13_dwmac_data}, { } }; MODULE_DEVICE_TABLE(of, stm32_dwmac_match);