From patchwork Tue Jan 29 23:20:01 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 157014 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp5253656jaa; Tue, 29 Jan 2019 15:20:37 -0800 (PST) X-Google-Smtp-Source: ALg8bN567xOE5hLwUm/o2omGm6C0C5Kq5HXMIRMPgx3aefZ02Djhpv57L1VkCTnEqq/qAk/LXUrI X-Received: by 2002:aa7:85d7:: with SMTP id z23mr29145682pfn.205.1548804037883; Tue, 29 Jan 2019 15:20:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548804037; cv=none; d=google.com; s=arc-20160816; b=YPTHGQlbGAZGawrEdSikEz/3lDWgcX9eAMZqJWHB3I8Xar9+moeLffIMRMj7z8xGU9 xt7FnFG+t8Mgx2Vce8me5d2lK7+gRMUOkToDmlCCG2gbf2pIrKO+3p3LUylMcJ/N49Rw Y4VbPOxjj0uCzxf0IJGvjQTrmz0gEGIzlaCLIziLvn5ONsMk52NCwBczGQMVCnW1A9/F CUG7iTmdwofVqWeaj9E9xhgF1N/jogrU2L9f9lrxPZn49qi+PKdCkf5gywGO//M8awx2 KRoAtK7mdbGeJDYVCW//FuQ4eJDD671kEnhaM/22dqlb07B9dm71pSkPQLbCVF3iKosO wxxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=IK7vUmkScfb4GTJa0Qmfj4ukRpGnUehE4KZAK/2fFS4=; b=mVD0nLb3JFF/jyLcdphOIXkqHMOkvxULRMOW0jhQuLTaWHSoVyVm+xQH728GSINpjt 3p1roNFWtwYptcbrRcyMts+3piKgkyPau8ncohM2T2tQhM8WsrHa/7lb85h0mb7X2Z2L eYvNliMTCeISdZffMEqp5PJVzw8mQpS1E0VONb/NfkMzDgJozET0pQuN1jGUFFmvsWIV TcjLz0LLDEojMqlZ4hxyTOjAQvx1vY0C8VLMnA2WOeVWbIrUeeB9788KemvVlvwPXv+h pxl0WiIr7p9GP07D94fi+bXFyCsOKG3JJL/qlT83G2NxI90OhKwuMguSjM+kwqT7tOuI OH5Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dDhlpiEk; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r4si36073273pgi.387.2019.01.29.15.20.37; Tue, 29 Jan 2019 15:20:37 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dDhlpiEk; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729840AbfA2XUc (ORCPT + 7 others); Tue, 29 Jan 2019 18:20:32 -0500 Received: from mail-pg1-f193.google.com ([209.85.215.193]:39837 "EHLO mail-pg1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729808AbfA2XUc (ORCPT ); Tue, 29 Jan 2019 18:20:32 -0500 Received: by mail-pg1-f193.google.com with SMTP id w6so9443803pgl.6 for ; Tue, 29 Jan 2019 15:20:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=IK7vUmkScfb4GTJa0Qmfj4ukRpGnUehE4KZAK/2fFS4=; b=dDhlpiEkrSzRnfbSHSUP0+EJQW45ZCPu1KXn2BnUS3nrGqo59qeABKPkEBFCYjqFin BzlSl+hE+eVbJU75mvAio07ggS949ygNqH18nHK5sQWhAX1JYdwb/fIJ33lqe6Fsd8lh /mhmWPqWQMVxzL8ICkZ3gD/yBeT4c5p2hDMTs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=IK7vUmkScfb4GTJa0Qmfj4ukRpGnUehE4KZAK/2fFS4=; b=hSSWJ7xDE07fFIvzbkFurH6uIB810ikJU2rFN8FYo/cm3BEsVd8ADf0oKb8NMGdr1L s4Wi+U4nTTdjTjEGFrUJ4/DHa+2FCCTWNTCE9vsU7V/+wIJBYWcS/W7kLuhj/MkApHmJ NBI8O35t353z0Hi9jz6JvFwGa50w6pbvJoD/k1rciAvqg1Dq7lXN+4YMKTzidm99wFBF 0kUq0N6Lv/SC/sESHcuFhmux4faTOVfdS8q9PS7c2AQwv2Pr6KZhZS0y9ycsVLuvQKyB Yr2hBWlZnpb6liAv1cQWVMZjuEOfKv/MdvIUP6wdqN1DMrLraoNQUz1SBozl9CWZCCYh 5k9Q== X-Gm-Message-State: AJcUukd5chBElMqCD4xdlfe07HWwkn59zopei01glwEBxPC0qkrIEW93 yWW8JBsbAzu4viVmptQLGadWWA== X-Received: by 2002:a63:f811:: with SMTP id n17mr26001195pgh.23.1548804031009; Tue, 29 Jan 2019 15:20:31 -0800 (PST) Received: from localhost.localdomain (104-188-17-28.lightspeed.sndgca.sbcglobal.net. [104.188.17.28]) by smtp.gmail.com with ESMTPSA id v70sm51182779pfa.152.2019.01.29.15.20.29 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 29 Jan 2019 15:20:30 -0800 (PST) From: Bjorn Andersson To: Andy Gross , David Brown Cc: Rob Herring , Mark Rutland , Ohad Ben-Cohen , Arun Kumar Neelakantam , Sibi Sankar , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-remoteproc@vger.kernel.org Subject: [PATCH v4 02/10] arm64: dts: qcom: sdm845: Define rmtfs memory Date: Tue, 29 Jan 2019 15:20:01 -0800 Message-Id: <20190129232009.5033-3-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20190129232009.5033-1-bjorn.andersson@linaro.org> References: <20190129232009.5033-1-bjorn.andersson@linaro.org> Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Define the rmtfs memory node, as described in version 10 of the memory map. Signed-off-by: Bjorn Andersson --- Changes since v3: - Labeled the node arch/arm64/boot/dts/qcom/sdm845.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+) -- 2.18.0 diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi index c363848e9001..afaffcc1e835 100644 --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi @@ -78,6 +78,15 @@ no-map; }; + mpss_efs: memory@85d00000 { + compatible = "qcom,rmtfs-mem"; + reg = <0 0x85d00000 0 0x200000>; + no-map; + + qcom,client-id = <1>; + qcom,vmid = <15>; + }; + xbl_mem: memory@85e00000 { reg = <0x0 0x85e00000 0 0x100000>; no-map; From patchwork Tue Jan 29 23:20:02 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 157013 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp5253602jaa; Tue, 29 Jan 2019 15:20:34 -0800 (PST) X-Google-Smtp-Source: ALg8bN4oSGD4PCbLWhsi1gtHy4yhL/xO6VzfJAkxydg00qIf7HZHVyOJTiOsctBkgTpZQRIjOY0C X-Received: by 2002:a17:902:b48b:: with SMTP id y11mr26889748plr.200.1548804034826; Tue, 29 Jan 2019 15:20:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548804034; cv=none; d=google.com; s=arc-20160816; b=hFkKOuMg6iFYhYIhegS2C7jdyCeFeNuKpIiqmskw0pHpo8l8/PFYIuT5MGp8RgBvcL 1lkBI9cE45oUUc0h2g/QkTwTqYlhaIO02c3WS1bjsgoFYiIJbAmUQEYR0b92E9RDscNe JgLN5ERKpEbXwgBx738XWro1ZeRhg3/NnrUNxo7oTtLSkKxxuCHNd7OdKRDDtmI1Hxm7 iD6tcBPPVmuVDqGaBWh8m/nBDybcdgJyEaqDO0gk9X7NGwKH+pyZTpuB51hD0TnSCZoe k+MYfb90PGMC/jMSuw5dxXUsiTZtLXHYt/SeYZ3EozoyXj0T80DOu7BX8Tg7JC/+t0bi B2Lg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=NRbN8HgsLKUpGZTnSmCBsWLR6zauooE33ibyj+b+r7o=; b=FYP0nXyqAVSCOjoFPo/Y2DV7pP2RORHpT+ElJbtCaJUB5qjETq0tY9edQHnpVYsRqW Davw/XfQZ9GEqcqWfUdeCgTaco4wEmEEcO+7XxBCdcZ4lC0Ew+1M49CqUgxrSi2vfG63 EL7K7S0DoiuL03IS/wBMzmNWb9qFprhkFFPApPz4AvzI7CNtmzWAA8fMxWzHJAdVTYJX JoTn7nTpCX8q+FmYuJAVGy1pBLsOfMewH1Z087wGl9x2po7x7fuZW4E0mu6kifmhBv0P kbOoRyetWakrjaZ3Th9XoDJxIj7sjWu7i++WWgoCRFcsXC81UVljQ5T1QiQ2W7TOGEBI plYA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=KNaeMfbY; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r4si36073273pgi.387.2019.01.29.15.20.34; Tue, 29 Jan 2019 15:20:34 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=KNaeMfbY; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727783AbfA2XUd (ORCPT + 7 others); Tue, 29 Jan 2019 18:20:33 -0500 Received: from mail-pl1-f196.google.com ([209.85.214.196]:41787 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729846AbfA2XUd (ORCPT ); Tue, 29 Jan 2019 18:20:33 -0500 Received: by mail-pl1-f196.google.com with SMTP id u6so10096525plm.8 for ; Tue, 29 Jan 2019 15:20:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=NRbN8HgsLKUpGZTnSmCBsWLR6zauooE33ibyj+b+r7o=; b=KNaeMfbYBnuDZIDwXP5HLmL9z8tblTbyacx3M2ClFJQkm4xAtoDdZfpLtoKAEfcrNF 06fZ/Mi/Oz4ZCgo1LQw5ijhFEp4gnqhBo7uddJ7yq/YCAB+kI9kGFCtV49pX/iPWYtaq 04PV32G78JQLrgBTKiNAx3wiGVrpwSNlL+Dhk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=NRbN8HgsLKUpGZTnSmCBsWLR6zauooE33ibyj+b+r7o=; b=PBWK8U97euBQ4oktJVxDVpMTNrGYrMbwMWY2qhqWkBZkZqvoukWkLHpKTY5sM7zPax +Jj9V2oVz5algmzxbSihfeTxwRfur9jRoA+i5lU5s3ZdJgqUuDmnM1WyK/xIvhLAVu+C 88zNvO3N86My/Xv1i9mzzlPG3rUHMqCbX+g5RdzVS0ZGGdd+IE8y0BYoRk5fjZ7TsC8A IvzB0Sd9YWTGbS+jCoghcoB97BwFjHzWX2094cPg90eyEMg5x3vfqzhLv8MBwm9G86BJ NpBXMmgurWUc5isg6jvP7ATUTjlqUiUBX9COGNnHyNTkAgzBI9oPC3j18kPszBhhDWTP 57Kw== X-Gm-Message-State: AJcUukfDvy39A+Yjb3kxN3dKhU74YBI8VTyAcm3uThMJ5rghABWW3Gu2 X5ylRcM6Mn28DIwDcrPAn9Ggs875SFs= X-Received: by 2002:a17:902:714c:: with SMTP id u12mr27661196plm.234.1548804032511; Tue, 29 Jan 2019 15:20:32 -0800 (PST) Received: from localhost.localdomain (104-188-17-28.lightspeed.sndgca.sbcglobal.net. [104.188.17.28]) by smtp.gmail.com with ESMTPSA id v70sm51182779pfa.152.2019.01.29.15.20.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 29 Jan 2019 15:20:31 -0800 (PST) From: Bjorn Andersson To: Andy Gross , David Brown Cc: Rob Herring , Mark Rutland , Ohad Ben-Cohen , Arun Kumar Neelakantam , Sibi Sankar , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-remoteproc@vger.kernel.org Subject: [PATCH v4 03/10] arm64: dts: sdm845: Introduce ADSP and CDSP PAS nodes Date: Tue, 29 Jan 2019 15:20:02 -0800 Message-Id: <20190129232009.5033-4-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20190129232009.5033-1-bjorn.andersson@linaro.org> References: <20190129232009.5033-1-bjorn.andersson@linaro.org> Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Add the Audio DSP (ADSP) and Compute DSP (CDSP) nodes for TrustZone based remoteproc, supporting booting these cores on e.g. the MTP, and enable the same for the MTP. Signed-off-by: Bjorn Andersson --- Changes since v3: - Make xo reference the actual CXO clock arch/arm64/boot/dts/qcom/sdm845-mtp.dts | 8 ++++ arch/arm64/boot/dts/qcom/sdm845.dtsi | 58 +++++++++++++++++++++++++ 2 files changed, 66 insertions(+) -- 2.18.0 diff --git a/arch/arm64/boot/dts/qcom/sdm845-mtp.dts b/arch/arm64/boot/dts/qcom/sdm845-mtp.dts index af8c6a2445a2..02b8357c8ce8 100644 --- a/arch/arm64/boot/dts/qcom/sdm845-mtp.dts +++ b/arch/arm64/boot/dts/qcom/sdm845-mtp.dts @@ -48,6 +48,10 @@ }; }; +&adsp_pas { + status = "okay"; +}; + &apps_rsc { pm8998-rpmh-regulators { compatible = "qcom,pm8998-rpmh-regulators"; @@ -344,6 +348,10 @@ }; }; +&cdsp_pas { + status = "okay"; +}; + &gcc { protected-clocks = , , diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi index afaffcc1e835..d193f85e5835 100644 --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi @@ -330,6 +330,64 @@ }; }; + adsp_pas: remoteproc-adsp { + compatible = "qcom,sdm845-adsp-pas"; + + interrupts-extended = <&intc GIC_SPI 162 IRQ_TYPE_EDGE_RISING>, + <&adsp_smp2p_in 0 IRQ_TYPE_EDGE_RISING>, + <&adsp_smp2p_in 1 IRQ_TYPE_EDGE_RISING>, + <&adsp_smp2p_in 2 IRQ_TYPE_EDGE_RISING>, + <&adsp_smp2p_in 3 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "wdog", "fatal", "ready", + "handover", "stop-ack"; + + clocks = <&rpmhcc RPMH_CXO_CLK>; + clock-names = "xo"; + + memory-region = <&adsp_mem>; + + qcom,smem-states = <&adsp_smp2p_out 0>; + qcom,smem-state-names = "stop"; + + status = "disabled"; + + glink-edge { + interrupts = ; + label = "lpass"; + qcom,remote-pid = <2>; + mboxes = <&apss_shared 8>; + }; + }; + + cdsp_pas: remoteproc-cdsp { + compatible = "qcom,sdm845-cdsp-pas"; + + interrupts-extended = <&intc GIC_SPI 578 IRQ_TYPE_EDGE_RISING>, + <&cdsp_smp2p_in 0 IRQ_TYPE_EDGE_RISING>, + <&cdsp_smp2p_in 1 IRQ_TYPE_EDGE_RISING>, + <&cdsp_smp2p_in 2 IRQ_TYPE_EDGE_RISING>, + <&cdsp_smp2p_in 3 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "wdog", "fatal", "ready", + "handover", "stop-ack"; + + clocks = <&rpmhcc RPMH_CXO_CLK>; + clock-names = "xo"; + + memory-region = <&cdsp_mem>; + + qcom,smem-states = <&cdsp_smp2p_out 0>; + qcom,smem-state-names = "stop"; + + status = "disabled"; + + glink-edge { + interrupts = ; + label = "turing"; + qcom,remote-pid = <5>; + mboxes = <&apss_shared 4>; + }; + }; + tcsr_mutex: hwlock { compatible = "qcom,tcsr-mutex"; syscon = <&tcsr_mutex_regs 0 0x1000>; From patchwork Tue Jan 29 23:20:07 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 157017 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp5253736jaa; Tue, 29 Jan 2019 15:20:43 -0800 (PST) X-Google-Smtp-Source: ALg8bN6xg5fDDrMHSse9ly9XJJ+qPG3b0hyz9xdk8Y6ien+w6TKC38s1zkg7P2ikwLI/Z7671+gF X-Received: by 2002:a17:902:4601:: with SMTP id o1mr27995774pld.243.1548804043009; Tue, 29 Jan 2019 15:20:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548804043; cv=none; d=google.com; s=arc-20160816; b=R5Re42GeiumxlFW2Bu4WmddG4uFYionZ3yllEYMqz2oL9/RAgMIm+zMF76CyPTXeq6 ZwRATpG3o1jvLA94m4PMDxAfuByHGX+bWU81axIvGAe1BcO7u0DuFts0fylTumAtp7df RlJI1TlFaYRWJRy83HFyYnmiXYQ5O94K+zJfLb9F/siomhSZG7Br1SUhAjA2SeaSA+fF kOg0pQvPe/H5h2xi9h2hM6rd9orMamLiAcIkhrdhg5Y5LLy0EZ7paH/Qa4buEP4LW+ZQ zQ5QvMHtpa681pL+d8UeKnPpAhUomorXm4VcvKX/RAAjG/zmBXLfoZKXD785fZqxxaxJ pYXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=+VB4lYf9DNI0f5oxIEKDuBpa7GNxZTlTEpIziZQr2lk=; b=ta3s+W6QR9JC5/UZC8xT90t4ybppsWS6rT5k3WIH1c8sq5ioX6+9LzUbRWGJfzV/Iv PQMLRgx0NXB5gDDEzThRSIu8hwF5n0bMk5raNyCeuj12rvKAIuiwMQHI9x4CmjaAk5q9 w3LPLHgI9F0MYx9MeF3ddGt7hAKEgq4WoV/GZ4i94qLW3CsuuiRW22/ILaYYhToWby2l 8kF2oAjv65AlIbGQTcw3ovgEbIn6txPc+R5MWTt216kUaT/MqFvOfDSXytEqO7xZDpff CY3aT4dg0YnNOxfSQ/nlNtaxoWU5Q43zCDzuG3laDuQXMRlD+Sr/+TPY9uPGwjJk3+bA h1UA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=FK7a1zOH; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m39si37433692plg.315.2019.01.29.15.20.42; Tue, 29 Jan 2019 15:20:43 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=FK7a1zOH; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729959AbfA2XUl (ORCPT + 7 others); Tue, 29 Jan 2019 18:20:41 -0500 Received: from mail-pf1-f193.google.com ([209.85.210.193]:45051 "EHLO mail-pf1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729954AbfA2XUk (ORCPT ); Tue, 29 Jan 2019 18:20:40 -0500 Received: by mail-pf1-f193.google.com with SMTP id u6so10412157pfh.11 for ; Tue, 29 Jan 2019 15:20:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=+VB4lYf9DNI0f5oxIEKDuBpa7GNxZTlTEpIziZQr2lk=; b=FK7a1zOH+uDiPanqJJPgFQlERDW5djLwpFLeN7Z2c1/2lJ/xPoSynfnEbwPnHTlDvk IqVKTreSXLXARjzAQntWrAqb932VVEj4lJP9L9+oNTcVHo3vMhb7nweJrlTbJrEXvOZb gq0BbHPcby5ijOA8fxpYJhQmjiVteLp41lz7c= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=+VB4lYf9DNI0f5oxIEKDuBpa7GNxZTlTEpIziZQr2lk=; b=DW8hQbjq3V/o1EHHF2rjI5CoUXd9csrDdWMAahNO1D0Qx4AE6Zu3u5BjaSkVMhJFzc SY2rdrWsWlDxiJUU4mEKQCcD2JElSyJ4K4KwpOa92EoJacHxtnTTmehLUn52c0SMTU/h wbKI9YP2hOZcgRu8p458nCTR7HvMzaqO9k7Y9TvArcOStnOns9qRDXJ9lLLxv60n009l Oi+S1mAfS45Tl2hyLyKuGCxahhgykD7fkZ9FBWLn2qAMCkhPzJAsgKSKSAgOhGtY5o0m wOLRcxFuQvpeNvIRaTfok181C9piIhbgcJcRg7G4BkmdSzwNg7jPXiSt+pOYAzwfTTZ1 RAEw== X-Gm-Message-State: AJcUukchX0POt4n3U9gfsqFMK5el0vWeZH7Foeyjv3SKvnS/YsFfvIJt J8UfWgu2ajeIjUr2GxFk/SNQrJvUlnY= X-Received: by 2002:a63:111c:: with SMTP id g28mr25113118pgl.85.1548804039696; Tue, 29 Jan 2019 15:20:39 -0800 (PST) Received: from localhost.localdomain (104-188-17-28.lightspeed.sndgca.sbcglobal.net. [104.188.17.28]) by smtp.gmail.com with ESMTPSA id v70sm51182779pfa.152.2019.01.29.15.20.38 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 29 Jan 2019 15:20:38 -0800 (PST) From: Bjorn Andersson To: Ohad Ben-Cohen , Bjorn Andersson Cc: Andy Gross , David Brown , Rob Herring , Mark Rutland , Arun Kumar Neelakantam , Sibi Sankar , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-remoteproc@vger.kernel.org Subject: [PATCH v4 08/10] remoteproc: q6v5-mss: Active powerdomain for SDM845 Date: Tue, 29 Jan 2019 15:20:07 -0800 Message-Id: <20190129232009.5033-9-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20190129232009.5033-1-bjorn.andersson@linaro.org> References: <20190129232009.5033-1-bjorn.andersson@linaro.org> Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org The SDM845 MSS needs the load_state powerdomain voted for during the duration of the MSS being powered on, to let the AOSS know that it may not perform certain power save measures. So vote for this. Tested-by: Sibi Sankar Reviewed-by: Sibi Sankar Signed-off-by: Bjorn Andersson --- Changes since v3: - None drivers/remoteproc/qcom_q6v5_mss.c | 31 ++++++++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) -- 2.18.0 diff --git a/drivers/remoteproc/qcom_q6v5_mss.c b/drivers/remoteproc/qcom_q6v5_mss.c index c32c63e351a0..e30f5486fd20 100644 --- a/drivers/remoteproc/qcom_q6v5_mss.c +++ b/drivers/remoteproc/qcom_q6v5_mss.c @@ -133,6 +133,7 @@ struct rproc_hexagon_res { char **proxy_clk_names; char **reset_clk_names; char **active_clk_names; + char **active_pd_names; char **proxy_pd_names; int version; bool need_mem_protection; @@ -159,10 +160,12 @@ struct q6v5 { struct clk *active_clks[8]; struct clk *reset_clks[4]; struct clk *proxy_clks[4]; + struct device *active_pds[1]; struct device *proxy_pds[3]; int active_clk_count; int reset_clk_count; int proxy_clk_count; + int active_pd_count; int proxy_pd_count; struct reg_info active_regs[1]; @@ -730,10 +733,16 @@ static int q6v5_mba_load(struct q6v5 *qproc) qcom_q6v5_prepare(&qproc->q6v5); + ret = q6v5_pds_enable(qproc, qproc->active_pds, qproc->active_pd_count); + if (ret < 0) { + dev_err(qproc->dev, "failed to enable active power domains\n"); + goto disable_irqs; + } + ret = q6v5_pds_enable(qproc, qproc->proxy_pds, qproc->proxy_pd_count); if (ret < 0) { dev_err(qproc->dev, "failed to enable proxy power domains\n"); - goto disable_irqs; + goto disable_active_pds; } ret = q6v5_regulator_enable(qproc, qproc->proxy_regs, @@ -839,6 +848,8 @@ static int q6v5_mba_load(struct q6v5 *qproc) qproc->proxy_reg_count); disable_proxy_pds: q6v5_pds_disable(qproc, qproc->proxy_pds, qproc->proxy_pd_count); +disable_active_pds: + q6v5_pds_disable(qproc, qproc->active_pds, qproc->active_pd_count); disable_irqs: qcom_q6v5_unprepare(&qproc->q6v5); @@ -878,6 +889,7 @@ static void q6v5_mba_reclaim(struct q6v5 *qproc) qproc->active_clk_count); q6v5_regulator_disable(qproc, qproc->active_regs, qproc->active_reg_count); + q6v5_pds_disable(qproc, qproc->active_pds, qproc->active_pd_count); /* In case of failure or coredump scenario where reclaiming MBA memory * could not happen reclaim it here. @@ -1412,11 +1424,19 @@ static int q6v5_probe(struct platform_device *pdev) } qproc->active_reg_count = ret; + ret = q6v5_pds_attach(&pdev->dev, qproc->active_pds, + desc->active_pd_names); + if (ret < 0) { + dev_err(&pdev->dev, "Failed to attach active power domains\n"); + goto free_rproc; + } + qproc->active_pd_count = ret; + ret = q6v5_pds_attach(&pdev->dev, qproc->proxy_pds, desc->proxy_pd_names); if (ret < 0) { dev_err(&pdev->dev, "Failed to init power domains\n"); - goto free_rproc; + goto detach_active_pds; } qproc->proxy_pd_count = ret; @@ -1452,6 +1472,8 @@ static int q6v5_probe(struct platform_device *pdev) detach_proxy_pds: q6v5_pds_detach(qproc, qproc->proxy_pds, qproc->proxy_pd_count); +detach_active_pds: + q6v5_pds_detach(qproc, qproc->active_pds, qproc->active_pd_count); free_rproc: rproc_free(rproc); @@ -1469,6 +1491,7 @@ static int q6v5_remove(struct platform_device *pdev) qcom_remove_smd_subdev(qproc->rproc, &qproc->smd_subdev); qcom_remove_ssr_subdev(qproc->rproc, &qproc->ssr_subdev); + q6v5_pds_detach(qproc, qproc->active_pds, qproc->active_pd_count); q6v5_pds_detach(qproc, qproc->proxy_pds, qproc->proxy_pd_count); rproc_free(qproc->rproc); @@ -1495,6 +1518,10 @@ static const struct rproc_hexagon_res sdm845_mss = { "mnoc_axi", NULL }, + .active_pd_names = (char*[]){ + "load_state", + NULL + }, .proxy_pd_names = (char*[]){ "cx", "mx", From patchwork Tue Jan 29 23:20:09 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 157019 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp5253790jaa; Tue, 29 Jan 2019 15:20:46 -0800 (PST) X-Google-Smtp-Source: ALg8bN7P2qL7bP+TMnIn5FHB0R3dWjNeCsnpA0kEd5++0racID/niVl2eB7pWrDLC4No11egs7gX X-Received: by 2002:a63:5964:: with SMTP id j36mr25391652pgm.210.1548804046624; Tue, 29 Jan 2019 15:20:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548804046; cv=none; d=google.com; s=arc-20160816; b=BWXrvn6KoVw5KNSEzW4k07PgFyZyobX/RVEwLDC8k8WHKCCms0tYLH01WNte2E1CQ3 zrX6qA9eIloKdiw5k6Okxzm2hejLZaBs+CQ0cvI/ziUlzyI8HV8HFQKJg5xHitEyhxVh upeEcDCk+KPt6ORiThKYOMiZYBA3d42kLZl3xCzASgeNWkp2c3CUH7ms/deV+yZqRsGP /JZ7ooR8xSdY0Gln6Bu2BOtn4lnmAd4XIOhJEibzzaQNDpmbQelQtMXa+SV4NqBjG3nM 2SSnHhOt2xwSezMXn986G0STs99GgQKDljPQh5G1WMVVM2YD5HHX6sYltPQTS6UbyRtb r5Xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=y7woJHGPgzIIqbCsBKj31TBihnfFQpfwnMTZGOBzJNU=; b=skFe6e+QRT+YoAJs/lPsIH/K436S4REKPOACfl7Gb21m8taD03fkF9KlELFJLIVyDO XoeQoW6aNbpbjKdJXKCZWRaGLHGP4c2ILPxLJHJ2t19eSARkFeYjud9YAjegM/62mjUv sTrCVIU3z++vRRhcamaPrHl0QyLusU6xCFf1AeV1PRc/eqPrqWWVA7c8srBVVUIQcKIz AhQg7wiRg9Y5HARx5l4kXfcasF88PofQU+qFYsYr5eVOUzEkvfwPTxLv41BH3+KlgOpo 9TVgDB932SZrP36Ir88sG34FKN2jAuEdWNugyCtEN4oVPzc8duYUQS5V5DXA+eZsGfsC 0rhg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=O6eJ430i; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j135si32816948pgc.517.2019.01.29.15.20.46; Tue, 29 Jan 2019 15:20:46 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=O6eJ430i; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729835AbfA2XUp (ORCPT + 7 others); Tue, 29 Jan 2019 18:20:45 -0500 Received: from mail-pg1-f194.google.com ([209.85.215.194]:44926 "EHLO mail-pg1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729970AbfA2XUn (ORCPT ); Tue, 29 Jan 2019 18:20:43 -0500 Received: by mail-pg1-f194.google.com with SMTP id t13so9431683pgr.11 for ; Tue, 29 Jan 2019 15:20:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=y7woJHGPgzIIqbCsBKj31TBihnfFQpfwnMTZGOBzJNU=; b=O6eJ430iQ+KJ6Yek3/cpjgZYN7FjHW1DsdfAnpL0GrpxYrf5Jeomex7jn2yUxyQwQN Lscg0jK7EuUpo3bONBVg8YCmS7zQadkxUbz5oAhbiqrIVPCpv8WoeEJLXoV0PZ+lzI78 70ZpJvYIpqoIEDR8JTM59ple95dI62rM52S8M= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=y7woJHGPgzIIqbCsBKj31TBihnfFQpfwnMTZGOBzJNU=; b=n41OE9ZcMif4x20ATdXUHcoL6D/9MLKHIw3UwHcI4nrxeBuZJ3IMSVBu3WeyuWzDwz s8psBoUFFSHaPbzjfTm4afDryEmb2s3NWHE68H2Ia1qzAlETxe07KR/rKrG1chXBm6qS ZUWAlAB9l/vRQzG6I/LFoQ9Z1XYTJc3XCN3x/zQPr6C46MIXTbRk5oory4R4W9sD2fqa 5M/25o7DkRRfttXaRANIaiNKauoR10OAIa5/kNfnwjJpl9zOwjIs98WtSIoWIdw80LbI lewBs3Vu64tq82gtRdIk+5Jx1lFBZ9Shn29GePRQY9fYYAbw3OFLCg1ZMrnT+ZTpDESX 7t8Q== X-Gm-Message-State: AJcUukdqduUFysZAisQfB9k5ZPq6wIZBft/u1mxNCdJdYgi1veVJiHZU gdQOClkcgs3lq7NPgIg5oKBeQw== X-Received: by 2002:a63:441e:: with SMTP id r30mr25758642pga.128.1548804042315; Tue, 29 Jan 2019 15:20:42 -0800 (PST) Received: from localhost.localdomain (104-188-17-28.lightspeed.sndgca.sbcglobal.net. [104.188.17.28]) by smtp.gmail.com with ESMTPSA id v70sm51182779pfa.152.2019.01.29.15.20.41 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 29 Jan 2019 15:20:41 -0800 (PST) From: Bjorn Andersson To: Andy Gross , David Brown Cc: Rob Herring , Mark Rutland , Ohad Ben-Cohen , Arun Kumar Neelakantam , Sibi Sankar , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-remoteproc@vger.kernel.org Subject: [PATCH v4 10/10] arm64: dts: qcom: sdm845: Add Q6V5 MSS node Date: Tue, 29 Jan 2019 15:20:09 -0800 Message-Id: <20190129232009.5033-11-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20190129232009.5033-1-bjorn.andersson@linaro.org> References: <20190129232009.5033-1-bjorn.andersson@linaro.org> Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Sibi Sankar This patch adds Q6V5 MSS remoteproc node for SDM845 SoCs. Signed-off-by: Sibi Sankar Reviewed-by: Douglas Anderson Signed-off-by: Bjorn Andersson --- Changes since v3: - Fixed sort order in /soc arch/arm64/boot/dts/qcom/sdm845.dtsi | 58 ++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) -- 2.18.0 diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi index 24c30be974bf..eb02c39d2048 100644 --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi @@ -1618,6 +1618,64 @@ }; }; + mss_pil: remoteproc@4080000 { + compatible = "qcom,sdm845-mss-pil"; + reg = <0 0x04080000 0 0x408>, <0 0x04180000 0 0x48>; + reg-names = "qdsp6", "rmb"; + + interrupts-extended = + <&intc GIC_SPI 266 IRQ_TYPE_EDGE_RISING>, + <&modem_smp2p_in 0 IRQ_TYPE_EDGE_RISING>, + <&modem_smp2p_in 1 IRQ_TYPE_EDGE_RISING>, + <&modem_smp2p_in 2 IRQ_TYPE_EDGE_RISING>, + <&modem_smp2p_in 3 IRQ_TYPE_EDGE_RISING>, + <&modem_smp2p_in 7 IRQ_TYPE_EDGE_RISING>; + interrupt-names = "wdog", "fatal", "ready", + "handover", "stop-ack", + "shutdown-ack"; + + clocks = <&gcc GCC_MSS_CFG_AHB_CLK>, + <&gcc GCC_MSS_Q6_MEMNOC_AXI_CLK>, + <&gcc GCC_BOOT_ROM_AHB_CLK>, + <&gcc GCC_MSS_GPLL0_DIV_CLK_SRC>, + <&gcc GCC_MSS_SNOC_AXI_CLK>, + <&gcc GCC_MSS_MFAB_AXIS_CLK>, + <&gcc GCC_PRNG_AHB_CLK>, + <&rpmhcc RPMH_CXO_CLK>; + clock-names = "iface", "bus", "mem", "gpll0_mss", + "snoc_axi", "mnoc_axi", "prng", "xo"; + + qcom,smem-states = <&modem_smp2p_out 0>; + qcom,smem-state-names = "stop"; + + resets = <&aoss_reset AOSS_CC_MSS_RESTART>, + <&pdc_reset PDC_MODEM_SYNC_RESET>; + reset-names = "mss_restart", "pdc_reset"; + + qcom,halt-regs = <&tcsr_mutex_regs 0x23000 0x25000 0x24000>; + + power-domains = <&aoss_qmp AOSS_QMP_LS_MODEM>, + <&rpmhpd SDM845_CX>, + <&rpmhpd SDM845_MX>, + <&rpmhpd SDM845_MSS>; + power-domain-names = "load_state", "cx", "mx", "mss"; + + mba { + memory-region = <&mba_region>; + }; + + mpss { + memory-region = <&mpss_region>; + }; + + glink-edge { + interrupts = ; + label = "modem"; + qcom,remote-pid = <1>; + mboxes = <&apss_shared 12>; + }; + }; + gpucc: clock-controller@5090000 { compatible = "qcom,sdm845-gpucc"; reg = <0 0x05090000 0 0x9000>;