From patchwork Mon Mar 18 10:09:45 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 13595184 Received: from mail-wm1-f44.google.com (mail-wm1-f44.google.com [209.85.128.44]) (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 AEC912E83F for ; Mon, 18 Mar 2024 10:09:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.44 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710756593; cv=none; b=Rejx89MNpPt+o4fRNdVaiV2wmRz3vH7rl4ZFHjCBzMlX9AfLypINh4movaxuiIFyt3kUC9mSOGH6Kxa7j2XaRYBGx7EsIFJ5iuDTkA8VziBfpfckMx3yhjS0t+28AGFaDMrmUub54OiQLTggm+Orx25pkOK29vQIFsDhdDe1/Os= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710756593; c=relaxed/simple; bh=NHUBJ3C6TZTrEVk6MIERemImihySUvN3VXYQqv+Am2w=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=jBl5lIjdvgzH2Zn7X2uFdv386CE02xf/CxA/Ew+kjEf2Rg20CljXn9W/gtOha/u7R6K4Gyt252Q93bPH/P5lBl0fEPNJJp5nEiLn6mZHdFqfl+8Bxa6ob4r8w79MxfpE3W7XDWw0VnSVj4i45KEj4qeOWqYVNd3Bu+S8Ji6QvhU= 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=YKy+d+j5; arc=none smtp.client-ip=209.85.128.44 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="YKy+d+j5" Received: by mail-wm1-f44.google.com with SMTP id 5b1f17b1804b1-4141156f245so3979765e9.2 for ; Mon, 18 Mar 2024 03:09:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1710756590; x=1711361390; 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=aMqC9Qpno0KSr5BatsAEOI7fBV8AlIgGQxaQajD859c=; b=YKy+d+j55qflXnM0S8l5GdBXHhOS94wS+VR91E2Jq3UV6zwMU2AK/WhJeoSMrKA7Wz XcwW3HcS79QcF3WyIWIB3apOTxyxtkjONpk3HhiHPqjNzzL46XCQtoHgCYcUdTWoZVPp fStuJ4Luif+ygZom51r6hYA/fkSH4vx3amBaysH0x1gUUQRkGLk+atocaheytaKUHpqS EsS943O+gS0BHTQjPcvtVRAOI2SWecP1OsBS8qodqk+Zci50ln080VePCNug8EG+glO3 lR8rpT7Q/j0h19jLNoFnCvOI4HLjEbfOseA4dLdXqqLSJazdTFO+89J95BoFXlO25mK5 MuQw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1710756590; x=1711361390; 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=aMqC9Qpno0KSr5BatsAEOI7fBV8AlIgGQxaQajD859c=; b=h/E30loaS2Gcx/ZbuCRXTl+hz0gVe0tW1fsUrqMyoaHcQBJ6+kaXxHqUP/aUsJJLxC YOoB9fSGkG9KFEqX7Tmk4IVn8j6dV3EbqsVMd6OPEyem4iklWt80CdlPP94ddt6WHgvK buGNpLjXaUa6D9eYFtV449R315rtJXxJJ0+ZXUMOVTMyuxpE2i1vn+VWapd8cEcRDRJN 9qhLCUO90U32XhkyUkVVkB0jRbC/zowSuz+Vw5Vwb79YQs+w8Phr48PnzKFBCjGRlNvd A2Qm0puZeYQ/hVdiUmuEhguBPf0zi9uh3LXvf7mSB4ZMZdbw6pO6Ryka1KOkBuDUJY2S SObw== X-Gm-Message-State: AOJu0YzgMdEqhUn4LG+Na2l5z9+3OxWnWk1uc6untSibPF0Hrgv575te LCHqEydOH5S38qXQQ0qRE1t6QPQh8jHIPN1j6X5fgM3YJ2anBT06a6iKPf0ieTGzuQ02QqHizdY zDc0= X-Google-Smtp-Source: AGHT+IFPilx0RIzigUSas2wp+HZomIIDYFY/HSTVARt1ijpdHFRLg8nhL/HqfJTPXB+HZiEOggXsdA== X-Received: by 2002:a05:600c:4f8a:b0:414:239:40cc with SMTP id n10-20020a05600c4f8a00b00414023940ccmr6668887wmq.12.1710756590085; Mon, 18 Mar 2024 03:09:50 -0700 (PDT) Received: from arrakeen.starnux.net ([2a01:e0a:982:cbb0:8261:5fff:fe11:bdda]) by smtp.gmail.com with ESMTPSA id u8-20020a5d4688000000b0033e3c4e600asm9533734wrq.7.2024.03.18.03.09.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Mar 2024 03:09:49 -0700 (PDT) From: Neil Armstrong Date: Mon, 18 Mar 2024 11:09:45 +0100 Subject: [PATCH v4 1/2] arm64: dts: qcom: sm8650: add GPU nodes Precedence: bulk X-Mailing-List: linux-arm-msm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240318-topic-sm8650-gpu-v4-1-206eb0d31694@linaro.org> References: <20240318-topic-sm8650-gpu-v4-0-206eb0d31694@linaro.org> In-Reply-To: <20240318-topic-sm8650-gpu-v4-0-206eb0d31694@linaro.org> To: Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Neil Armstrong X-Mailer: b4 0.12.4 X-Developer-Signature: v=1; a=openpgp-sha256; l=6093; i=neil.armstrong@linaro.org; h=from:subject:message-id; bh=NHUBJ3C6TZTrEVk6MIERemImihySUvN3VXYQqv+Am2w=; b=owEBbQKS/ZANAwAKAXfc29rIyEnRAcsmYgBl+BLrVd7jnoT/LAxO7dXAC92pmy6jUQ4xo1jQii6N TUQbQfqJAjMEAAEKAB0WIQQ9U8YmyFYF/h30LIt33NvayMhJ0QUCZfgS6wAKCRB33NvayMhJ0WTdD/ 4/IU9zp8j6JL+q1JvMZSESSsKSv/tNtZzH58ZnbxeQWqrI8/0/TGbeNk0ceuAPC+WLnhXZS3DKiU3x uuKNSV5ywgqnMfo3+PCj0E53w1HaoW3drRekEPyedUk14O/SM/9x6wgi4jtxMXpgfJfow1W2reKEp+ 10CkfEgLycxHasVAIDTVMvtt/KlE5H2WkpOmq9B/9gAqWi1A/D67hOq+23zq10Wi9HjzQubQsfsYyF l/V8fcsl0YjF/vRuFNO4pC2ggBliLdY0mdb3AqKVHl4gdISifmdxuzVfqPvBKc05GL61STP6i5O3QE GbpI3onuuJBO5uZUpv7mkoBpb+a8QtEGYXZfKYSwMHyGkPmrBLMYejy2Rb/1xw0jMIWu9/ZWKx30S6 pWAA0ZYaNmqtDwqNVagCw8pCvoiGql/3qaaMFiaro8r7u8UsbipSgP0AFbGk7mSp8GBsHpWUyrpuv1 7JBHNIe1ez3JQgPeIZ+xoMA94HtnJNMP/cfeR8oupdvzautinqzoI4LIKDiD9t1SLDE9mQ21JPADSN lUyCNu1B+UPe8RlIZJkQmejFRF78mdQnNL+Ab0m3jMdVnMH5C0NQYI/f7hD14CEuQTttZgoawc0BDe GRVx0+Q79towmPsvxI4Rx+m9+uc44YMPOEyGQgj6m8iEuOyxsQJxBQhUtOaQ== X-Developer-Key: i=neil.armstrong@linaro.org; a=openpgp; fpr=89EC3D058446217450F22848169AB7B1A4CFF8AE Add GPU nodes for the SM8650 platform. Signed-off-by: Neil Armstrong Reviewed-by: Konrad Dybcio Acked-by: Jun Nie --- arch/arm64/boot/dts/qcom/sm8650.dtsi | 181 +++++++++++++++++++++++++++++++++++ 1 file changed, 181 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sm8650.dtsi b/arch/arm64/boot/dts/qcom/sm8650.dtsi index ba72d8f38420..99aa15c7c074 100644 --- a/arch/arm64/boot/dts/qcom/sm8650.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8650.dtsi @@ -2591,6 +2591,143 @@ tcsr: clock-controller@1fc0000 { #reset-cells = <1>; }; + gpu: gpu@3d00000 { + compatible = "qcom,adreno-43051401", "qcom,adreno"; + reg = <0x0 0x03d00000 0x0 0x40000>, + <0x0 0x03d9e000 0x0 0x1000>, + <0x0 0x03d61000 0x0 0x800>; + reg-names = "kgsl_3d0_reg_memory", + "cx_mem", + "cx_dbgc"; + + interrupts = ; + + iommus = <&adreno_smmu 0 0x0>, + <&adreno_smmu 1 0x0>; + + operating-points-v2 = <&gpu_opp_table>; + + qcom,gmu = <&gmu>; + + status = "disabled"; + + zap-shader { + memory-region = <&gpu_micro_code_mem>; + }; + + /* Speedbin needs more work on A740+, keep only lower freqs */ + gpu_opp_table: opp-table { + compatible = "operating-points-v2"; + + opp-231000000 { + opp-hz = /bits/ 64 <231000000>; + opp-level = ; + }; + + opp-310000000 { + opp-hz = /bits/ 64 <310000000>; + opp-level = ; + }; + + opp-366000000 { + opp-hz = /bits/ 64 <366000000>; + opp-level = ; + }; + + opp-422000000 { + opp-hz = /bits/ 64 <422000000>; + opp-level = ; + }; + + opp-500000000 { + opp-hz = /bits/ 64 <500000000>; + opp-level = ; + }; + + opp-578000000 { + opp-hz = /bits/ 64 <578000000>; + opp-level = ; + }; + + opp-629000000 { + opp-hz = /bits/ 64 <629000000>; + opp-level = ; + }; + + opp-680000000 { + opp-hz = /bits/ 64 <680000000>; + opp-level = ; + }; + + opp-720000000 { + opp-hz = /bits/ 64 <720000000>; + opp-level = ; + }; + + opp-770000000 { + opp-hz = /bits/ 64 <770000000>; + opp-level = ; + }; + + opp-834000000 { + opp-hz = /bits/ 64 <834000000>; + opp-level = ; + }; + }; + }; + + gmu: gmu@3d6a000 { + compatible = "qcom,adreno-gmu-750.1", "qcom,adreno-gmu"; + reg = <0x0 0x03d6a000 0x0 0x35000>, + <0x0 0x03d50000 0x0 0x10000>, + <0x0 0x0b280000 0x0 0x10000>; + reg-names = "gmu", "rscc", "gmu_pdc"; + + interrupts = , + ; + interrupt-names = "hfi", "gmu"; + + clocks = <&gpucc GPU_CC_AHB_CLK>, + <&gpucc GPU_CC_CX_GMU_CLK>, + <&gpucc GPU_CC_CXO_CLK>, + <&gcc GCC_DDRSS_GPU_AXI_CLK>, + <&gcc GCC_GPU_MEMNOC_GFX_CLK>, + <&gpucc GPU_CC_HUB_CX_INT_CLK>, + <&gpucc GPU_CC_DEMET_CLK>; + clock-names = "ahb", + "gmu", + "cxo", + "axi", + "memnoc", + "hub", + "demet"; + + power-domains = <&gpucc GPU_CX_GDSC>, + <&gpucc GPU_GX_GDSC>; + power-domain-names = "cx", + "gx"; + + iommus = <&adreno_smmu 5 0x0>; + + qcom,qmp = <&aoss_qmp>; + + operating-points-v2 = <&gmu_opp_table>; + + gmu_opp_table: opp-table { + compatible = "operating-points-v2"; + + opp-260000000 { + opp-hz = /bits/ 64 <260000000>; + opp-level = ; + }; + + opp-625000000 { + opp-hz = /bits/ 64 <625000000>; + opp-level = ; + }; + }; + }; + gpucc: clock-controller@3d90000 { compatible = "qcom,sm8650-gpucc"; reg = <0 0x03d90000 0 0xa000>; @@ -2604,6 +2741,50 @@ gpucc: clock-controller@3d90000 { #power-domain-cells = <1>; }; + adreno_smmu: iommu@3da0000 { + compatible = "qcom,sm8650-smmu-500", "qcom,adreno-smmu", + "qcom,smmu-500", "arm,mmu-500"; + reg = <0x0 0x03da0000 0x0 0x40000>; + #iommu-cells = <2>; + #global-interrupts = <1>; + interrupts = , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + , + ; + clocks = <&gpucc GPU_CC_HLOS1_VOTE_GPU_SMMU_CLK>, + <&gcc GCC_GPU_MEMNOC_GFX_CLK>, + <&gcc GCC_GPU_SNOC_DVM_GFX_CLK>, + <&gpucc GPU_CC_AHB_CLK>; + clock-names = "hlos", + "bus", + "iface", + "ahb"; + power-domains = <&gpucc GPU_CX_GDSC>; + dma-coherent; + }; + ipa: ipa@3f40000 { compatible = "qcom,sm8650-ipa", "qcom,sm8550-ipa";