From patchwork Thu Jan 25 13:03:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 766141 Received: from mail-ed1-f54.google.com (mail-ed1-f54.google.com [209.85.208.54]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5FF334F89D for ; Thu, 25 Jan 2024 13:03:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.54 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706187841; cv=none; b=fWnG3ahUUEx9LojFZLkGwK5/fE8mbfOBc1uUUizkpkynnMzuMrSDGpNoa1BnA7bft+jel/udXenfRYDQcEEXiV7OtDfjepJndqqMeh1/ryNaBvc+QAeeyUqwu/ihV9ufWTMOxGT6FsPCysjcvzv7/MF40pKun0JCRVuG5P5L1vA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706187841; c=relaxed/simple; bh=Q/Tocvh9EXB7maJsWvrdsfs89mbAIyPguSmeuPPim+M=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=KnST6cxq+HTYWpJdyMVyrqusZua5pMntJSC8x5WmcQ6hsUx17PBnnCFmfCl8EiI5jJydbQJ/QXsZRlacjHVNBBrqWyAjKUrIN/bky4smnX2IA5RYGnlqUgm0ZhlEx6pnroofruL4TZNuBFE5lXKvcW03mwSJVBAaFX8M6HgGB9I= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=vJMFKqZs; arc=none smtp.client-ip=209.85.208.54 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="vJMFKqZs" Received: by mail-ed1-f54.google.com with SMTP id 4fb4d7f45d1cf-55a45a453eeso8460281a12.0 for ; Thu, 25 Jan 2024 05:03:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1706187838; x=1706792638; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=6M//4gavqKqAX98RMN/hrCVHrhUbgeSamdA2/agqIGQ=; b=vJMFKqZszgm8mKeHqVGDXjoOwVv1VmlaKQITx2H+qjUPyPhwcGXzCUCKaXWgUS4aRb ij/RC6Kp4Ry4GdqikNJ2fcr4sDamhBQdyRzgbNMn9mtdIAh7jDVTj3Wr+VpbrLN8nfUZ IDTEyBd7X6cXQPkzDohlb2iA2Oy+/ZjXmFmWgk02c9/rlOsKZXqMKcL0MThhLNqYNMdG fgSie+TDyRyycYrHbb/7pczYZfi1gai1LOwwmmNh4WPSA5vBksfNdSTwc4eh8q78NLt3 SB5lQphagAovC4WpCfEQ8QxlxFdTL0PxqNESUEmICwB8iHJ3d+QINYxTU6k7E3eCiQQr TX3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706187838; x=1706792638; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=6M//4gavqKqAX98RMN/hrCVHrhUbgeSamdA2/agqIGQ=; b=TpKDMJ2Anh58vaMVFE5Pa4ti+SiGY/0B7CdukDhyNKRcKUqti4ajJjSba7HrlSBivO vYy77i7hPf0zR8UUZ5UkvwEyeZAwHo48Es2dmHpXyARIfL8UwTL+hkZ9Ctpkts0qWQpE V7bDlatxtpaBq5qk977QWAGUKe+uoAQeqVycrrzwwdlb0rZTLt0IS5NG123+rczWSEnD 2vGlLB2o5+OWozfGc6gLpETkwblnSQp/jZg4XFBVXUhc52RX+bZz5bGXr21f2RNFeZ3u SNsSJ3a+6iCckiOXlVZI/krhubDx4S0iVDGxraDQWzp7Xe/Yap/WZMPG8DRfHCQ8pgCC ANEw== X-Gm-Message-State: AOJu0YwCcIpXzdrUXzzQORtFEPJeyfmuaw4Q/yHnR4DSkUi7IxLQWlIg 7DuzBgl43y0qOIV06zgr4iyNgY6S26GWwng8rEyPVo6uhRkv0k/f/O+Y//d+JL8= X-Google-Smtp-Source: AGHT+IHRSECyVnPsASGjX1hHcootr6LAKKl1InX+5g7JuJp+LYMsXeYYCRlRcpvNoBGLaHbbfGMPOg== X-Received: by 2002:a17:907:367:b0:a30:858f:6186 with SMTP id rs7-20020a170907036700b00a30858f6186mr641050ejb.40.1706187837612; Thu, 25 Jan 2024 05:03:57 -0800 (PST) Received: from [127.0.1.1] ([178.197.215.66]) by smtp.gmail.com with ESMTPSA id tx24-20020a1709078e9800b00a31c5caa750sm294079ejc.177.2024.01.25.05.03.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Jan 2024 05:03:57 -0800 (PST) From: Krzysztof Kozlowski Date: Thu, 25 Jan 2024 14:03:25 +0100 Subject: [PATCH v2 2/6] dt-bindings: PCI: qcom,pcie-sm8450: move SM8450 to dedicated schema Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240125-dt-bindings-pci-qcom-split-v2-2-6b58efd91a7a@linaro.org> References: <20240125-dt-bindings-pci-qcom-split-v2-0-6b58efd91a7a@linaro.org> In-Reply-To: <20240125-dt-bindings-pci-qcom-split-v2-0-6b58efd91a7a@linaro.org> To: Bjorn Andersson , Konrad Dybcio , Lorenzo Pieralisi , =?utf-8?q?Krzysztof_Wilczy?= =?utf-8?q?=C5=84ski?= , Bjorn Helgaas , Krzysztof Kozlowski , Rob Herring , Conor Dooley , Manivannan Sadhasivam Cc: linux-arm-msm@vger.kernel.org, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Manivannan Sadhasivam , Krzysztof Kozlowski X-Mailer: b4 0.12.4 X-Developer-Signature: v=1; a=openpgp-sha256; l=10238; i=krzysztof.kozlowski@linaro.org; h=from:subject:message-id; bh=Q/Tocvh9EXB7maJsWvrdsfs89mbAIyPguSmeuPPim+M=; b=owEBbQKS/ZANAwAKAcE3ZuaGi4PXAcsmYgBlslwz/cJqG2zI6+Fs5qEAiFV1ABSwCkcUCuge4 5GM0X0YF9SJAjMEAAEKAB0WIQTd0mIoPREbIztuuKjBN2bmhouD1wUCZbJcMwAKCRDBN2bmhouD 1w2LD/4t+JHejnCaPLlOEidnLW7DDEzOBUwqxU7uXvw/mVC7E6c6wgMrnXrnlOtcxgCN+nXNzFR xqsA/HL2kJ0WO3yl6+txbx3yjSGoH5xKUuLMnT0Namtuw/p/l/4ip9mwzb5bJhmYGG2+1u+DrM1 uXRG5tweCbo3AOFkJ+Sm9tkO6GTNT02HcwDGFHaVm2OjN9Uq8wt1qSoONcOwSzvqIGb5i4Gb2/3 w+22SRnWMmMC5eZbKmt+YN8/Wu1pQudTUWdNp/P0geOk1vq+CN6RuCcUl9gqcN2CGYcIw6NfaGy IRMrkAJ97CfScJyf/onbwYXeGpCoTkQuCHsxs4OjwwJs5VgKEqYjAmQxj9j96d5/Q8Zp3u95vco 0ORhJHoMxZbDQm7GcxhKmD/jVcWGmhoScoowS73vYHZ3sZwlRC8Ex9Nvlp3vr1HZw47+lTLOJQb CYRK/J9VS0XQsUwpv+x+irfC5CpP206DgJ3YK2M8P2L0tdb653xtkdDIMhP/VzFUHicZr4ZtvVS EGmcIrzmU4/kpQ9hVr0iXLG+otCRs88CnmgRqZ9aiF99algncWwshasVx/W/wOXBLGkt3IdmNN0 iyLWTWg2b9wUnp+rPlqQJDn1ueEHpjuI6jNMq6pY41ta84pnJwKBG8DnNmtiXFrxSMaCciHfSuR Jlw3Ztpa8vqAFnw== X-Developer-Key: i=krzysztof.kozlowski@linaro.org; a=openpgp; fpr=9BD07E0E0C51F8D59677B7541B93437D3B41629B Move SM8450 PCIe devices from qcom,pcie.yaml binding to a dedicated file to make reviewing easier. This creates equivalent schema file, except: - Missing required compatible which is actually redundant. - Expecting eight MSI interrupts, instead of only one, which was incomplete hardware description. Acked-by: Manivannan Sadhasivam Signed-off-by: Krzysztof Kozlowski --- .../devicetree/bindings/pci/qcom,pcie-sm8450.yaml | 175 +++++++++++++++++++++ .../devicetree/bindings/pci/qcom,pcie.yaml | 67 -------- 2 files changed, 175 insertions(+), 67 deletions(-) diff --git a/Documentation/devicetree/bindings/pci/qcom,pcie-sm8450.yaml b/Documentation/devicetree/bindings/pci/qcom,pcie-sm8450.yaml new file mode 100644 index 000000000000..eff5bf7bd022 --- /dev/null +++ b/Documentation/devicetree/bindings/pci/qcom,pcie-sm8450.yaml @@ -0,0 +1,175 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/pci/qcom,pcie-sm8450.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm SM8450 PCI Express Root Complex + +maintainers: + - Bjorn Andersson + - Manivannan Sadhasivam + +description: + Qualcomm SM8450 SoC PCIe root complex controller is based on the Synopsys + DesignWare PCIe IP. + +properties: + compatible: + enum: + - qcom,pcie-sm8450-pcie0 + - qcom,pcie-sm8450-pcie1 + + reg: + minItems: 5 + maxItems: 6 + + reg-names: + minItems: 5 + items: + - const: parf # Qualcomm specific registers + - const: dbi # DesignWare PCIe registers + - const: elbi # External local bus interface registers + - const: atu # ATU address space + - const: config # PCIe configuration space + - const: mhi # MHI registers + + clocks: + minItems: 11 + maxItems: 12 + + clock-names: + minItems: 11 + items: + - const: pipe # PIPE clock + - const: pipe_mux # PIPE MUX + - const: phy_pipe # PIPE output clock + - const: ref # REFERENCE clock + - const: aux # Auxiliary clock + - const: cfg # Configuration clock + - const: bus_master # Master AXI clock + - const: bus_slave # Slave AXI clock + - const: slave_q2a # Slave Q2A clock + - const: ddrss_sf_tbu # PCIe SF TBU clock + - enum: [aggre0, aggre1] # Aggre NoC PCIe0/1 AXI clock + - const: aggre1 # Aggre NoC PCIe1 AXI clock + + interrupts: + minItems: 8 + maxItems: 8 + + interrupt-names: + items: + - const: msi0 + - const: msi1 + - const: msi2 + - const: msi3 + - const: msi4 + - const: msi5 + - const: msi6 + - const: msi7 + + resets: + maxItems: 1 + + reset-names: + items: + - const: pci + +unevaluatedProperties: false + +examples: + - | + #include + #include + #include + #include + #include + + soc { + #address-cells = <2>; + #size-cells = <2>; + + pcie@1c00000 { + compatible = "qcom,pcie-sm8450-pcie0"; + reg = <0 0x01c00000 0 0x3000>, + <0 0x60000000 0 0xf1d>, + <0 0x60000f20 0 0xa8>, + <0 0x60001000 0 0x1000>, + <0 0x60100000 0 0x100000>; + reg-names = "parf", "dbi", "elbi", "atu", "config"; + ranges = <0x01000000 0x0 0x00000000 0x0 0x60200000 0x0 0x100000>, + <0x02000000 0x0 0x60300000 0x0 0x60300000 0x0 0x3d00000>; + + bus-range = <0x00 0xff>; + device_type = "pci"; + linux,pci-domain = <0>; + max-link-speed = <2>; + num-lanes = <1>; + + #address-cells = <3>; + #size-cells = <2>; + + clocks = <&gcc GCC_PCIE_0_PIPE_CLK>, + <&gcc GCC_PCIE_0_PIPE_CLK_SRC>, + <&pcie0_phy>, + <&rpmhcc RPMH_CXO_CLK>, + <&gcc GCC_PCIE_0_AUX_CLK>, + <&gcc GCC_PCIE_0_CFG_AHB_CLK>, + <&gcc GCC_PCIE_0_MSTR_AXI_CLK>, + <&gcc GCC_PCIE_0_SLV_AXI_CLK>, + <&gcc GCC_PCIE_0_SLV_Q2A_AXI_CLK>, + <&gcc GCC_DDRSS_PCIE_SF_TBU_CLK>, + <&gcc GCC_AGGRE_NOC_PCIE_0_AXI_CLK>, + <&gcc GCC_AGGRE_NOC_PCIE_1_AXI_CLK>; + clock-names = "pipe", + "pipe_mux", + "phy_pipe", + "ref", + "aux", + "cfg", + "bus_master", + "bus_slave", + "slave_q2a", + "ddrss_sf_tbu", + "aggre0", + "aggre1"; + + interrupts = , + , + , + , + , + , + , + ; + interrupt-names = "msi0", "msi1", "msi2", "msi3", + "msi4", "msi5", "msi6", "msi7"; + #interrupt-cells = <1>; + interrupt-map-mask = <0 0 0 0x7>; + interrupt-map = <0 0 0 1 &intc 0 0 0 149 IRQ_TYPE_LEVEL_HIGH>, /* int_a */ + <0 0 0 2 &intc 0 0 0 150 IRQ_TYPE_LEVEL_HIGH>, /* int_b */ + <0 0 0 3 &intc 0 0 0 151 IRQ_TYPE_LEVEL_HIGH>, /* int_c */ + <0 0 0 4 &intc 0 0 0 152 IRQ_TYPE_LEVEL_HIGH>; /* int_d */ + msi-map = <0x0 &gic_its 0x5981 0x1>, + <0x100 &gic_its 0x5980 0x1>; + msi-map-mask = <0xff00>; + + iommu-map = <0x0 &apps_smmu 0x1c00 0x1>, + <0x100 &apps_smmu 0x1c01 0x1>; + + phys = <&pcie0_phy>; + phy-names = "pciephy"; + + pinctrl-0 = <&pcie0_default_state>; + pinctrl-names = "default"; + + power-domains = <&gcc PCIE_0_GDSC>; + + resets = <&gcc GCC_PCIE_0_BCR>; + reset-names = "pci"; + + perst-gpios = <&tlmm 94 GPIO_ACTIVE_LOW>; + wake-gpios = <&tlmm 96 GPIO_ACTIVE_HIGH>; + }; + }; diff --git a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml index 3b7dd9a4ef60..791ddab8ddc7 100644 --- a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml +++ b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml @@ -38,8 +38,6 @@ properties: - qcom,pcie-sm8150 - qcom,pcie-sm8250 - qcom,pcie-sm8350 - - qcom,pcie-sm8450-pcie0 - - qcom,pcie-sm8450-pcie1 - items: - const: qcom,pcie-msm8998 - const: qcom,pcie-msm8996 @@ -219,8 +217,6 @@ allOf: - qcom,pcie-sdx55 - qcom,pcie-sm8250 - qcom,pcie-sm8350 - - qcom,pcie-sm8450-pcie0 - - qcom,pcie-sm8450-pcie1 then: properties: reg: @@ -648,67 +644,6 @@ allOf: items: - const: pci # PCIe core reset - - if: - properties: - compatible: - contains: - enum: - - qcom,pcie-sm8450-pcie0 - then: - properties: - clocks: - minItems: 12 - maxItems: 12 - clock-names: - items: - - const: pipe # PIPE clock - - const: pipe_mux # PIPE MUX - - const: phy_pipe # PIPE output clock - - const: ref # REFERENCE clock - - const: aux # Auxiliary clock - - const: cfg # Configuration clock - - const: bus_master # Master AXI clock - - const: bus_slave # Slave AXI clock - - const: slave_q2a # Slave Q2A clock - - const: ddrss_sf_tbu # PCIe SF TBU clock - - const: aggre0 # Aggre NoC PCIe0 AXI clock - - const: aggre1 # Aggre NoC PCIe1 AXI clock - resets: - maxItems: 1 - reset-names: - items: - - const: pci # PCIe core reset - - - if: - properties: - compatible: - contains: - enum: - - qcom,pcie-sm8450-pcie1 - then: - properties: - clocks: - minItems: 11 - maxItems: 11 - clock-names: - items: - - const: pipe # PIPE clock - - const: pipe_mux # PIPE MUX - - const: phy_pipe # PIPE output clock - - const: ref # REFERENCE clock - - const: aux # Auxiliary clock - - const: cfg # Configuration clock - - const: bus_master # Master AXI clock - - const: bus_slave # Slave AXI clock - - const: slave_q2a # Slave Q2A clock - - const: ddrss_sf_tbu # PCIe SF TBU clock - - const: aggre1 # Aggre NoC PCIe1 AXI clock - resets: - maxItems: 1 - reset-names: - items: - - const: pci # PCIe core reset - - if: properties: compatible: @@ -844,8 +779,6 @@ allOf: - qcom,pcie-sm8150 - qcom,pcie-sm8250 - qcom,pcie-sm8350 - - qcom,pcie-sm8450-pcie0 - - qcom,pcie-sm8450-pcie1 then: oneOf: - properties: From patchwork Thu Jan 25 13:03:27 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 766140 Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 001AD51003 for ; Thu, 25 Jan 2024 13:04:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.51 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706187845; cv=none; b=dSIbaoB3nNh2OoMZzxEEJVokzhvnb2jVJQ3i1jDjC2SmMGfAI9JqeSHVVfkQKjgRlanum/o4zD4BZoJWyD7CwtFBpXsVR4nFgtowC2jE5uzS8tESPDJmcP3JKqEZXGzPuquN0Ovrh2x8SkX77369FS32g2bWf3t88oV5WFYWCdA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706187845; c=relaxed/simple; bh=L2tu3oVaNutiUYx1lhf/hq1yv4Gzm5YHggLrHFEaVTI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=KR7GTQtg/w8+QlXvtflETNM04OvPkoGmjiKeBbSiAA2YoVfI/SfoF3K4nz/qUlWLvASaNNGNK3Cg8sUPaCDT1UBuqePjWC0/e6vj//un2V3zCR13LmpsA2ZPKj3n+4PijJvJAgAlbts0LSnxhcaFLv2Db/lWTi9FGA02zhzAtXY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=nwfsMCeP; arc=none smtp.client-ip=209.85.167.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="nwfsMCeP" Received: by mail-lf1-f51.google.com with SMTP id 2adb3069b0e04-50f1c524010so7622079e87.3 for ; Thu, 25 Jan 2024 05:04:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1706187842; x=1706792642; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=yb0WcvqtQcLyXdbtPa/dVBnzAG+9fpalgiYlCkLzkns=; b=nwfsMCePpXaaySQkic5HidLnaDM3++CyyopAuk3l1AcQsYGHq9HrbASOeUXH+x0KsO 54UFLs1Ns7/OAEjLdk2kIzP1bsAJ2QnOrNaCL8IO+6wjj2Nn0k6ifUewSm6wxC7MteeL juXm/gQhvvqlQUYkmh3ep89wiBzLuIeyxtH+nrrvUL9iOZbSRzDp5IcqqXDJQIyrgcQp h8kqFx9PhwiO6K/G1m5wCuqVBwsvPnUkiTvY7L2cSysVx2cZiTEkwHzoabdbH2hFzrfq 039x3aBKoK/QqVF/zvLgydFTspcBxzTFP4ZYRpxd0KRSg1XkHkXkQHSsCNXPQRm3kw4M IO4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706187842; x=1706792642; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=yb0WcvqtQcLyXdbtPa/dVBnzAG+9fpalgiYlCkLzkns=; b=LgCXWiRypOh/gGccJEDj3HrFgeqxa1XzYzRp9/nWv0Q4XgwLiioJnMQqTwzsRs9NIR kSD5z7AHwtlKc9zA56u/7iqBz6AbGNqpHOuT9yiX54/UN07P035KtOFuORNFe0MYvDsb 8BEm8CALjSmWte8dl8Ri9o//W/sDDYtTXk67bVxbnQFELjX2M4Wk2pbrU8ZuB/Y8YxUY JR7lOPnECBbGARauVMv/6QszxgjJ4U6YciwnlXNMSZFRDmnDNrgqFkZ0uSkKq4bJRJGE hTc7CKFnNN8d/yewnQFZgIs7yJWSN7yQoZHn+ly2DoH/6nu9foypnTFDIvKnxiWNIpBQ O0hQ== X-Gm-Message-State: AOJu0YwzL7AnO2nmLqn4l+EP+2xYcwW6/GF+VixNlbPn1nuFFlBZJk7X a5rYm5RUgdzl4dw8/MjoQE8W7iTsBBpmNCw+JOCM5g2iBd5P1INvQ1il8AYgHpQ= X-Google-Smtp-Source: AGHT+IFUbJjX+Ypx5/lnO5uD083FbLjDvYECn4Rghok4vuvhNv6Vc4Des1Umco+71XNwJe9IpnF5Gg== X-Received: by 2002:a19:f504:0:b0:50e:84ad:3e29 with SMTP id j4-20020a19f504000000b0050e84ad3e29mr228052lfb.136.1706187841993; Thu, 25 Jan 2024 05:04:01 -0800 (PST) Received: from [127.0.1.1] ([178.197.215.66]) by smtp.gmail.com with ESMTPSA id tx24-20020a1709078e9800b00a31c5caa750sm294079ejc.177.2024.01.25.05.04.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Jan 2024 05:04:01 -0800 (PST) From: Krzysztof Kozlowski Date: Thu, 25 Jan 2024 14:03:27 +0100 Subject: [PATCH v2 4/6] dt-bindings: PCI: qcom,pcie-sm8150: move SM8150 to dedicated schema Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240125-dt-bindings-pci-qcom-split-v2-4-6b58efd91a7a@linaro.org> References: <20240125-dt-bindings-pci-qcom-split-v2-0-6b58efd91a7a@linaro.org> In-Reply-To: <20240125-dt-bindings-pci-qcom-split-v2-0-6b58efd91a7a@linaro.org> To: Bjorn Andersson , Konrad Dybcio , Lorenzo Pieralisi , =?utf-8?q?Krzysztof_Wilczy?= =?utf-8?q?=C5=84ski?= , Bjorn Helgaas , Krzysztof Kozlowski , Rob Herring , Conor Dooley , Manivannan Sadhasivam Cc: linux-arm-msm@vger.kernel.org, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Rob Herring , Manivannan Sadhasivam , Krzysztof Kozlowski X-Mailer: b4 0.12.4 X-Developer-Signature: v=1; a=openpgp-sha256; l=7937; i=krzysztof.kozlowski@linaro.org; h=from:subject:message-id; bh=L2tu3oVaNutiUYx1lhf/hq1yv4Gzm5YHggLrHFEaVTI=; b=owEBbQKS/ZANAwAKAcE3ZuaGi4PXAcsmYgBlslw1HCDINfvmJk3s6gXTL1ZMT6TJ7iI6Xrc/B BbDMUfFMzeJAjMEAAEKAB0WIQTd0mIoPREbIztuuKjBN2bmhouD1wUCZbJcNQAKCRDBN2bmhouD 16J3D/0WLrFSq2QPB8aT2I64+6619ZRQC13AJHi2vHzxpxCwJvJ5jmGIr/nWzousY7O+UYEM42H IE3RccPGsp01MO0KHSnG74lH6HUQsYAERFyOtht5a+bJNyuE5wPgz2RlJkUohWaq8HNYrkB0ogG v3IdL4SHYUjB0I0myRKH3vhqbdm6wjYcgy4MshbRCzYJ3tVNnYPgMBgeQ4+IZ/KQdP+45pB6uKq VhrkXXzqiIAsug8ZTXzijgMrgkWzIcoTobEl4M1/ZDKnvOqUwHSlo+xqUOLsWZoNjqy/mY0J4b0 zduW901+zEdj/F8fDWvh7RI1gvOqn24MK06hqC3SRW2LrpVwwVVMM+bVda5QJrFggeb+pE7hnKS eqjHA2w8r4sRnsF4/Pk9+F5mHlQY/499alowYl4IMYgOXWNIiRNHXnOpzSqQIFLxqTv/dkBU2F4 +mfhDRaeJM3xGm7jcXwTgGl9vmXVfv6rzzc9uk3w89hZE5gKt/is3AgOhoyIAsjXZjuzyusbBTh VkptkniFevcakw9E6c8BCuf35ey6raWcyemEgsyZGHcuwZTAUuvcfazaUeM8Z11/Ua9hR+IWmRC VnSjl+q1RgKUVmmRA3VeJo8ha/TJqlc3CmKlL1+d9dYMAkImVHufCm6zQq9Ssu1XHFQV1myCJri GKqP58wly86ItRw== X-Developer-Key: i=krzysztof.kozlowski@linaro.org; a=openpgp; fpr=9BD07E0E0C51F8D59677B7541B93437D3B41629B Move SM8150 PCIe devices from qcom,pcie.yaml binding to a dedicated file to make reviewing easier. This creates equivalent schema file, except: - Missing required compatible which is actually redundant. - Expecting eight MSI interrupts, instead of only one, which was incomplete hardware description. Reviewed-by: Rob Herring Acked-by: Manivannan Sadhasivam Signed-off-by: Krzysztof Kozlowski --- .../devicetree/bindings/pci/qcom,pcie-sm8150.yaml | 158 +++++++++++++++++++++ .../devicetree/bindings/pci/qcom,pcie.yaml | 29 ---- 2 files changed, 158 insertions(+), 29 deletions(-) diff --git a/Documentation/devicetree/bindings/pci/qcom,pcie-sm8150.yaml b/Documentation/devicetree/bindings/pci/qcom,pcie-sm8150.yaml new file mode 100644 index 000000000000..9d569644fda9 --- /dev/null +++ b/Documentation/devicetree/bindings/pci/qcom,pcie-sm8150.yaml @@ -0,0 +1,158 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/pci/qcom,pcie-sm8150.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm SM8150 PCI Express Root Complex + +maintainers: + - Bjorn Andersson + - Manivannan Sadhasivam + +description: + Qualcomm SM8150 SoC PCIe root complex controller is based on the Synopsys + DesignWare PCIe IP. + +properties: + compatible: + const: qcom,pcie-sm8150 + + reg: + minItems: 5 + maxItems: 6 + + reg-names: + minItems: 5 + items: + - const: parf # Qualcomm specific registers + - const: dbi # DesignWare PCIe registers + - const: elbi # External local bus interface registers + - const: atu # ATU address space + - const: config # PCIe configuration space + - const: mhi # MHI registers + + clocks: + minItems: 8 + maxItems: 8 + + clock-names: + items: + - const: pipe # PIPE clock + - const: aux # Auxiliary clock + - const: cfg # Configuration clock + - const: bus_master # Master AXI clock + - const: bus_slave # Slave AXI clock + - const: slave_q2a # Slave Q2A clock + - const: tbu # PCIe TBU clock + - const: ref # REFERENCE clock + + interrupts: + minItems: 8 + maxItems: 8 + + interrupt-names: + items: + - const: msi0 + - const: msi1 + - const: msi2 + - const: msi3 + - const: msi4 + - const: msi5 + - const: msi6 + - const: msi7 + + resets: + maxItems: 1 + + reset-names: + items: + - const: pci + +allOf: + - $ref: qcom,pcie-common.yaml# + +unevaluatedProperties: false + +examples: + - | + #include + #include + #include + #include + #include + + soc { + #address-cells = <2>; + #size-cells = <2>; + pcie@1c00000 { + compatible = "qcom,pcie-sm8150"; + reg = <0 0x01c00000 0 0x3000>, + <0 0x60000000 0 0xf1d>, + <0 0x60000f20 0 0xa8>, + <0 0x60001000 0 0x1000>, + <0 0x60100000 0 0x100000>; + reg-names = "parf", "dbi", "elbi", "atu", "config"; + ranges = <0x01000000 0x0 0x00000000 0x0 0x60200000 0x0 0x100000>, + <0x02000000 0x0 0x60300000 0x0 0x60300000 0x0 0x3d00000>; + + bus-range = <0x00 0xff>; + device_type = "pci"; + linux,pci-domain = <0>; + num-lanes = <1>; + + #address-cells = <3>; + #size-cells = <2>; + + clocks = <&gcc GCC_PCIE_0_PIPE_CLK>, + <&gcc GCC_PCIE_0_AUX_CLK>, + <&gcc GCC_PCIE_0_CFG_AHB_CLK>, + <&gcc GCC_PCIE_0_MSTR_AXI_CLK>, + <&gcc GCC_PCIE_0_SLV_AXI_CLK>, + <&gcc GCC_PCIE_0_SLV_Q2A_AXI_CLK>, + <&gcc GCC_AGGRE_NOC_PCIE_TBU_CLK>, + <&rpmhcc RPMH_CXO_CLK>; + clock-names = "pipe", + "aux", + "cfg", + "bus_master", + "bus_slave", + "slave_q2a", + "tbu", + "ref"; + + interrupts = , + , + , + , + , + , + , + ; + interrupt-names = "msi0", "msi1", "msi2", "msi3", + "msi4", "msi5", "msi6", "msi7"; + #interrupt-cells = <1>; + interrupt-map-mask = <0 0 0 0x7>; + interrupt-map = <0 0 0 1 &intc 0 149 IRQ_TYPE_LEVEL_HIGH>, /* int_a */ + <0 0 0 2 &intc 0 150 IRQ_TYPE_LEVEL_HIGH>, /* int_b */ + <0 0 0 3 &intc 0 151 IRQ_TYPE_LEVEL_HIGH>, /* int_c */ + <0 0 0 4 &intc 0 152 IRQ_TYPE_LEVEL_HIGH>; /* int_d */ + + iommu-map = <0x0 &apps_smmu 0x1d80 0x1>, + <0x100 &apps_smmu 0x1d81 0x1>; + + phys = <&pcie0_phy>; + phy-names = "pciephy"; + + pinctrl-0 = <&pcie0_default_state>; + pinctrl-names = "default"; + + power-domains = <&gcc PCIE_0_GDSC>; + + resets = <&gcc GCC_PCIE_0_BCR>; + reset-names = "pci"; + + perst-gpios = <&tlmm 35 GPIO_ACTIVE_HIGH>; + wake-gpios = <&tlmm 37 GPIO_ACTIVE_HIGH>; + }; + }; diff --git a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml index 14341d210063..47888b5b1a13 100644 --- a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml +++ b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml @@ -35,7 +35,6 @@ properties: - qcom,pcie-sc8280xp - qcom,pcie-sdm845 - qcom,pcie-sdx55 - - qcom,pcie-sm8150 - qcom,pcie-sm8350 - items: - const: qcom,pcie-msm8998 @@ -541,33 +540,6 @@ allOf: items: - const: pci # PCIe core reset - - if: - properties: - compatible: - contains: - enum: - - qcom,pcie-sm8150 - then: - properties: - clocks: - minItems: 8 - maxItems: 8 - clock-names: - items: - - const: pipe # PIPE clock - - const: aux # Auxiliary clock - - const: cfg # Configuration clock - - const: bus_master # Master AXI clock - - const: bus_slave # Slave AXI clock - - const: slave_q2a # Slave Q2A clock - - const: tbu # PCIe TBU clock - - const: ref # REFERENCE clock - resets: - maxItems: 1 - reset-names: - items: - - const: pci # PCIe core reset - - if: properties: compatible: @@ -729,7 +701,6 @@ allOf: - qcom,pcie-sc7280 - qcom,pcie-sc8180x - qcom,pcie-sdm845 - - qcom,pcie-sm8150 - qcom,pcie-sm8350 then: oneOf: From patchwork Thu Jan 25 13:03:29 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 766139 Received: from mail-lf1-f46.google.com (mail-lf1-f46.google.com [209.85.167.46]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 68F6655766 for ; Thu, 25 Jan 2024 13:04:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.46 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706187850; cv=none; b=BuxpNiHOFMnbUmxZvnGFsK16d7OazcsjGmW3f8IhISdB4yw/IQuViRJoHLGSTA3GilT2rjFSy1yvYNsdrdplIXFOTH9UnuEzgVvuIaFL42m20Gy+ixZ2vSu4SRvnPnC/hC0Mm1iWiFZLyEcNXzxWyPv4j0ER12Cm+FuuhfQxb5w= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706187850; c=relaxed/simple; bh=Kpi+e1zOQGsMvKNsg7T6zt51ptrCq+dQp4qRk2qgV5Q=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=HNSOQ1Y3D9pvQ/NJV9t8R4IzxKOJzIcM/5C6i2ez2COXklDRgzAtcp7mPkKTgwD6/8V/4zdEOI5MSh3ce84WpM7pB+YeRnuV8SLaOL92RfnVbTkWHXb4q9gU3VTLrc1bp6eoTaWL9SvYL0bhm5QR3fue+EWVXFuowcwKS9+rQhA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=GCtfVplO; arc=none smtp.client-ip=209.85.167.46 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="GCtfVplO" Received: by mail-lf1-f46.google.com with SMTP id 2adb3069b0e04-5101ae8ac40so939632e87.3 for ; Thu, 25 Jan 2024 05:04:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1706187846; x=1706792646; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=0J42QZRyE7hua2zyqMdnH79xAYGxt1x2MM5KxH2NKU8=; b=GCtfVplOUNq3EkRWQ6RddRmOJiRSFmjhHiDUyH6BbN2fHwJ2c28FCg2ZxfBzYIr+Et ekeR7vYehEqbO+d3bMEnZHa5JKhMEf+uUwL3LUqaVvretKqbywsVDoRub5VbTM77Xa9X ECbA5E/anHLrfDL5Pvjo6UK/h5mPlrWXC/7sucZHfYJIUaSZep0uMBJLbkR57J1v5/Vv as2NC/iracTbkQKpPSMwg/HXSD/40pAG2nes/9LeQ9dbbULlgJZFsVp21lwk36xgGWLD MY4K2EUDh9UiXmJQCpmbOhnExlO38g9wAYMcpt6PO+WmCOpTzQ+eSiphYjwmMK4B8OqI NfVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706187846; x=1706792646; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=0J42QZRyE7hua2zyqMdnH79xAYGxt1x2MM5KxH2NKU8=; b=Wj7msjfDtWwQY2ec5pGv/4zuuQC0T+zxY6+RCf2PxEJ1W9e71NSqfKvsgYIgCS+piq +uxIxCfRGnIkApuPfuNuo539RXjt6XkvmfWKz0OInmzWsdjHzAy1Hyes/KgDljzd6adD GO8FZgm7luf81r/Dmn66HSo0GDTVlx8KPh14UU4FGgsLAXL9TL2FNKlaH34zu5AUsFEU QcFiNNvN6x2PnYC7II3VF1KH1p289E9wPdV05fm0Lj2v5Yc2nW/1jc/GRCugzsGMuim9 tAuWlOqTon6HKYTgCQUIVB81pb9adca3bSKcBg6wrFkJEGXzTuvJT8VM+JHacdUcmHyA PpCg== X-Gm-Message-State: AOJu0YwKU3vvWI+3oNdNSxTOaXEND1PjbvrH4eP1MfSj7tRi/QYFlhis gTdXXN15iHvKF1HYoFj+3Fqgft+5MkDQ0gc/MPn2+32InUOA8/Y4uGp3lizbLSs= X-Google-Smtp-Source: AGHT+IFEK6NPEMyvxZ71K+eCJXvDTKHGZxypSdRACG8UN8h5+6DurqFfDerubF8tbcE1Z1s0X0SSkA== X-Received: by 2002:a19:3850:0:b0:50e:71d4:a37f with SMTP id d16-20020a193850000000b0050e71d4a37fmr526746lfj.55.1706187846522; Thu, 25 Jan 2024 05:04:06 -0800 (PST) Received: from [127.0.1.1] ([178.197.215.66]) by smtp.gmail.com with ESMTPSA id tx24-20020a1709078e9800b00a31c5caa750sm294079ejc.177.2024.01.25.05.04.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Jan 2024 05:04:06 -0800 (PST) From: Krzysztof Kozlowski Date: Thu, 25 Jan 2024 14:03:29 +0100 Subject: [PATCH v2 6/6] dt-bindings: PCI: qcom,pcie-sc8280xp: move SC8280XP to dedicated schema Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240125-dt-bindings-pci-qcom-split-v2-6-6b58efd91a7a@linaro.org> References: <20240125-dt-bindings-pci-qcom-split-v2-0-6b58efd91a7a@linaro.org> In-Reply-To: <20240125-dt-bindings-pci-qcom-split-v2-0-6b58efd91a7a@linaro.org> To: Bjorn Andersson , Konrad Dybcio , Lorenzo Pieralisi , =?utf-8?q?Krzysztof_Wilczy?= =?utf-8?q?=C5=84ski?= , Bjorn Helgaas , Krzysztof Kozlowski , Rob Herring , Conor Dooley , Manivannan Sadhasivam Cc: linux-arm-msm@vger.kernel.org, linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Rob Herring , Manivannan Sadhasivam , Krzysztof Kozlowski X-Mailer: b4 0.12.4 X-Developer-Signature: v=1; a=openpgp-sha256; l=9872; i=krzysztof.kozlowski@linaro.org; h=from:subject:message-id; bh=Kpi+e1zOQGsMvKNsg7T6zt51ptrCq+dQp4qRk2qgV5Q=; b=owEBbQKS/ZANAwAKAcE3ZuaGi4PXAcsmYgBlslw2eVZ+DtBTiXEACy/qc/+UWpYBJWibKQEJm duAvC+I+o+JAjMEAAEKAB0WIQTd0mIoPREbIztuuKjBN2bmhouD1wUCZbJcNgAKCRDBN2bmhouD 1+NJD/9rxjKlKpqkhmU1aTe39vSeUGaEQdQGgnGeLINMq+N5r2TmpSSrbUD/Hnbl/JcRFcexNLq 1VW6+WuUQfYWzzAJiqc88T6KI2Dt2KWq1ktcqrH8ZFbSNa+jOW3Lfbw4stNdq3XUZgRhdgKENRv 4vX/oQcErPnNJ0fE5MFVwbPqd/7s5PUbrQibZ8e57bEJ2GNNKU34UfKllJinrVS033NoEKvBRz4 tttOrTq0MNSHCNn1tyUI7iokOCw8jrPjWAl02iEjUSpY7qdYUIxPxLtkNNeA+Bxd0FHfxdfsnvM 4MH3zK9GmPkLE4smTvnYktqQl+hVZ6GN1xr9kxWt5VTxE4mpkg4wqS4UpSBGalnp1EAwkf+evGw d6I7A3n9yf31vkI9Rj86q7v3QZdHsuASf5q/cXwiN/HgLx4snDb6ETtB9XakKv0MA1Gu9aCkh12 7c9dXLJAPIH6aBfMUfaPtNVe4h7bbn6skaQCzOkPGcE3sNejj0Uya8qcOWqRnnntzgfdqkb4HVH dooRKa+KmIWP0zu8BsJS8DgCNNia+/cpRqomGcRDOFkJNlKw90eXdSsPvXjDEq5hQT5DWmjF2hm ZFeXW8WsUHRSqIijP/oP1Ib5QmtkU7I60vEQkotPC+Y0HHsyswyHAGnVugka9kPifliiiz5vN4S tSn/45eG8qfs+WA== X-Developer-Key: i=krzysztof.kozlowski@linaro.org; a=openpgp; fpr=9BD07E0E0C51F8D59677B7541B93437D3B41629B Move SC8280XP compatible PCIe devices from qcom,pcie.yaml binding to a dedicated file to make reviewing easier. This creates equivalent schema file, except missing required compatible which is actually redundant. Reviewed-by: Rob Herring Acked-by: Manivannan Sadhasivam Signed-off-by: Krzysztof Kozlowski --- .../bindings/pci/qcom,pcie-sc8280xp.yaml | 180 +++++++++++++++++++++ .../devicetree/bindings/pci/qcom,pcie.yaml | 54 ------- 2 files changed, 180 insertions(+), 54 deletions(-) diff --git a/Documentation/devicetree/bindings/pci/qcom,pcie-sc8280xp.yaml b/Documentation/devicetree/bindings/pci/qcom,pcie-sc8280xp.yaml new file mode 100644 index 000000000000..25c9f13ae977 --- /dev/null +++ b/Documentation/devicetree/bindings/pci/qcom,pcie-sc8280xp.yaml @@ -0,0 +1,180 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/pci/qcom,pcie-sc8280xp.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Qualcomm SC8280XP PCI Express Root Complex + +maintainers: + - Bjorn Andersson + - Manivannan Sadhasivam + +description: + Qualcomm SC8280XP SoC PCIe root complex controller is based on the Synopsys + DesignWare PCIe IP. + +properties: + compatible: + enum: + - qcom,pcie-sa8540p + - qcom,pcie-sc8280xp + + reg: + minItems: 5 + maxItems: 6 + + reg-names: + minItems: 5 + items: + - const: parf # Qualcomm specific registers + - const: dbi # DesignWare PCIe registers + - const: elbi # External local bus interface registers + - const: atu # ATU address space + - const: config # PCIe configuration space + - const: mhi # MHI registers + + clocks: + minItems: 8 + maxItems: 9 + + clock-names: + minItems: 8 + items: + - const: aux # Auxiliary clock + - const: cfg # Configuration clock + - const: bus_master # Master AXI clock + - const: bus_slave # Slave AXI clock + - const: slave_q2a # Slave Q2A clock + - const: ddrss_sf_tbu # PCIe SF TBU clock + - const: noc_aggr_4 # NoC aggregate 4 clock + - const: noc_aggr_south_sf # NoC aggregate South SF clock + - const: cnoc_qx # Configuration NoC QX clock + + resets: + maxItems: 1 + + reset-names: + items: + - const: pci + + vddpe-3v3-supply: + description: A phandle to the PCIe endpoint power supply + +required: + - interconnects + - interconnect-names + +allOf: + - $ref: qcom,pcie-common.yaml# + - if: + properties: + compatible: + contains: + enum: + - qcom,pcie-sc8280xp + then: + properties: + interrupts: + minItems: 4 + maxItems: 4 + interrupt-names: + items: + - const: msi0 + - const: msi1 + - const: msi2 + - const: msi3 + else: + properties: + interrupts: + maxItems: 1 + interrupt-names: + items: + - const: msi + +unevaluatedProperties: false + +examples: + - | + #include + #include + #include + #include + + soc { + #address-cells = <2>; + #size-cells = <2>; + + pcie@1c20000 { + compatible = "qcom,pcie-sc8280xp"; + reg = <0x0 0x01c20000 0x0 0x3000>, + <0x0 0x3c000000 0x0 0xf1d>, + <0x0 0x3c000f20 0x0 0xa8>, + <0x0 0x3c001000 0x0 0x1000>, + <0x0 0x3c100000 0x0 0x100000>, + <0x0 0x01c23000 0x0 0x1000>; + reg-names = "parf", "dbi", "elbi", "atu", "config", "mhi"; + ranges = <0x01000000 0x0 0x00000000 0x0 0x3c200000 0x0 0x100000>, + <0x02000000 0x0 0x3c300000 0x0 0x3c300000 0x0 0x1d00000>; + + bus-range = <0x00 0xff>; + device_type = "pci"; + linux,pci-domain = <2>; + num-lanes = <4>; + + #address-cells = <3>; + #size-cells = <2>; + + assigned-clocks = <&gcc GCC_PCIE_2A_AUX_CLK>; + assigned-clock-rates = <19200000>; + clocks = <&gcc GCC_PCIE_2A_AUX_CLK>, + <&gcc GCC_PCIE_2A_CFG_AHB_CLK>, + <&gcc GCC_PCIE_2A_MSTR_AXI_CLK>, + <&gcc GCC_PCIE_2A_SLV_AXI_CLK>, + <&gcc GCC_PCIE_2A_SLV_Q2A_AXI_CLK>, + <&gcc GCC_DDRSS_PCIE_SF_TBU_CLK>, + <&gcc GCC_AGGRE_NOC_PCIE_4_AXI_CLK>, + <&gcc GCC_AGGRE_NOC_PCIE_SOUTH_SF_AXI_CLK>; + clock-names = "aux", + "cfg", + "bus_master", + "bus_slave", + "slave_q2a", + "ddrss_sf_tbu", + "noc_aggr_4", + "noc_aggr_south_sf"; + + dma-coherent; + + interrupts = , + , + , + ; + interrupt-names = "msi0", "msi1", "msi2", "msi3"; + #interrupt-cells = <1>; + interrupt-map-mask = <0 0 0 0x7>; + interrupt-map = <0 0 0 1 &intc 0 0 GIC_SPI 530 IRQ_TYPE_LEVEL_HIGH>, + <0 0 0 2 &intc 0 0 GIC_SPI 531 IRQ_TYPE_LEVEL_HIGH>, + <0 0 0 3 &intc 0 0 GIC_SPI 532 IRQ_TYPE_LEVEL_HIGH>, + <0 0 0 4 &intc 0 0 GIC_SPI 533 IRQ_TYPE_LEVEL_HIGH>; + + interconnects = <&aggre2_noc MASTER_PCIE_2A 0 &mc_virt SLAVE_EBI1 0>, + <&gem_noc MASTER_APPSS_PROC 0 &config_noc SLAVE_PCIE_2A 0>; + interconnect-names = "pcie-mem", "cpu-pcie"; + + phys = <&pcie2a_phy>; + phy-names = "pciephy"; + + pinctrl-0 = <&pcie2a_default>; + pinctrl-names = "default"; + + power-domains = <&gcc PCIE_2A_GDSC>; + + resets = <&gcc GCC_PCIE_2A_BCR>; + reset-names = "pci"; + + perst-gpios = <&tlmm 143 GPIO_ACTIVE_LOW>; + wake-gpios = <&tlmm 145 GPIO_ACTIVE_LOW>; + vddpe-3v3-supply = <&vreg_nvme>; + }; + }; diff --git a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml index 6e03a1bce5d4..c8f36978a94c 100644 --- a/Documentation/devicetree/bindings/pci/qcom,pcie.yaml +++ b/Documentation/devicetree/bindings/pci/qcom,pcie.yaml @@ -28,11 +28,9 @@ properties: - qcom,pcie-ipq8074-gen3 - qcom,pcie-msm8996 - qcom,pcie-qcs404 - - qcom,pcie-sa8540p - qcom,pcie-sa8775p - qcom,pcie-sc7280 - qcom,pcie-sc8180x - - qcom,pcie-sc8280xp - qcom,pcie-sdm845 - qcom,pcie-sdx55 - items: @@ -210,7 +208,6 @@ allOf: - qcom,pcie-sa8775p - qcom,pcie-sc7280 - qcom,pcie-sc8180x - - qcom,pcie-sc8280xp - qcom,pcie-sdx55 then: properties: @@ -538,36 +535,6 @@ allOf: items: - const: pci # PCIe core reset - - if: - properties: - compatible: - contains: - enum: - - qcom,pcie-sa8540p - - qcom,pcie-sc8280xp - then: - properties: - clocks: - minItems: 8 - maxItems: 9 - clock-names: - minItems: 8 - items: - - const: aux # Auxiliary clock - - const: cfg # Configuration clock - - const: bus_master # Master AXI clock - - const: bus_slave # Slave AXI clock - - const: slave_q2a # Slave Q2A clock - - const: ddrss_sf_tbu # PCIe SF TBU clock - - const: noc_aggr_4 # NoC aggregate 4 clock - - const: noc_aggr_south_sf # NoC aggregate South SF clock - - const: cnoc_qx # Configuration NoC QX clock - resets: - maxItems: 1 - reset-names: - items: - - const: pci # PCIe core reset - - if: properties: compatible: @@ -623,9 +590,7 @@ allOf: compatible: contains: enum: - - qcom,pcie-sa8540p - qcom,pcie-sa8775p - - qcom,pcie-sc8280xp then: required: - interconnects @@ -692,24 +657,6 @@ allOf: - const: msi6 - const: msi7 - - if: - properties: - compatible: - contains: - enum: - - qcom,pcie-sc8280xp - then: - properties: - interrupts: - minItems: 4 - maxItems: 4 - interrupt-names: - items: - - const: msi0 - - const: msi1 - - const: msi2 - - const: msi3 - - if: properties: compatible: @@ -724,7 +671,6 @@ allOf: - qcom,pcie-ipq8074 - qcom,pcie-ipq8074-gen3 - qcom,pcie-qcs404 - - qcom,pcie-sa8540p then: properties: interrupts: