From patchwork Tue Aug 8 09:44:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 13345903 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6171CC001DF for ; Tue, 8 Aug 2023 09:45:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=fSVoaULtcbUh8IdX/K9QXXa0xad7hfmBPdsSWRs26x4=; b=kvlZq57EjNPR85 hKdz4pJB1nVcQHwjSRPMDuahlfncgiKCoJZT60upiQm9Pozz+/NjNOdHSHRC28jzod/D01/GiRIMP 6l+WDtiMNfsg3yZRVIVFf3mxyLR3M9qEy+tdi8D0eHLk9NcsGqNbp6CXk3HJFX5u1gsY7gfZy8thA SVUt2rT7zadromdXfUfKfXbVDkrIhL+Wx607caqNczabobDhHWU5fboQ6CoCmiH4b+kWx61F5WT6+ K6ebTCVGdmica72zIcBI2Pp7OsWH0vDfKadHwEqF7zRqVX/NDDX5qRbT65MRboXeHvE87/VxUU6uC NLzjjOXT7jQynJgSSA0Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qTJGs-002AB0-2F; Tue, 08 Aug 2023 09:44:58 +0000 Received: from mail-lf1-x131.google.com ([2a00:1450:4864:20::131]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qTJGl-002A79-37 for linux-arm-kernel@lists.infradead.org; Tue, 08 Aug 2023 09:44:53 +0000 Received: by mail-lf1-x131.google.com with SMTP id 2adb3069b0e04-4fe0d5f719dso8977336e87.2 for ; Tue, 08 Aug 2023 02:44:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691487889; x=1692092689; 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=4KW5W/BsMVq6+QNzWH4B7mMdqsIsqWz/fCs4TWl8ltY=; b=KSWYTc5D3BN3gp99SUg3MEoihR8mRf2Yxe9UrxtqsBYgJndJ3OWTn8CLZgter4FoFR i5Tzu4DyXPsf4zIMKSQESEwGQLbJ/ymAwxxeVMR4sW0nOBf2eGBPMzv2y6GxV5pmO7vb 9XrWFnxyh8ZsVQ5m/Ab5WeaedRbR/JYvzh/rsx45p++ZVPL1E+IgDsIFY95fjnjctCcx 6XyHZaJFyGHKbQF1qLh5YapRKJW/8DeVmz0vKghkGat/CQru9ozaXX+5tv1qdzUc55y/ IcmHcfu0R7HXOhrdUJtz7R0gFomC+MRrHPqH+TKk7NtAHasEA0HTGSHco95G+ORirVfv ScrQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691487889; x=1692092689; 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=4KW5W/BsMVq6+QNzWH4B7mMdqsIsqWz/fCs4TWl8ltY=; b=Dwg7+LDRwcO697KlLtyWx8gnLn38UJRtyXebt+QQDuRoleaDFdcwPN+YG0U6nL+2Gl 6OD5P26B5m0dbwHmJGWRZK+ZTcfgwm2+8LKvS+K3j0yg25TBsEDFURpA3Z7OuyJucqyb 4iB0Y9S32kJHuFmnx2iT0PLRznJrqrHuDznsz3/4MeTEjfMTyn0iz45Z4PUvhJ6/4hQ1 DHi78u+khVTlnLvJGUinVtykZmEOdtShMhEyDmHKIWgehqNHKdxi25xYEWHBfMuOzX9a Py1mEfxHMK2O+KGrgXJIUNOTABEJ4RbA79BVoTL3/vRWabqwUtkABaIlFTfXMr776oob pl5g== X-Gm-Message-State: AOJu0Yzyw+/nVmDvq9TDbauKSxjMsPhvqlrraYsKoNABo3to43pItBmR H50NLxl+GyjcU7Q7E7EZyFjSyA== X-Google-Smtp-Source: AGHT+IG1IYYssFkGiczWRJXJ2hNd7aUPVrG4bPRpm+cL/fBJQfj5HgLT+UBhH2Xhh05RcC4OK+d9Kw== X-Received: by 2002:a19:6518:0:b0:4fd:d18e:be33 with SMTP id z24-20020a196518000000b004fdd18ebe33mr7634340lfb.26.1691487889572; Tue, 08 Aug 2023 02:44:49 -0700 (PDT) Received: from [192.168.1.101] (abxi185.neoplus.adsl.tpnet.pl. [83.9.2.185]) by smtp.gmail.com with ESMTPSA id i6-20020a056512006600b004fdba93b92asm1818884lfo.252.2023.08.08.02.44.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Aug 2023 02:44:49 -0700 (PDT) From: Konrad Dybcio Date: Tue, 08 Aug 2023 11:44:41 +0200 Subject: [PATCH v2 1/6] arm64: dts: qcom: msm8998: Drop bus clock reference from MMSS SMMU MIME-Version: 1.0 Message-Id: <20230531-topic-8998_mmssclk-v2-1-34273e275c51@linaro.org> References: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> In-Reply-To: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , AngeloGioacchino Del Regno , Michael Turquette , Stephen Boyd , Jeffrey Hugo , Imran Khan , Rajendra Nayak , Joonwoo Park , Jeffrey Hugo , Will Deacon , Robin Murphy , Joerg Roedel , Jeffrey Hugo Cc: Marijn Suijten , Dmitry Baryshkov , Jami Kettunen , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev, Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1691487885; l=994; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=3dPVka+1yoTBWJAX5iuBqo/JljLJGzd9OEipOW26gpY=; b=P/xfTwdFTTKmfRH1cHDGu0mhCVETc7DhmfzfJHr6hh8cV9OWxxp8ilKs4ThwIArS2RVFHOVnf uG9mGb1qwVACAbr6fd75bvJra8iZTVEziz1Kd1WLVE66/LQYZdFZUkQ X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230808_024452_002638_E93E525F X-CRM114-Status: GOOD ( 11.23 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The MMSS SMMU has been abusingly consuming the exposed RPM interconnect clock. Drop it. Fixes: 05ce21b54423 ("arm64: dts: qcom: msm8998: Configure the multimedia subsystem iommu") Signed-off-by: Konrad Dybcio Reviewed-by: Jeffrey Hugo --- arch/arm64/boot/dts/qcom/msm8998.dtsi | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/msm8998.dtsi b/arch/arm64/boot/dts/qcom/msm8998.dtsi index a41a34dbcc3c..e40f6461f4fd 100644 --- a/arch/arm64/boot/dts/qcom/msm8998.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8998.dtsi @@ -2743,10 +2743,10 @@ mmss_smmu: iommu@cd00000 { clocks = <&mmcc MNOC_AHB_CLK>, <&mmcc BIMC_SMMU_AHB_CLK>, - <&rpmcc RPM_SMD_MMAXI_CLK>, <&mmcc BIMC_SMMU_AXI_CLK>; - clock-names = "iface-mm", "iface-smmu", - "bus-mm", "bus-smmu"; + clock-names = "iface-mm", + "iface-smmu", + "bus-smmu"; #global-interrupts = <0>; interrupts = From patchwork Tue Aug 8 09:44:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 13345904 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AA504C001B0 for ; Tue, 8 Aug 2023 09:45:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=8j+mypZaNMJy94+40+cnGbz7YdxllgdWIJ/CW84LF1o=; b=lVQPXvdBBWO9bG nmKWD6mdk3ANYDmUc2BWssfsexGlLBVd7GdEWD/A1lnbykkdZjGAeoX5xkZII+tVGttdZwWlygLUE Y/ngSdRiHrq2cO2bRDn7XWh61aEF9txpVfG01/xytpSX8WFoYoXHp2UE0PJAQ0XGol/J1wuwI1qqr yzbNxHinRTfb74RgtehrxOaUZK2dmngN3kccmUTDP+3JIEMv/itseAFD2/9xoz0nq5+dSVsDWE4CY flhv5rcSKKWjPzT7AX3Uz9HV3CvCaVMsxJQxyP8EtRUQxVOElaI6lB+2ObLnQD1JhSF5OM6RfirbD qSRxMdYyi/4lw3vYtXJg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qTJGt-002ABR-0g; Tue, 08 Aug 2023 09:44:59 +0000 Received: from mail-lf1-x134.google.com ([2a00:1450:4864:20::134]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qTJGn-002A7W-1o for linux-arm-kernel@lists.infradead.org; Tue, 08 Aug 2023 09:44:54 +0000 Received: by mail-lf1-x134.google.com with SMTP id 2adb3069b0e04-4fe383c1a26so8934263e87.1 for ; Tue, 08 Aug 2023 02:44:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691487891; x=1692092691; 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=X+614xtHjgD1nkm8xRBKqqyV2uZni5hqr1Y2F11sHVk=; b=QrrSZlNH7DwCjw8YYQSdqDs0bUcxQDorMEYEk7vp2qS6xl7os8OPuvCrC0lUCKxE8B gCB0QInnqHTXhGYWZmjvN8lVHlMjKq7ltiNhZ6kTxYXA5S9jh6gsfqL87TPRG2mcpBtv ekqBWdXMfFGCG4iWWYM1g9TcIvvhLxarkOIm/A7dZzYd3aXULM2jvMm/RprLZr8M7f3g X09MNDK2eCSehGh82bpEou5bqzlyLbwQNwBaC0rUhUz3jKJK5GkVFSMZgVXz3DxaNzE+ AzW5XUnG8QwRY7CHGHNfJ9H4GDrLTFrIs9LfaOIaJD43UTB/K/ImFXjCIlebg8yDU4jO Echg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691487891; x=1692092691; 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=X+614xtHjgD1nkm8xRBKqqyV2uZni5hqr1Y2F11sHVk=; b=L5kOf8hsK/6Gqzfw/Zd3rjH9SJL7We0C1nJDW+ykHATWRPsqk6tRX9CD96gJIwcvCn mg/Zxw3pOmy6UJpqwiKJKb3aNVxQO/jM5QLhJvMgSJaWhJOjW8nGDuX00eSzr7KiCcab SDPgRUTXMpijs1NtYjrBDlnY0GfjqcriuvS8g2XcqGX/dJ/2eqXyPET6me7GFRR2r6O0 litp5xicb2CWGVPAkNNIlhTeJuJBJK27YRRjFBTahd0StKmUhB8gLAjHp+tfZ8cZ0ihw CZFm/Dui5PI71lUgoF5PyfYJUcKZWBEc4M6XO5cX1ch2/LrcApbiDCB5tHEldF+Tmzwn QQmQ== X-Gm-Message-State: AOJu0Ywev192/pBCFZjSVu1p3xdIS6cDAlF92/zsNtEedXNHzTRc8Nmi I8IrtYZX7IhQ9fFA97El7ctmsA== X-Google-Smtp-Source: AGHT+IFVMdcEkHvqjIMX5oEgG2oBE7nbsEMOVRk5VcpuTnRc1mcmt8mNUyLq7GYjCrQ3jyb2zmb5Gw== X-Received: by 2002:a05:6512:e9b:b0:4fe:5680:db1f with SMTP id bi27-20020a0565120e9b00b004fe5680db1fmr7912704lfb.53.1691487891249; Tue, 08 Aug 2023 02:44:51 -0700 (PDT) Received: from [192.168.1.101] (abxi185.neoplus.adsl.tpnet.pl. [83.9.2.185]) by smtp.gmail.com with ESMTPSA id i6-20020a056512006600b004fdba93b92asm1818884lfo.252.2023.08.08.02.44.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Aug 2023 02:44:50 -0700 (PDT) From: Konrad Dybcio Date: Tue, 08 Aug 2023 11:44:42 +0200 Subject: [PATCH v2 2/6] arm64: dts: qcom: msm8998: Add missing power domain to MMSS SMMU MIME-Version: 1.0 Message-Id: <20230531-topic-8998_mmssclk-v2-2-34273e275c51@linaro.org> References: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> In-Reply-To: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , AngeloGioacchino Del Regno , Michael Turquette , Stephen Boyd , Jeffrey Hugo , Imran Khan , Rajendra Nayak , Joonwoo Park , Jeffrey Hugo , Will Deacon , Robin Murphy , Joerg Roedel , Jeffrey Hugo Cc: Marijn Suijten , Dmitry Baryshkov , Jami Kettunen , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev, Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1691487885; l=854; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=/yznmFUOFfvt3H81R22ABUv0eOeLe9LUwSr+QNKzGV0=; b=6ok/LWtlPH6zSyy5UMAq/t5bgWP3Ud7Ij9vBySuwjh3vMiS1gJVjxUKw6nLHyS95ARxX+LJAd Ibm+ib3FKxpBIIhASbXVDOfZYxEwn1cNsRmJHG+sQTEmtuUOfL5elUO X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230808_024453_606219_F2DB81EC X-CRM114-Status: UNSURE ( 9.63 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The MMSS SMMU has its own power domain. Attach it so that we can drop the "keep it always-on" hack. Fixes: 05ce21b54423 ("arm64: dts: qcom: msm8998: Configure the multimedia subsystem iommu") Signed-off-by: Konrad Dybcio Reviewed-by: Jeffrey Hugo --- arch/arm64/boot/dts/qcom/msm8998.dtsi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/msm8998.dtsi b/arch/arm64/boot/dts/qcom/msm8998.dtsi index e40f6461f4fd..39db67211fae 100644 --- a/arch/arm64/boot/dts/qcom/msm8998.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8998.dtsi @@ -2770,6 +2770,8 @@ mmss_smmu: iommu@cd00000 { , , ; + + power-domains = <&mmcc BIMC_SMMU_GDSC>; }; remoteproc_adsp: remoteproc@17300000 { From patchwork Tue Aug 8 09:44:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 13345902 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AE3B8C001B0 for ; Tue, 8 Aug 2023 09:45:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=NBUfb1wbwOebStiHiKaM1Qp/jg6FW73/Yc1nCslsVB4=; b=dGSXp1ketAV4Kc C4Wk18ZJs+tka8pjVvAg9l6bBS0rUa9ROwaj3PccsiiIYVCRTDHuB7iXHN9UkHmY7zhsf7UUAqhOO 6+M2sX2yeWBX9ripuzSjRTABe9zOF6hd28k0ZzW9Ac0QumSnBapB0hP9rcuCPqLK1RpTLgIoGMllr pE8FGtJiGso+vmf7E8X4NUQIdjb6vM64YcZOPFiufxvxmNmPIs0rZWyNnb0MAUjLv3kvAnvyTaf0L iBCdUY4KXyYZY7pPWhlFTtSrwV0pyTmhZQMBTjVHD70hvsDqPl6W5NAvc0+TwbxKxZ9OdS/x9DSJf DZEMDRoylj8T0IzSanQQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qTJGt-002ABq-2V; Tue, 08 Aug 2023 09:44:59 +0000 Received: from mail-lf1-x12f.google.com ([2a00:1450:4864:20::12f]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qTJGp-002A8i-0I for linux-arm-kernel@lists.infradead.org; Tue, 08 Aug 2023 09:44:56 +0000 Received: by mail-lf1-x12f.google.com with SMTP id 2adb3069b0e04-4fe15bfb1adso9033069e87.0 for ; Tue, 08 Aug 2023 02:44:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691487893; x=1692092693; 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=TJRcX7l83GzG4nljjiXsSgTVORkCZorOu6CVVdtQF3E=; b=FwiZRivLw+b6j30Dqlfa0OdR8cWxJe7FJS3Eu98iehs4rEHG8XlD4DuQthJ9CgHo40 la1bXGL1RFgr5GLcaUqBBdxTxz+1kpZ7MjHphaTd03aCEMc2gEeWfUoWzgF182uzpscs SUZjI1uHCC7TX63M85GU8m5AB+wP7ti3nZd1N32a5FrobBDqEGAfmj/ok1wSnrpvAYo1 M8ReC5IkwmhBw0hwjsnlPwpnS4TzShlBCSNGz3MzgJ/ispJj2MSOYCHmeJRCj5MwCkQn 5IfDBUUzF700hih29k9XgIzd9MMTos9wgbWx0Kp6GyQF4KWi2AJtWvxTYx4mcIrRWRAJ ILMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691487893; x=1692092693; 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=TJRcX7l83GzG4nljjiXsSgTVORkCZorOu6CVVdtQF3E=; b=GtE4irsf4C+PjEvXa98qk4n/22kdtDTXiO2QW+K5EFiNRGXQDFkUVvpltweZUoKJB/ fTyEnOxRn40JAegV0td/u73w39l8rvyU2Hspeze9YxZg5Kjr0j60P+O4kt3y4BGgsJZ6 iv/B7gO072qjD+WiF8r/2tLZo/mR7lndIuV49c5LHO5kxwJVbhXoYLQMtHa0xSvZOPSN mpUtFUhpj+P+lTs/lmjCcxaxD714p0yUvgTGBLn60f4iXu8tjglTkb3iGwjaxGZiIdtU DZ8Vms4oF7C/Jyf+0fEiRDebPRbMk+Jsng7p6MiKaAHmf1p+j2vJvvixabyY0QXTyIUy KMrg== X-Gm-Message-State: AOJu0Yz1A+uh7+pKhZrJmd5pCzuL7Rec4ifipmI0NnCt0ePylAP0ke+q RKFJV/07QtM8S6nXa6Js3Gibqw== X-Google-Smtp-Source: AGHT+IGHUT7VSfmI8VQtBPNaetpOWrfLKOPZbXgUnGq/oqs5MCTMjFVV+jNZ7mtrZHhq6p1BDeKZtQ== X-Received: by 2002:a05:6512:39c3:b0:4fb:89e3:5ac6 with SMTP id k3-20020a05651239c300b004fb89e35ac6mr9893926lfu.62.1691487893637; Tue, 08 Aug 2023 02:44:53 -0700 (PDT) Received: from [192.168.1.101] (abxi185.neoplus.adsl.tpnet.pl. [83.9.2.185]) by smtp.gmail.com with ESMTPSA id i6-20020a056512006600b004fdba93b92asm1818884lfo.252.2023.08.08.02.44.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Aug 2023 02:44:53 -0700 (PDT) From: Konrad Dybcio Date: Tue, 08 Aug 2023 11:44:43 +0200 Subject: [PATCH v2 3/6] clk: qcom: gcc-msm8998: Don't check halt bit on some branch clks MIME-Version: 1.0 Message-Id: <20230531-topic-8998_mmssclk-v2-3-34273e275c51@linaro.org> References: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> In-Reply-To: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , AngeloGioacchino Del Regno , Michael Turquette , Stephen Boyd , Jeffrey Hugo , Imran Khan , Rajendra Nayak , Joonwoo Park , Jeffrey Hugo , Will Deacon , Robin Murphy , Joerg Roedel , Jeffrey Hugo Cc: Marijn Suijten , Dmitry Baryshkov , Jami Kettunen , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev, Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1691487885; l=1627; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=4vcJD39xmmwGxR16do/vEynX3nfOkYLGbzSw65dGFMA=; b=t/2b5DxWk6eOZxBSMoG1WvSgfjtXnl9wcFAwd+sra0DiGErD9S3YZpkCbKjr1qwJdtT7FY3gv IJZo/StB+T4CsgBs40j0+BPJSYBAKHNwSKgL7MrSPgapI+FCbOr3UJU X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230808_024455_130276_2561B89D X-CRM114-Status: GOOD ( 12.63 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Some branch clocks are governed externally and we're only supposed to send a request concerning their shutdown, not actually ensure it happens. Use the BRANCH_HALT_SKIP define to skip checking the halt bit. Fixes: db2c7c0a04b1 ("clk: qcom: Add missing msm8998 gcc_bimc_gfx_clk") Fixes: b5f5f525c547 ("clk: qcom: Add MSM8998 Global Clock Control (GCC) driver") Reviewed-by: Jeffrey Hugo Signed-off-by: Konrad Dybcio --- drivers/clk/qcom/gcc-msm8998.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/clk/qcom/gcc-msm8998.c b/drivers/clk/qcom/gcc-msm8998.c index 1ba516a0c0f3..257b27d8eeb6 100644 --- a/drivers/clk/qcom/gcc-msm8998.c +++ b/drivers/clk/qcom/gcc-msm8998.c @@ -2060,7 +2060,7 @@ static struct clk_branch gcc_gp3_clk = { static struct clk_branch gcc_bimc_gfx_clk = { .halt_reg = 0x46040, - .halt_check = BRANCH_HALT, + .halt_check = BRANCH_HALT_SKIP, .clkr = { .enable_reg = 0x46040, .enable_mask = BIT(0), @@ -2073,7 +2073,7 @@ static struct clk_branch gcc_bimc_gfx_clk = { static struct clk_branch gcc_gpu_bimc_gfx_clk = { .halt_reg = 0x71010, - .halt_check = BRANCH_HALT, + .halt_check = BRANCH_HALT_SKIP, .clkr = { .enable_reg = 0x71010, .enable_mask = BIT(0), @@ -2099,7 +2099,7 @@ static struct clk_branch gcc_gpu_bimc_gfx_src_clk = { static struct clk_branch gcc_gpu_cfg_ahb_clk = { .halt_reg = 0x71004, - .halt_check = BRANCH_HALT, + .halt_check = BRANCH_HALT_SKIP, .clkr = { .enable_reg = 0x71004, .enable_mask = BIT(0), From patchwork Tue Aug 8 09:44:44 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 13345905 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5BA03C001DF for ; Tue, 8 Aug 2023 09:45:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=GPz6clth/q8PQcw4M6zT+G1o4fPg5u+AzK6RxmOhUEE=; b=GWp3T9SveNiMTL jZ3U5eac3aCbtFV/aTHl7/HtBs5Afy+VGYztzQmAqDW17Sp3lXy+SbKGqlmw9xR2KIn4VxjjqfVz5 W/GdS72pyv2SbkF5XVAtN2DSPEbzH6Kk44J1w80eJfayG19B+eeSTWxSoG3ZSqetNUU0RkUwZznR7 ImopH2rAcvkSR5m1/i5UYXI45N1yiDAJSyYuk/WkVaFWORJGoH6T9ZxiJV8Eu+pA96w6S2afIj83k fmrcG2hPSeGGEvOxUDureeU0ipQ9bRWsXaXgp2oru21tsfpbxQI4pmIF1I0ST6ecsU04+OkkWo15A 48ZnzkarygV+CGD+kA3g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qTJH2-002AGf-2I; Tue, 08 Aug 2023 09:45:08 +0000 Received: from mail-lf1-x12e.google.com ([2a00:1450:4864:20::12e]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qTJGr-002A9V-1u for linux-arm-kernel@lists.infradead.org; Tue, 08 Aug 2023 09:44:58 +0000 Received: by mail-lf1-x12e.google.com with SMTP id 2adb3069b0e04-4fe48a2801bso8958110e87.1 for ; Tue, 08 Aug 2023 02:44:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691487895; x=1692092695; 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=gAg8mzz6tXJyaH1tEofpHQ5TEsFiQj+ho2hy+w4Tmaw=; b=ca5JW3Xvljn6DS1Xd30alZ4zxwYWFfovT2/rBr10h3IRpLg6vWyhTXUfMMgEyXqjTf fVDwI1brYe5iB+WTXfMIV1RDdxF7O5GvXM0qXs0nH55nSS+hJ4An72Q1UINLCpwN0qUz 2fFCXnGgDe0vK3E9HfN29br11SFPCQH//SDWZqJ69g/t1hS0kzIZj2X4vIBtwGdACO05 MQaXEif+bHQApWXNcjRX9OE2oHPylbrNc+zQwy8c69Ex5aUrRsemjdGkXgncPXU0gdNS /dbIXvpSj07PckDr1QK7ijnoXXkwb77lJnIgx0p7wwKkH8dBqwCJQHZllcz0ypf1OX9H vW/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691487895; x=1692092695; 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=gAg8mzz6tXJyaH1tEofpHQ5TEsFiQj+ho2hy+w4Tmaw=; b=iYsXu/0yQr0Rna1gKVRX9c8qDpJXqsvXYAGhjevfVOEdVejvLuK73QkuQ8Gm7WHPA2 hzGmbSvrK6mQDrqxxcbML/M625zU7ssNsIvNCcZgaAkLEG8StZItTRTMXWgfiTFxfPZJ x/xK43iwlgtqCoMkASCLBaV/HO0z/WPS4W9SUGf+rAuItFw/YPGb6TAm5893XYFmwF/L d0JbB/60fJDRvIhTGwMcDchvIE99tx/xi5dwx9bawNs36oeru3hlC6xg70k8NfwHMGAm ua9cXAJ/Gzc3Q/4KatyuLHTZfaHuZ6rVisQz30oK+HSEbLtfTGb+OUCjPAjQR9LUjdoM 7nYg== X-Gm-Message-State: AOJu0Yy4dRbQLmJTgSHrfi6YxVbYU50DhajPIs0RUGXeXCb/3Sh0ta8l 16FTg4IVJjnmzNRPVrxtnPSjZw== X-Google-Smtp-Source: AGHT+IHZdXCtug2ljX6dDSj6oQkG8V1UJLNKTYOKnSjmV42sR9+Wv2CCmrrKVl5VAmfJlHe6DhBOLg== X-Received: by 2002:a05:6512:2018:b0:4fd:c771:ed86 with SMTP id a24-20020a056512201800b004fdc771ed86mr6615303lfb.67.1691487895251; Tue, 08 Aug 2023 02:44:55 -0700 (PDT) Received: from [192.168.1.101] (abxi185.neoplus.adsl.tpnet.pl. [83.9.2.185]) by smtp.gmail.com with ESMTPSA id i6-20020a056512006600b004fdba93b92asm1818884lfo.252.2023.08.08.02.44.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Aug 2023 02:44:54 -0700 (PDT) From: Konrad Dybcio Date: Tue, 08 Aug 2023 11:44:44 +0200 Subject: [PATCH v2 4/6] clk: qcom: mmcc-msm8998: Don't check halt bit on some branch clks MIME-Version: 1.0 Message-Id: <20230531-topic-8998_mmssclk-v2-4-34273e275c51@linaro.org> References: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> In-Reply-To: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , AngeloGioacchino Del Regno , Michael Turquette , Stephen Boyd , Jeffrey Hugo , Imran Khan , Rajendra Nayak , Joonwoo Park , Jeffrey Hugo , Will Deacon , Robin Murphy , Joerg Roedel , Jeffrey Hugo Cc: Marijn Suijten , Dmitry Baryshkov , Jami Kettunen , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev, Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1691487885; l=1407; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=haDOFYx+cWB8WYF0AFsxGiNUFhwDHpLSQyDe+vgkap0=; b=ZrMZ0b0kru/BioU+kcPyTGDosiv5UYR3dvjZ97R7NYb1CKIWbtfb6OQL9uoCg1eDGTN2RtwgC KnIylLEWD68BzoXZqSp7GXw9MgJJMQxVOqARg8YLk04oG4zFHl8Kfq8 X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230808_024457_633217_B0E1FF45 X-CRM114-Status: GOOD ( 11.77 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Some branch clocks are governed externally and we're only supposed to send a request concerning their shutdown, not actually ensure it happens. Use the BRANCH_HALT_SKIP define to skip checking the halt bit. Fixes: d14b15b5931c ("clk: qcom: Add MSM8998 Multimedia Clock Controller (MMCC) driver") Reviewed-by: Jeffrey Hugo Signed-off-by: Konrad Dybcio --- drivers/clk/qcom/mmcc-msm8998.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/clk/qcom/mmcc-msm8998.c b/drivers/clk/qcom/mmcc-msm8998.c index c62aa270af1c..d0a5440e2291 100644 --- a/drivers/clk/qcom/mmcc-msm8998.c +++ b/drivers/clk/qcom/mmcc-msm8998.c @@ -2452,6 +2452,7 @@ static struct clk_branch fd_ahb_clk = { static struct clk_branch mnoc_ahb_clk = { .halt_reg = 0x5024, + .halt_check = BRANCH_HALT_SKIP, .clkr = { .enable_reg = 0x5024, .enable_mask = BIT(0), @@ -2467,6 +2468,7 @@ static struct clk_branch mnoc_ahb_clk = { static struct clk_branch bimc_smmu_ahb_clk = { .halt_reg = 0xe004, + .halt_check = BRANCH_HALT_SKIP, .hwcg_reg = 0xe004, .hwcg_bit = 1, .clkr = { @@ -2484,6 +2486,7 @@ static struct clk_branch bimc_smmu_ahb_clk = { static struct clk_branch bimc_smmu_axi_clk = { .halt_reg = 0xe008, + .halt_check = BRANCH_HALT_SKIP, .hwcg_reg = 0xe008, .hwcg_bit = 1, .clkr = { From patchwork Tue Aug 8 09:44:45 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 13345906 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E46BAC001B0 for ; Tue, 8 Aug 2023 09:45:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=PVzKogrqQSckG4QlRaL4MRHLSCTMYHGjwQO1aAWd+XE=; b=ZRI6zD2F/wDueP BNEk49x7l0eu1hkctCwJK8bJUxQpktDtjh8wl93lXho9pHlR6KU5ZA+pg8kAXggSSH0ldJPIOxW6n V2ERsEpWn7ECVGDMUw9qMCoHK76/mlTLVfZvj75yb0ilCFwmZTwXVj0X2jb4DGekalrNwZ0wvBx95 YrmaOog6cabxhZwv6IzyT3gQ9NG15uBBy8we9cBxlnWXIkw3oeGj4Wqoy26mHs4k7M7VDW1upXFAj hFSWudt+cermncVw4r9W6XTCBfckhy/fSrzSE/LVjeMyXevo4ZSjl8smCb3zUB4haRuX02aG0Zm4r I6dHp/G+aF3hcgvSZAiA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qTJH3-002AH1-0i; Tue, 08 Aug 2023 09:45:09 +0000 Received: from mail-lf1-x12b.google.com ([2a00:1450:4864:20::12b]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qTJGt-002AAu-2H for linux-arm-kernel@lists.infradead.org; Tue, 08 Aug 2023 09:45:01 +0000 Received: by mail-lf1-x12b.google.com with SMTP id 2adb3069b0e04-4fe5ab64a26so6414551e87.2 for ; Tue, 08 Aug 2023 02:44:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691487897; x=1692092697; 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=dlY5pXEYcBgHeb5qjzLwZeG+1V5JyWmwzq+8kailYB8=; b=v+PRDMZxsoLGpseVtkDvUJn58AZ1YAzEUzT4w0Zjtj4lt3VSh7JoXsim8kFKzP7l0d 8lNcQdku11MFWwF4cUUHmQf1XfwsRgVb654spJLXNc6tWBMWvQSuz/B3eN7WzKk2O+Ia cU1l8PDw2X1xUBrFVT6WkBNRgyDvHShiCf1aLPR28RSF/Rsa0xf3LZtp5J2BlxwzYkfs qKelIW9m/mx05lZFUMBILBhEuPUBUNcGdkiiapP0l05E+J8ol3s4I4YXgHttqbEBwl0M kbRPuTrMg1oFN3i6Fq4ckhhZHu/fVE76242lTBcE5rrXYsRo37EkzRy8COpvrvUX02k/ r5hw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691487897; x=1692092697; 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=dlY5pXEYcBgHeb5qjzLwZeG+1V5JyWmwzq+8kailYB8=; b=UCo2pwe0XDJokiHYVIdfzInMsAmaIAmBBXX2LTq1yQPi1tqk1BApAtJAT698VFV5RJ Gf2ogJmwlTVgsaCnf+neGBEYBh3FIrfAoXH1TcdMj0hVvxSpRwGGvKR8hOLY7LS2MUSv hDcdM5g+q78hY2GWQBzejitsHIbhExKxBhR4rfOK5EoYjsn6ZvB5KBRgxsuLVZAnMW5D j63C7qh97KIwFo3i3PbO6ExIh9io4dYAW31+G3MKmkaTF6tIonjAbxD9F8hUfX/xLmf1 iLZc5SpJ6W93bieqXVsjZ3EcPOQ6TpJBkYmBF6NaaGq2Mp9ZHhLIRA30JN0stX3604v/ 5QZg== X-Gm-Message-State: AOJu0Yy75l4AFJbnmDl7DZfJ8RBXiBeM7ZIvU5GiTOq+HGRmYQ9yosfk 0DBKeixjxYD2OnFV25HEZB5YHQ== X-Google-Smtp-Source: AGHT+IHh37iYuUiKI2GbU0AYhtJBCPFDqyHRg6hHZo0rvcAp0zMmu3aywLaX3w+vkrjWoKcJi+lCTw== X-Received: by 2002:a05:6512:20c1:b0:4f8:58af:ebd7 with SMTP id u1-20020a05651220c100b004f858afebd7mr6593359lfr.39.1691487897383; Tue, 08 Aug 2023 02:44:57 -0700 (PDT) Received: from [192.168.1.101] (abxi185.neoplus.adsl.tpnet.pl. [83.9.2.185]) by smtp.gmail.com with ESMTPSA id i6-20020a056512006600b004fdba93b92asm1818884lfo.252.2023.08.08.02.44.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Aug 2023 02:44:56 -0700 (PDT) From: Konrad Dybcio Date: Tue, 08 Aug 2023 11:44:45 +0200 Subject: [PATCH v2 5/6] clk: qcom: mmcc-msm8998: Fix the SMMU GDSC MIME-Version: 1.0 Message-Id: <20230531-topic-8998_mmssclk-v2-5-34273e275c51@linaro.org> References: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> In-Reply-To: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , AngeloGioacchino Del Regno , Michael Turquette , Stephen Boyd , Jeffrey Hugo , Imran Khan , Rajendra Nayak , Joonwoo Park , Jeffrey Hugo , Will Deacon , Robin Murphy , Joerg Roedel , Jeffrey Hugo Cc: Marijn Suijten , Dmitry Baryshkov , Jami Kettunen , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev, Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1691487885; l=1105; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=87zmBNCrKExC5fA2pDw1hJreUEORhjqL4+NYXqa3bgY=; b=VT9trWuRQROU5ByyIvzOsud1+jUCahMFSSwl7lXsHgNEroaV6TNcWL2Qi+2HDnBgH+uqXNQKx XLni2Mv9lxlCRZ/eHiiHKdcIHZUZoGsQGa7E5QjDCIxTVH8MTuWmOw8 X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230808_024459_745232_DC8530C9 X-CRM114-Status: GOOD ( 13.78 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The SMMU GDSC doesn't have to be ALWAYS-ON and shouldn't feature the HW_CTRL flag (it's separate from hw_ctrl_addr). In addition to that, it should feature a cxc entry for bimc_smmu_axi_clk and be marked as votable. Fix all of these issues. Fixes: d14b15b5931c ("clk: qcom: Add MSM8998 Multimedia Clock Controller (MMCC) driver") Signed-off-by: Konrad Dybcio --- drivers/clk/qcom/mmcc-msm8998.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/clk/qcom/mmcc-msm8998.c b/drivers/clk/qcom/mmcc-msm8998.c index d0a5440e2291..4fdc41e7d2a8 100644 --- a/drivers/clk/qcom/mmcc-msm8998.c +++ b/drivers/clk/qcom/mmcc-msm8998.c @@ -2627,11 +2627,13 @@ static struct gdsc camss_cpp_gdsc = { static struct gdsc bimc_smmu_gdsc = { .gdscr = 0xe020, .gds_hw_ctrl = 0xe024, + .cxcs = (unsigned int []){ 0xe008 }, + .cxc_count = 1, .pd = { .name = "bimc_smmu", }, .pwrsts = PWRSTS_OFF_ON, - .flags = HW_CTRL | ALWAYS_ON, + .flags = VOTABLE, }; static struct clk_regmap *mmcc_msm8998_clocks[] = { From patchwork Tue Aug 8 09:44:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 13345907 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C1C34C04A94 for ; Tue, 8 Aug 2023 09:45:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ESBn30MVG7jF9IXxVjQTjek1BmRUfiFlSRH9AaqV/d8=; b=WoRcckS/FKoTa1 4a2D1bqff8LHeidWi5w53x0P4zRaoQRja9j1OwDLmIkWt3su9XOUZJBR+BvJ3Z6/kmmWNk2UaTIwg 3zwNWLiowtrJIOZXw49wQgY0XuDTlignx1s/226zYATIap4qSGqMnntW2MMbnyWAEFJzLyurMybfh i8azKXC/Ao1aeDPxbRU56Jxg7xxc2Tz8aqiOLo1A5ynksI6ckOxG/cxq4UisVKKsbhGkDhzzYbqum f/m3BMpHDvuFj/kJO0M3vTcRQNDRu7PnFVQDzI1nNuy14Or/X5VWpYYaokTSqUjUmzvIpK0AM7Ixu R9rw5wuelvmwKDeCyKeg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qTJH3-002AHR-2Z; Tue, 08 Aug 2023 09:45:09 +0000 Received: from mail-lf1-x130.google.com ([2a00:1450:4864:20::130]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qTJGv-002ABp-1n for linux-arm-kernel@lists.infradead.org; Tue, 08 Aug 2023 09:45:03 +0000 Received: by mail-lf1-x130.google.com with SMTP id 2adb3069b0e04-4fe28e4671dso8826369e87.0 for ; Tue, 08 Aug 2023 02:45:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1691487899; x=1692092699; 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=2UuNhIPZQtVYzGmtMAw0xH3Mxdy93w7NQpbLuvaKjSg=; b=NrsC+6SfK6rrKzds1RrsxA8Em04z6KSF6jwxNJkKNWfdT9aRNwpmjHnFS9gBgqtXis 3dO/eSIliY7p/DzI8Ni3ODs5ut5E8pSf8uUpDGK1qS1vefoOck8jIYS4XE33QA/yggre NBegANHiapxeMUgfuRGPkAUmInRYZSLFPHEupPNC9ey35dcO/szxV/HvYjiZkaYsJ0P9 7/Gq4Sg1atuhWYG1d74XTAq13ZqcVlQ4KCF9DMv/pXacWpbKA0/nQAs7XlXQql/RdfL8 6QtYGgU7H7HuhT+YKoMgoDhVwGEOwynL0Z4Z0Dk+cos2BEyJ44OfZQtOhEW1QMBt2sKz qHfQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691487899; x=1692092699; 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=2UuNhIPZQtVYzGmtMAw0xH3Mxdy93w7NQpbLuvaKjSg=; b=j1WX577MF0H0F0rWvaTkrZTFTxLw2DtqQ/pZptTzmYS2y0Ky+s1ZBeNQ1j/NCMVvUC MOe64MkQFqxPrKw+4HSt4tAohWP0b3ven6HPCsADmh3XKg05vxJpgWIdUYZLPERTi+ty cfIwkCGYrXNmSs1szXRefghZ6y3uQFtH/KlEkbRmtp761TjGkN1Jj4PmdLJfP82En9dV v35AA+6/JSNm1N+gvBvkpg4kAoaPGR0bWZSkGZPpvsAE6x1yYHH2TCY1BJLzdCLw82Y6 fAo9Yv0x0BLwHqnbpD9SxHoegaG8yFSjpe/pl58m0nhIaMsJBcBdlvCjLXAfZM/VrXul LMYA== X-Gm-Message-State: AOJu0YwCc2fqLCL8JEqQ+HqHgOfXzhRPobqIxPTof7ES7REmSzP6g9vl 2dUC0EypxjG49t7JUSl4kP+iRA== X-Google-Smtp-Source: AGHT+IHe6NP3MzfgZSWbkR7jxRMoFmcA9NIiePawh4EYEM7Q9mrKbCLB6JP4QQacs26mWD9MoLIIVw== X-Received: by 2002:ac2:4ece:0:b0:4f8:5604:4b50 with SMTP id p14-20020ac24ece000000b004f856044b50mr7020474lfr.64.1691487899167; Tue, 08 Aug 2023 02:44:59 -0700 (PDT) Received: from [192.168.1.101] (abxi185.neoplus.adsl.tpnet.pl. [83.9.2.185]) by smtp.gmail.com with ESMTPSA id i6-20020a056512006600b004fdba93b92asm1818884lfo.252.2023.08.08.02.44.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Aug 2023 02:44:58 -0700 (PDT) From: Konrad Dybcio Date: Tue, 08 Aug 2023 11:44:46 +0200 Subject: [PATCH v2 6/6] dt-bindings: arm-smmu: Fix MSM8998 clocks description MIME-Version: 1.0 Message-Id: <20230531-topic-8998_mmssclk-v2-6-34273e275c51@linaro.org> References: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> In-Reply-To: <20230531-topic-8998_mmssclk-v2-0-34273e275c51@linaro.org> To: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , AngeloGioacchino Del Regno , Michael Turquette , Stephen Boyd , Jeffrey Hugo , Imran Khan , Rajendra Nayak , Joonwoo Park , Jeffrey Hugo , Will Deacon , Robin Murphy , Joerg Roedel , Jeffrey Hugo Cc: Marijn Suijten , Dmitry Baryshkov , Jami Kettunen , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, iommu@lists.linux.dev, Konrad Dybcio X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1691487885; l=2406; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=GiTo3aHVWSJqXeRVvBwFrjMpXiRsIg5liCVx9M1P4EU=; b=Nxs8hOuPBNmdHqXrObFj394Ryc0kynWXqn1i40tZ53Cb01Hzw6WwtFi+3X0Jcw4BcgOd603j0 ZWoh4q6XnKVBZvu54Q3HrIhvJNMsEM/z8rSRfzNPESDS1/k+Iq2OYtg X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230808_024501_653431_BF45108E X-CRM114-Status: GOOD ( 10.83 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org MSM8998 was abusingly referencing one of the internal bus clocks, that were recently dropped from Linux (because the original implementation did not make much sense), circumventing the interconnect framework. Fix it. Signed-off-by: Konrad Dybcio Reviewed-by: Krzysztof Kozlowski --- .../devicetree/bindings/iommu/arm,smmu.yaml | 41 ++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/Documentation/devicetree/bindings/iommu/arm,smmu.yaml b/Documentation/devicetree/bindings/iommu/arm,smmu.yaml index 3a31a979709b..cf29ab10501c 100644 --- a/Documentation/devicetree/bindings/iommu/arm,smmu.yaml +++ b/Documentation/devicetree/bindings/iommu/arm,smmu.yaml @@ -270,6 +270,47 @@ allOf: contains: enum: - qcom,msm8998-smmu-v2 + then: + anyOf: + - properties: + clock-names: + items: + - const: bus + clocks: + items: + - description: bus clock required for downstream bus access and for + the smmu ptw + - properties: + clock-names: + items: + - const: iface + - const: mem + - const: mem_iface + clocks: + items: + - description: interface clock required to access smmu's registers + through the TCU's programming interface. + - description: bus clock required for memory access + - description: bus clock required for GPU memory access + - properties: + clock-names: + items: + - const: iface-mm + - const: iface-smmu + - const: bus-smmu + clocks: + items: + - description: interface clock required to access mnoc's registers + through the TCU's programming interface. + - description: interface clock required to access smmu's registers + through the TCU's programming interface. + - description: bus clock required for the smmu ptw + + - if: + properties: + compatible: + contains: + enum: - qcom,sdm630-smmu-v2 - qcom,sm6375-smmu-v2 then: