From patchwork Mon May 1 20:51:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Halaney X-Patchwork-Id: 89177 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp175487vqo; Mon, 1 May 2023 13:56:02 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5pVxNOtNcDUgu12JEHlp5DuS1mWqyIwMiLFtcxRpEU27kvq6pO4Z7V9RBeHTOlMWgelQwx X-Received: by 2002:a05:6a00:2e03:b0:63a:65a9:10db with SMTP id fc3-20020a056a002e0300b0063a65a910dbmr22584185pfb.7.1682974562296; Mon, 01 May 2023 13:56:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682974562; cv=none; d=google.com; s=arc-20160816; b=uj39WjTZUMqpfN0zTN1HJecBvaupTETTgb8Gveh8lC0I49RCJauV86J19zdGbH4EDM iizP4q0aiXCcsRx5Q8/Bf/+pOWDU0c3uGRU7iujxsNOqIpRRCM9AqUFeJ01greJ2UGKD rEBrxMyz3Ile6eiV4G8LQats5HYBgvDh5GMbyo70T3W+8+SFfAnPooAP1Tfz+gp+4MrY 6EX+S2BVSZc5kZ1Zdhrn1DWT4iDIyhO4swAfGk1l9qJZLVQ6e50fExBGmR8H+E5wGZHA dBBAXHQPbWI++KqUszlB5sNlFDfEK1BCJwxZCNVARv6RCyM8webcUEDAaUkCDO1VOEpu lmHA== 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=ZySyzkpa+LDQ1V/Mnqnm2QktfICKKdof2ETQCboTeH4=; b=PNcHcugc6+flnoKwEiFolhtHEEXmqImm8p5DP5mBRmT4PQmVOyX9mD86exx7dHIhPA NirktdoX51Jep41EMmksgHFFJEh4WWeYJYxlP+Y926bOldRYkCOfjI9XdbVhSPX2bRUy +2HbQ5+Vj4wfr4BedqxYAezaHEdGso3Fum8yh2XjVcAPbwamXBud07FFs79tL7UKXdQO JsUljMASVdkYWY9/CBSwJZ39yxlxT337Ks5/2zykenQP5EwVsH2ihcqrEZ8Tk1BDXFbc IX1vU+Sj/kOWyVOY9lwc1ZbmAv3+pWtNRnV/9u188vvWztHCBrGJy0UnHVz3295d6zdw phLA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=WiLr3i41; 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=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o12-20020aa7978c000000b00628a75401bdsi29007019pfp.142.2023.05.01.13.55.49; Mon, 01 May 2023 13:56:02 -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=@redhat.com header.s=mimecast20190719 header.b=WiLr3i41; 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=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232699AbjEAUwa (ORCPT + 99 others); Mon, 1 May 2023 16:52:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35280 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232625AbjEAUw2 (ORCPT ); Mon, 1 May 2023 16:52:28 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C795E30F4 for ; Mon, 1 May 2023 13:51:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1682974297; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ZySyzkpa+LDQ1V/Mnqnm2QktfICKKdof2ETQCboTeH4=; b=WiLr3i41qK8MMjbYtYNffg4z3qKw/Bt6cgR0+1IaN5x1k5J6+EIQXya9xzAXRFTnB8DJss iznlXzd4qAKioQdo17RfZOSUZHTiIJpzPQQlUkQAcGHB2Q95nKXsSyRbvIrH7BqzZ7FouP 6Q3gItWAXzz+M1buUQUB1HhH9XfUFws= Received: from mail-ot1-f71.google.com (mail-ot1-f71.google.com [209.85.210.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-569-kkCNlSifOZWcEboQjkRG0w-1; Mon, 01 May 2023 16:51:35 -0400 X-MC-Unique: kkCNlSifOZWcEboQjkRG0w-1 Received: by mail-ot1-f71.google.com with SMTP id 46e09a7af769-6a5d32ce366so2869672a34.1 for ; Mon, 01 May 2023 13:51:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682974294; x=1685566294; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ZySyzkpa+LDQ1V/Mnqnm2QktfICKKdof2ETQCboTeH4=; b=BK83uax8Lsxd7zTCyuzUohN2CdAfldOjJ3HI9DT/c7R6LOzGmadc4yncRvZvFpKBeg jUPEiFmY4HRmf10hFAemcLuSh99quHba/b3taKY1ufq06aqyO5p6ZY8gxwaUb+AFigL0 C+KnMRBhFB4+GUIqoSzNGZlKXJsttZ2a2+UqpTCXP1PkGWYuD6MR2yGfKn7ldXEmvBo9 P/wZAhnFAIaozEZywLN6w+jXVHAUek64r8oWHLeHRDZHktCsmquXL82TOMn5FzOx2EKd 9B+F+012rIP5HAVoWbTLuERwbmKWK2MEeZb7SofkpJx3yw1G4ZlkzfCi86t46KY5IuoD GybA== X-Gm-Message-State: AC+VfDwC8Z+8yZO1H6Zk8O9bewIMTOjax+IfRCW9m1OfZkuaelV44ZEb jgMSRpEMdZSxLnBO2//YzdVziK3G60uK6p4u016h4tv4y0oNCCirHT6QKw/wQkCjOPDKJSFfG4O jR79EN3z3Ic9IacWqOO+rFzZ1rQ+qG57Tl1Ty8gNa+5LIuJIuqwYe6aFEj/Bzsay2XDrfnjKKZz YCLJvrzWzw X-Received: by 2002:a05:6830:10d2:b0:6a9:3a68:5f00 with SMTP id z18-20020a05683010d200b006a93a685f00mr3851535oto.23.1682974294555; Mon, 01 May 2023 13:51:34 -0700 (PDT) X-Received: by 2002:a05:6830:10d2:b0:6a9:3a68:5f00 with SMTP id z18-20020a05683010d200b006a93a685f00mr3851522oto.23.1682974294289; Mon, 01 May 2023 13:51:34 -0700 (PDT) Received: from halaney-x13s.attlocal.net ([2600:1700:1ff0:d0e0::22]) by smtp.gmail.com with ESMTPSA id c10-20020a9d67ca000000b0069f153bb37asm12110130otn.62.2023.05.01.13.51.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 13:51:33 -0700 (PDT) From: Andrew Halaney To: linux-kernel@vger.kernel.org Cc: agross@kernel.org, andersson@kernel.org, konrad.dybcio@linaro.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, Andrew Halaney , Brian Masney Subject: [PATCH v6 1/2] arm64: dts: qcom: sc8280xp: Add ethernet nodes Date: Mon, 1 May 2023 15:51:04 -0500 Message-Id: <20230501205105.2518373-2-ahalaney@redhat.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230501205105.2518373-1-ahalaney@redhat.com> References: <20230501205105.2518373-1-ahalaney@redhat.com> MIME-Version: 1.0 Content-type: text/plain X-Spam-Status: No, score=-2.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1764726734267607624?= X-GMAIL-MSGID: =?utf-8?q?1764726734267607624?= This platform has 2 MACs integrated in it, go ahead and describe them. Reviewed-by: Konrad Dybcio Tested-by: Brian Masney Signed-off-by: Andrew Halaney --- Changes since v5: * None Changes since v4: * Be consistent in newlines (Brian) * Add Tested-by (Brian) Changes since v3: * Order soc node via unit address (Konrad) * Add Reviewed-by (Konrad) Changes since v2: * Fix spacing (Konrad) Changes since v1: * None arch/arm64/boot/dts/qcom/sc8280xp.dtsi | 60 ++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi index 8fa9fbfe5d00..a2320f880795 100644 --- a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi +++ b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi @@ -768,6 +768,36 @@ soc: soc@0 { ranges = <0 0 0 0 0x10 0>; dma-ranges = <0 0 0 0 0x10 0>; + ethernet0: ethernet@20000 { + compatible = "qcom,sc8280xp-ethqos"; + reg = <0x0 0x00020000 0x0 0x10000>, + <0x0 0x00036000 0x0 0x100>; + reg-names = "stmmaceth", "rgmii"; + + clocks = <&gcc GCC_EMAC0_AXI_CLK>, + <&gcc GCC_EMAC0_SLV_AHB_CLK>, + <&gcc GCC_EMAC0_PTP_CLK>, + <&gcc GCC_EMAC0_RGMII_CLK>; + clock-names = "stmmaceth", + "pclk", + "ptp_ref", + "rgmii"; + + interrupts = , + ; + interrupt-names = "macirq", "eth_lpi"; + + iommus = <&apps_smmu 0x4c0 0xf>; + power-domains = <&gcc EMAC_0_GDSC>; + + snps,tso; + snps,pbl = <32>; + rx-fifo-depth = <4096>; + tx-fifo-depth = <4096>; + + status = "disabled"; + }; + gcc: clock-controller@100000 { compatible = "qcom,gcc-sc8280xp"; reg = <0x0 0x00100000 0x0 0x1f0000>; @@ -4706,6 +4736,36 @@ dispcc1: clock-controller@22100000 { status = "disabled"; }; + + ethernet1: ethernet@23000000 { + compatible = "qcom,sc8280xp-ethqos"; + reg = <0x0 0x23000000 0x0 0x10000>, + <0x0 0x23016000 0x0 0x100>; + reg-names = "stmmaceth", "rgmii"; + + clocks = <&gcc GCC_EMAC1_AXI_CLK>, + <&gcc GCC_EMAC1_SLV_AHB_CLK>, + <&gcc GCC_EMAC1_PTP_CLK>, + <&gcc GCC_EMAC1_RGMII_CLK>; + clock-names = "stmmaceth", + "pclk", + "ptp_ref", + "rgmii"; + + interrupts = , + ; + interrupt-names = "macirq", "eth_lpi"; + + iommus = <&apps_smmu 0x40 0xf>; + power-domains = <&gcc EMAC_1_GDSC>; + + snps,tso; + snps,pbl = <32>; + rx-fifo-depth = <4096>; + tx-fifo-depth = <4096>; + + status = "disabled"; + }; }; sound: sound { From patchwork Mon May 1 20:51:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Halaney X-Patchwork-Id: 89178 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp176871vqo; Mon, 1 May 2023 14:00:13 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6s1Wr6yIRcfZJET1adEQmYbxL2+7cdIZIxKZbMgyXgfW4YOdNDK08QkNR1DD68J43ILdka X-Received: by 2002:a05:6a21:99a5:b0:ee:3824:664f with SMTP id ve37-20020a056a2199a500b000ee3824664fmr20044576pzb.47.1682974813051; Mon, 01 May 2023 14:00:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682974813; cv=none; d=google.com; s=arc-20160816; b=XtKjeLFlzGf8t3V/Yj5l3Yne03a7DegkR8pzX8vCCw10xoxASyKhISNNza7AqmSoEk P1uEtMxJGaANPKyJ44G/cupcYjDpvevMdinN7FuEQkE21pRpwB9ABdxX28FFX4uD/BmJ 88NPv0ramF4OVeqr+Se00s0G+nB6JnyhqYbYVYl3u6H2GH9PvQiG0VqLxAIOYgdw4Cvx gve7Lemr4JAS3AcijhdX4uWMDsp7tyzsbYQGV0zEmFZzrRnrXqSaUNMv/FdnbkUEAZPb GRcHv3MU9bD5D619JsMhov4CCei7T//b7ox3HKWGpPIEXf+aJaXAqn/Xp3vbRTqjDKh3 fHlw== 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=FQVLgDOkXyGANqyYjw+hvuQPpe3HsxoxumeTjkX76j8=; b=Z/RfXK1jLU+D0b7nbBl2jOdb2YdLNPTD4fc3E1xEioTjSr4iQrhoy5NrBaWaapBfEG m9Prp3ZehTP48qYKNXnAY+lE6ARwAvob0ktXVGkbtF6Us48QbLaJDExIo3YKFLChAzlg liTeR/cghlN1AluFLANw5GU8GXlKlplKFIwEL7fttj6Z6zEkGe1c8IrHjE6eiqqUR+Je x/LdKaorOVZgbSG9Rwm9+NHvJ6gpb6iBDPZNzcrvYVv8Ud4d8gP919RkJZrbMjjUdGMq xoTzUkoaUZApiSvyptfoJcuylHLqc/FCoRIA4QwM8UnO7tVqGhuKXW6NWpKSB4FXN0SB DQFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=BFozajfP; 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=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k23-20020a6568d7000000b00503a029385asi24851129pgt.849.2023.05.01.13.59.58; Mon, 01 May 2023 14:00:13 -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=@redhat.com header.s=mimecast20190719 header.b=BFozajfP; 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=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232757AbjEAUwc (ORCPT + 99 others); Mon, 1 May 2023 16:52:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35358 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229816AbjEAUwa (ORCPT ); Mon, 1 May 2023 16:52:30 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 726BF2D57 for ; Mon, 1 May 2023 13:51:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1682974300; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=FQVLgDOkXyGANqyYjw+hvuQPpe3HsxoxumeTjkX76j8=; b=BFozajfPDoWiDEyzuPkbXgcW3/yn8h4nJ9iSu4BbvK5N/BB9hPeA0AZwsISXxcJNFIZthn dNE/qwttIHy/5e6DY66FtDGNj4ks9bL8EMYB6Vz8PUHFEEHaXESnq6emx3NHdYzMsiWNQb DlZjL0oY2J5KSCITdsnXiChF4NaxAxM= Received: from mail-ot1-f70.google.com (mail-ot1-f70.google.com [209.85.210.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-394-N2GvFCR6O-ik5judRakLVQ-1; Mon, 01 May 2023 16:51:39 -0400 X-MC-Unique: N2GvFCR6O-ik5judRakLVQ-1 Received: by mail-ot1-f70.google.com with SMTP id 46e09a7af769-6a646c99bacso740686a34.1 for ; Mon, 01 May 2023 13:51:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682974298; x=1685566298; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=FQVLgDOkXyGANqyYjw+hvuQPpe3HsxoxumeTjkX76j8=; b=kVWASbngoGYXU/hFQ+fQ+OXsYcxQtJXHfYzxq1/4v+Ush88dAa/USLPLlyfO228aUR fl6NM/oqLMKa8PU9s7fjbcDVGktw862NMV/OLprULEPNtnK/EgmMmF1ctpsRdTUXAQ73 56hYzyiLdt+4hv3ViifNFt3ueXl1Ohq+ktaNWAi3hz92b//s5ULWfiJt/3s0Hea4ESzz 19c4SZsvgEGTq/mHkph+vIVOSJx7l5caiDRUNzwehwxw/F4f5LAyHDZkUsG9z/FhLlMa kZ7Yjb/BM24YdAAh1LIV2MJ1KazCPeMt5hYrmrl5FXgk2I/oM1h6lX8/vf+zWQ7wXjfY s9TQ== X-Gm-Message-State: AC+VfDyBq/u9h5mY9D0BTgnEe/4Sn4eUqWQKoWbxkHNM/1uPSFSt6/nD FxdZnlyucngp4f4PSX+bj+ld5kgCkMa+tk19IDLWBpI9TvkuMZ/HejyUFGHN51mm8++qyY7iV8+ d5+iLA2rwc5wIq3nTTsSl4zdSKRI7OirY4EGdD4jo4eq/bcr5cJm+Jy51JzvZ46C95iUOxELVE5 D+znMLYykL X-Received: by 2002:a9d:65d2:0:b0:6a6:3d94:a0d7 with SMTP id z18-20020a9d65d2000000b006a63d94a0d7mr7435697oth.36.1682974298316; Mon, 01 May 2023 13:51:38 -0700 (PDT) X-Received: by 2002:a9d:65d2:0:b0:6a6:3d94:a0d7 with SMTP id z18-20020a9d65d2000000b006a63d94a0d7mr7435679oth.36.1682974297845; Mon, 01 May 2023 13:51:37 -0700 (PDT) Received: from halaney-x13s.attlocal.net ([2600:1700:1ff0:d0e0::22]) by smtp.gmail.com with ESMTPSA id c10-20020a9d67ca000000b0069f153bb37asm12110130otn.62.2023.05.01.13.51.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 01 May 2023 13:51:37 -0700 (PDT) From: Andrew Halaney To: linux-kernel@vger.kernel.org Cc: agross@kernel.org, andersson@kernel.org, konrad.dybcio@linaro.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, Andrew Halaney , Brian Masney Subject: [PATCH v6 2/2] arm64: dts: qcom: sa8540p-ride: Add ethernet nodes Date: Mon, 1 May 2023 15:51:05 -0500 Message-Id: <20230501205105.2518373-3-ahalaney@redhat.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230501205105.2518373-1-ahalaney@redhat.com> References: <20230501205105.2518373-1-ahalaney@redhat.com> MIME-Version: 1.0 Content-type: text/plain X-Spam-Status: No, score=-2.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1764726997490964038?= X-GMAIL-MSGID: =?utf-8?q?1764726997490964038?= Enable both the MACs found on the board. ethernet0 and ethernet1 both ultimately go to a series of on board switches which aren't managed by this processor. ethernet0 is connected to a Marvell 88EA1512 phy via RGMII. That goes to the series of switches via SGMII on the "media" side of the phy. RGMII_SGMII mode is enabled via devicetree register descriptions. The switch on the "media" side has auto-negotiation disabled, so configuration from userspace similar to: ethtool -s eth0 autoneg off speed 1000 duplex full is necessary to get traffic flowing on that interface. ethernet1 is in a mac2mac/fixed-link configuration going to the same series of switches directly via RGMII. Tested-by: Brian Masney Signed-off-by: Andrew Halaney --- Changes since v5: * Move mtl nodes into ethernet nodes so they're evaluated when running the dtbs_check (Stephen) Changes since v4: * Remove needless interrupt-parent (Konrad) * Add Tested-by (Brian) Changes since v3: * Compatible goes first in node (Krzysztof) Changes since v1 and v2: * None arch/arm64/boot/dts/qcom/sa8540p-ride.dts | 238 ++++++++++++++++++++++ 1 file changed, 238 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sa8540p-ride.dts b/arch/arm64/boot/dts/qcom/sa8540p-ride.dts index 24fa449d48a6..21e9eaf914dd 100644 --- a/arch/arm64/boot/dts/qcom/sa8540p-ride.dts +++ b/arch/arm64/boot/dts/qcom/sa8540p-ride.dts @@ -151,6 +151,184 @@ vreg_l8g: ldo8 { }; }; +ðernet0 { + snps,mtl-rx-config = <ðernet0_mtl_rx_setup>; + snps,mtl-tx-config = <ðernet0_mtl_tx_setup>; + + max-speed = <1000>; + phy-handle = <&rgmii_phy>; + phy-mode = "rgmii-txid"; + + pinctrl-names = "default"; + pinctrl-0 = <ðernet0_default>; + + status = "okay"; + + mdio { + compatible = "snps,dwmac-mdio"; + #address-cells = <1>; + #size-cells = <0>; + + /* Marvell 88EA1512 */ + rgmii_phy: phy@8 { + reg = <0x8>; + + interrupts-extended = <&tlmm 127 IRQ_TYPE_EDGE_FALLING>; + + reset-gpios = <&pmm8540c_gpios 1 GPIO_ACTIVE_LOW>; + reset-assert-us = <11000>; + reset-deassert-us = <70000>; + + device_type = "ethernet-phy"; + + /* Set to RGMII_SGMII mode and soft reset. Turn off auto-negotiation + * from userspace to talk to the switch on the SGMII side of things + */ + marvell,reg-init = + /* Set MODE[2:0] to RGMII_SGMII */ + <0x12 0x14 0xfff8 0x4>, + /* Soft reset required after changing MODE[2:0] */ + <0x12 0x14 0x7fff 0x8000>; + }; + }; + + ethernet0_mtl_rx_setup: rx-queues-config { + snps,rx-queues-to-use = <1>; + snps,rx-sched-sp; + + queue0 { + snps,dcb-algorithm; + snps,map-to-dma-channel = <0x0>; + snps,route-up; + snps,priority = <0x1>; + }; + + queue1 { + snps,dcb-algorithm; + snps,map-to-dma-channel = <0x1>; + snps,route-ptp; + }; + + queue2 { + snps,avb-algorithm; + snps,map-to-dma-channel = <0x2>; + snps,route-avcp; + }; + + queue3 { + snps,avb-algorithm; + snps,map-to-dma-channel = <0x3>; + snps,priority = <0xc>; + }; + }; + + ethernet0_mtl_tx_setup: tx-queues-config { + snps,tx-queues-to-use = <1>; + snps,tx-sched-sp; + + queue0 { + snps,dcb-algorithm; + }; + + queue1 { + snps,dcb-algorithm; + }; + + queue2 { + snps,avb-algorithm; + snps,send_slope = <0x1000>; + snps,idle_slope = <0x1000>; + snps,high_credit = <0x3e800>; + snps,low_credit = <0xffc18000>; + }; + + queue3 { + snps,avb-algorithm; + snps,send_slope = <0x1000>; + snps,idle_slope = <0x1000>; + snps,high_credit = <0x3e800>; + snps,low_credit = <0xffc18000>; + }; + }; +}; + +ðernet1 { + snps,mtl-rx-config = <ðernet1_mtl_rx_setup>; + snps,mtl-tx-config = <ðernet1_mtl_tx_setup>; + + max-speed = <1000>; + phy-mode = "rgmii-txid"; + + pinctrl-names = "default"; + pinctrl-0 = <ðernet1_default>; + + status = "okay"; + + fixed-link { + speed = <1000>; + full-duplex; + }; + + ethernet1_mtl_rx_setup: rx-queues-config { + snps,rx-queues-to-use = <1>; + snps,rx-sched-sp; + + queue0 { + snps,dcb-algorithm; + snps,map-to-dma-channel = <0x0>; + snps,route-up; + snps,priority = <0x1>; + }; + + queue1 { + snps,dcb-algorithm; + snps,map-to-dma-channel = <0x1>; + snps,route-ptp; + }; + + queue2 { + snps,avb-algorithm; + snps,map-to-dma-channel = <0x2>; + snps,route-avcp; + }; + + queue3 { + snps,avb-algorithm; + snps,map-to-dma-channel = <0x3>; + snps,priority = <0xc>; + }; + }; + + ethernet1_mtl_tx_setup: tx-queues-config { + snps,tx-queues-to-use = <1>; + snps,tx-sched-sp; + + queue0 { + snps,dcb-algorithm; + }; + + queue1 { + snps,dcb-algorithm; + }; + + queue2 { + snps,avb-algorithm; + snps,send_slope = <0x1000>; + snps,idle_slope = <0x1000>; + snps,high_credit = <0x3e800>; + snps,low_credit = <0xffc18000>; + }; + + queue3 { + snps,avb-algorithm; + snps,send_slope = <0x1000>; + snps,idle_slope = <0x1000>; + snps,high_credit = <0x3e800>; + snps,low_credit = <0xffc18000>; + }; + }; +}; + &i2c0 { pinctrl-names = "default"; pinctrl-0 = <&i2c0_default>; @@ -316,6 +494,66 @@ &xo_board_clk { /* PINCTRL */ &tlmm { + ethernet0_default: ethernet0-default-state { + mdc-pins { + pins = "gpio175"; + function = "rgmii_0"; + drive-strength = <16>; + bias-pull-up; + }; + + mdio-pins { + pins = "gpio176"; + function = "rgmii_0"; + drive-strength = <16>; + bias-pull-up; + }; + + rgmii-tx-pins { + pins = "gpio183", "gpio184", "gpio185", "gpio186", "gpio187", "gpio188"; + function = "rgmii_0"; + drive-strength = <16>; + bias-pull-up; + }; + + rgmii-rx-pins { + pins = "gpio177", "gpio178", "gpio179", "gpio180", "gpio181", "gpio182"; + function = "rgmii_0"; + drive-strength = <16>; + bias-disable; + }; + }; + + ethernet1_default: ethernet1-default-state { + mdc-pins { + pins = "gpio97"; + function = "rgmii_1"; + drive-strength = <16>; + bias-pull-up; + }; + + mdio-pins { + pins = "gpio98"; + function = "rgmii_1"; + drive-strength = <16>; + bias-pull-up; + }; + + rgmii-tx-pins { + pins = "gpio105", "gpio106", "gpio107", "gpio108", "gpio109", "gpio110"; + function = "rgmii_1"; + drive-strength = <16>; + bias-pull-up; + }; + + rgmii-rx-pins { + pins = "gpio99", "gpio100", "gpio101", "gpio102", "gpio103", "gpio104"; + function = "rgmii_1"; + drive-strength = <16>; + bias-disable; + }; + }; + i2c0_default: i2c0-default-state { /* To USB7002T-I/KDXVA0 USB hub (SIP1 only) */ pins = "gpio135", "gpio136";