Received: by 2002:a89:d88:0:b0:1fa:5c73:8e2d with SMTP id eb8csp412352lqb; Fri, 24 May 2024 02:07:54 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWpP16V/qkEmfjLxm+4qUYofLq+LEv719K872FNu1A/RX4OZQKlYzKgkcvwdpINgDS3qKI5OBhwohze6/rrkBZ8noPGsNI1dbnFI8/viA== X-Google-Smtp-Source: AGHT+IFlkvvEu+ev1QUPn96Hs+L+9SjOxiJ654YmdgXo70vdQulRF49glSEE8wp/c+Gq3XGF09QA X-Received: by 2002:ac8:5dc6:0:b0:43b:7be:15a1 with SMTP id d75a77b69052e-43fb0e4a8aemr17699141cf.12.1716541674607; Fri, 24 May 2024 02:07:54 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716541674; cv=pass; d=google.com; s=arc-20160816; b=wMqYex5B3x1yEXA2doymrWU3wePU1W/WVUExo9MdATImx7tGyN2hNGPGZ2pDVNvY7u oaciNciconLMJ21rw5GSJs3dxBKzYJC2QSkAp7hs2EamIbok8YO7CnJm2tM1EVDE5p7g i1+0YvIY2yzsB4JibYufma2wIi8c4krN5E2Y/fb66n/OKie6OEg9p1ppkMFCBWMlpCd0 NArq4eoXlrBL2rtNxzInRPSAkicTULD2hT4kFis1jpIWSpPNcaZgYNSxl3pzN9u8Tj8j 49eaXiPg2yw71WREDqJdpn1Qcun3ykYjrq6+HdDrkm91gbBWBjE76CQz6isjGqXOkaTN Yvrg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=wc2dY3olrF19WzQwpC81iLuubWXUUGHsClDovydRv+Q=; fh=v0teqksL3xO+SLXxmXdn9hV0IgnSHmLX2R1lVYr4iek=; b=CVlWk//HOWebTElBmlsgZ28lA+EcPMUkaXE+2dEG5i38yy5ObyNxc4L7wp4YwQLWb6 y7ICnayPnWooFiUYgvyjPyaJMORn4S8LjEhKvh8Pt3Tgupc3VBvkv6ANQPb9jUfdRg10 G3aGYP6EMd4/0jJyTfeAn0s9tXGqTHJL/ZfUgBV+hd4FDe6k8hhNe0T8JXR6YOMGWtCY Ju/yJo65mwYC6YTv/427vkX6/insZ7QUlhAUoppFTq0XFyL9xZUoGJ/9XnhEThCjlAes 1MJI8z8Mz5nI1WEhFDCrsFZhrn5fYvGH2LiGZPpmmwEkS1nkuEUPgF/GWRE8qlVcl4Ku ErbQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=qORj5Z04; arc=pass (i=1 spf=pass spfdomain=ti.com dkim=pass dkdomain=ti.com dmarc=pass fromdomain=ti.com); spf=pass (google.com: domain of linux-kernel+bounces-188522-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-188522-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id d75a77b69052e-43fb18ea317si13709931cf.794.2024.05.24.02.07.54 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 24 May 2024 02:07:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-188522-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=qORj5Z04; arc=pass (i=1 spf=pass spfdomain=ti.com dkim=pass dkdomain=ti.com dmarc=pass fromdomain=ti.com); spf=pass (google.com: domain of linux-kernel+bounces-188522-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-188522-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 575CC1C21A10 for ; Fri, 24 May 2024 09:07:54 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AE34912C493; Fri, 24 May 2024 09:06:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="qORj5Z04" Received: from lelv0142.ext.ti.com (lelv0142.ext.ti.com [198.47.23.249]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4A487129A8D; Fri, 24 May 2024 09:06:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.47.23.249 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716541562; cv=none; b=dCZ6iyvvrJYykkWyWagmlhPB/df3qDdT8BDkzMe8YV8b+NqJxrZkfB4P7peCkRNK9Cjh2cBVxzStFRkpTyZ2FJ06dq9ODoPQW+ZWBCzxjzgwLA3mfbc02YLSDg9DPbCamkPfLT719gQgGqFuF4vMCcs8JJ3EFcU+ETSx8M+/UUs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716541562; c=relaxed/simple; bh=xZA4BkXOmae5sDVcBgar+n9txAQk3eLKOo8BzZvDjQw=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=dVsq0jLMTD72SIJgJXzmnRysfxW7iTwBPIsXCdYLlWjscAUv0jRsfPU+RAW48kkA4gKpjrfZd+VwnC5/9xoogZvHoYUJqcmUAE3iARBoC4jgCM2Ls45D2ys4wlgNYcPUKNqPmBDBlc+zJud4pR9vsAu669LnW1eIewMBZFQqsoc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=qORj5Z04; arc=none smtp.client-ip=198.47.23.249 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Received: from lelv0265.itg.ti.com ([10.180.67.224]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id 44O95one001503; Fri, 24 May 2024 04:05:50 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1716541550; bh=wc2dY3olrF19WzQwpC81iLuubWXUUGHsClDovydRv+Q=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=qORj5Z04dneFzn3FQgVf9t0N/bd2S6sV/hcobafNt5zvPbk99kMyMWwN3gYlW3jOa w3/FR32Y3GdodpQN4OULuWAlxvMwD6+Ruu5d67s026MtO2EhzMkt9sTNiEWjZ1Nu0f RrU0SCzU7DNdq+o0pVkWg9pE10JRvMZBcBOulylU= Received: from DLEE103.ent.ti.com (dlee103.ent.ti.com [157.170.170.33]) by lelv0265.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 44O95ocA028968 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Fri, 24 May 2024 04:05:50 -0500 Received: from DLEE112.ent.ti.com (157.170.170.23) by DLEE103.ent.ti.com (157.170.170.33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Fri, 24 May 2024 04:05:50 -0500 Received: from lelvsmtp5.itg.ti.com (10.180.75.250) by DLEE112.ent.ti.com (157.170.170.23) 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; Fri, 24 May 2024 04:05:50 -0500 Received: from uda0492258.dhcp.ti.com (uda0492258.dhcp.ti.com [172.24.227.9]) by lelvsmtp5.itg.ti.com (8.15.2/8.15.2) with ESMTP id 44O95F7M017455; Fri, 24 May 2024 04:05:46 -0500 From: Siddharth Vadapalli To: , , , , , , , CC: , , , , , , Subject: [PATCH v3 7/7] arm64: dts: ti: k3-j722s: Add support for PCIe0 Date: Fri, 24 May 2024 14:35:14 +0530 Message-ID: <20240524090514.152727-8-s-vadapalli@ti.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20240524090514.152727-1-s-vadapalli@ti.com> References: <20240524090514.152727-1-s-vadapalli@ti.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 The PCIe0 instance of PCIe on TI's J722S SoC is a Gen3 single lane PCIe controller. Add the device-tree nodes for it and enable it in Root Complex mode of operation using Lane 0 of the Serdes1 instance of Serdes. Signed-off-by: Siddharth Vadapalli --- Current patch is v1. No changelog. arch/arm64/boot/dts/ti/k3-j722s-evm.dts | 17 +++++++++++ arch/arm64/boot/dts/ti/k3-j722s-main.dtsi | 37 +++++++++++++++++++++++ 2 files changed, 54 insertions(+) diff --git a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts index 16c6ab8ee07e..d2d7de5cfe27 100644 --- a/arch/arm64/boot/dts/ti/k3-j722s-evm.dts +++ b/arch/arm64/boot/dts/ti/k3-j722s-evm.dts @@ -416,6 +416,16 @@ serdes0_usb_link: phy@0 { }; }; +&serdes1 { + serdes1_pcie_link: phy@0 { + reg = <0>; + cdns,num-lanes = <1>; + #phy-cells = <0>; + cdns,phy-type = ; + resets = <&serdes_wiz1 1>; + }; +}; + &usbss0 { ti,vbus-divider; status = "okay"; @@ -439,3 +449,10 @@ &usb1 { phys = <&serdes0_usb_link>; phy-names = "cdns3,usb3-phy"; }; + +&pcie0_rc { + status = "okay"; + reset-gpios = <&exp1 18 GPIO_ACTIVE_HIGH>; + phys = <&serdes1_pcie_link>; + phy-names = "pcie-phy"; +}; diff --git a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi index 19a7e8413ad2..0b32893eb75e 100644 --- a/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi +++ b/arch/arm64/boot/dts/ti/k3-j722s-main.dtsi @@ -4,6 +4,7 @@ * Copyright (C) 2023-2024 Texas Instruments Incorporated - https://www.ti.com/ */ +#include #include /* @@ -96,6 +97,35 @@ serdes1: serdes@f010000 { }; }; + pcie0_rc: pcie@f102000 { + compatible = "ti,j722s-pcie-host", "ti,j721e-pcie-host"; + reg = <0x00 0x0f102000 0x00 0x1000>, + <0x00 0x0f100000 0x00 0x400>, + <0x00 0x0d000000 0x00 0x00800000>, + <0x00 0x68000000 0x00 0x00001000>; + reg-names = "intd_cfg", "user_cfg", "reg", "cfg"; + ranges = <0x01000000 0x00 0x68001000 0x00 0x68001000 0x00 0x0010000>, + <0x02000000 0x00 0x68011000 0x00 0x68011000 0x00 0x7fef000>; + dma-ranges = <0x02000000 0x0 0x0 0x0 0x0 0x10000 0x0>; + interrupt-names = "link_state"; + interrupts = ; + device_type = "pci"; + max-link-speed = <3>; + num-lanes = <1>; + power-domains = <&k3_pds 259 TI_SCI_PD_EXCLUSIVE>; + clocks = <&k3_clks 259 0>, <&serdes1 CDNS_TORRENT_REFCLK_DRIVER>; + clock-names = "fck", "pcie_refclk"; + #address-cells = <3>; + #size-cells = <2>; + bus-range = <0x0 0xff>; + vendor-id = <0x104c>; + device-id = <0xb010>; + cdns,no-bar-match-nbits = <64>; + ti,syscon-pcie-ctrl = <&pcie0_ctrl 0x0>; + msi-map = <0x0 &gic_its 0x0 0x10000>; + status = "disabled"; + }; + usbss1: usb@f920000 { compatible = "ti,j721e-usb"; reg = <0x00 0x0f920000 0x00 0x100>; @@ -138,3 +168,10 @@ serdes_ln_ctrl: mux-controller@4080 { <0x10 0x3>; /* SERDES1 lane0 select */ }; }; + +&wkup_conf { + pcie0_ctrl: pcie0-ctrl@4070 { + compatible = "ti,j784s4-pcie-ctrl", "syscon"; + reg = <0x4070 0x4>; + }; +}; -- 2.40.1