Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp4647729rwb; Mon, 31 Jul 2023 09:58:09 -0700 (PDT) X-Google-Smtp-Source: APBJJlEQWMFnrUmi9Z6N929vEvLR+4TqsiX6Y7TOsnXQIdOleSCp3nmKdBwZNuZR5UwRdjtovFgB X-Received: by 2002:a05:6808:bd1:b0:3a7:3b6c:ecb9 with SMTP id o17-20020a0568080bd100b003a73b6cecb9mr2977141oik.22.1690822688539; Mon, 31 Jul 2023 09:58:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690822688; cv=none; d=google.com; s=arc-20160816; b=xWELbCj99qyHas8WEIs4/gT4cA4COapGJ8kOA6pLTYHzIOF6nATJ4voCsBYphswg8m w0DNU4W/fRk2WZdRiIApiMWTtTXHbUJd5X5cK0bFv/wPqPYEhE87/uuvIl+BtWDY77Kb CZDQAyPLEggNp4uP1IXJoFZZ/fB/sgzxhqAg5VB3f05yi0kG4Q0AP/S+zxuYpxtmM7WR oo/JdKpQX1b6iNcRoGVsFnP+hZA27cY/6Sy6SxzA/JQ3YbLuWuIBwfcttlLeihDoAfaw 6g4G8+hrEsmAco7NbhxpCsDNDUjMJqixIbuyBuDtX2nkmzKsrV8yOO6Q0sGb7qnPFFGU seIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=0fZoRzqsVsl2DrqFfH7FNxDnDstpZGeIPe8SX7WYfkY=; fh=3109qC6i7dREPMf79CsN/jl+9zRd4/rV6IOQmZMqsxU=; b=g62NpgCEYsD2VmAfhWQuLmXFs/S4W5OkoSWoBZFUKQH6QJ1XUWgPfEIpv19sPZgShK ZYFWAzEJosEmIJdn1dVA/yL34LMC5JHukZoitu6eh1FRo/mlDqkE9SaCS3HAZkXT3pec ykWbrMRSsuJIVC+WzM/6D0YrnniETQe4EcaAGx9whQw0RiTLPXj075iMM9akpkLyxG9D UYzOnJuVwk4wSLmC0fwkZ7zTYREnt/LjEn1gEreqn9KtGtygTgopKIXOE6M1g6AqydwV ZKZDRI3HYslPPJm02+lL/oYm7JuBCmogjLZFuCwuypHb4eSfi5Htc4YRxVzFKHnkxs6D 5gPQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=apDEw9gu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id l190-20020a6388c7000000b00563c4244af9si4640233pgd.722.2023.07.31.09.57.55; Mon, 31 Jul 2023 09:58:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=apDEw9gu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-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 S233419AbjGaQf5 (ORCPT + 99 others); Mon, 31 Jul 2023 12:35:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38646 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233380AbjGaQfd (ORCPT ); Mon, 31 Jul 2023 12:35:33 -0400 Received: from mail-pl1-x629.google.com (mail-pl1-x629.google.com [IPv6:2607:f8b0:4864:20::629]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5DE4A1BD2 for ; Mon, 31 Jul 2023 09:35:21 -0700 (PDT) Received: by mail-pl1-x629.google.com with SMTP id d9443c01a7336-1bba48b0bd2so29472865ad.3 for ; Mon, 31 Jul 2023 09:35:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1690821320; x=1691426120; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=0fZoRzqsVsl2DrqFfH7FNxDnDstpZGeIPe8SX7WYfkY=; b=apDEw9guhDGR1m7e1txjCAEYGfIwqTYB4bhVZlXDoTvkw8YSH2H+pkHwbPdY+APTsx rJioXo+74YcllhyJuKU6YGL7X+g2zzk+XWT/pR5pjDMUCjRng/vWiZvYgNxntlua/eW1 wfvjDYqJWyDlYyMHN6aNZujeIHNFaYULQQagg/wsrgoX70i92T6L8oBhL7mGnDUt1/Sn xNAQJZBuDTAVTkfvx83O6Md02Iz4OxRwpG/ituEEmnwtWSLZ81TWJMx0LLtNuZr6s80/ kYES5bwflQmjzF7sr7CUwUhbNHd5F3xltkfYoz6WF+BZ6+9cj3NffYlrXY3C4jipcxo0 n8Ng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690821320; x=1691426120; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=0fZoRzqsVsl2DrqFfH7FNxDnDstpZGeIPe8SX7WYfkY=; b=EvTRxvJm2fnWmJ/uL/Vu2KJ4HnUJOkZ8Dk4CnIOQdO25lNbYk0Ef4MHUHd9fXXhLeg gzONM7tkXB9RSm1DdRR4LnATO7Sf/0BCkkGQ1pEuTN7JMrS6kkvMRhnljROIPYSOqc5U nAyqxZkx3hlpUHw7r254WoVuhuqZtuIdd+7GU/EH1C2a15MmZmlP0zI0nzqaLYmIAEfA P3w5PQ5XKb9GqmTDeCdWjGWw6nxwQjFhzcZQpO71JBVqRBtiEF/wLUypRQ7xPvYKtwKS and9q+TQjdcWRi8KEAA2CDAw+pFEsmtJ77xHhxwLTcdcvMmlqRgMlGStCE22L0SfPdTO sTNA== X-Gm-Message-State: ABy/qLbl0RCe8keOk7uBYdRtI1wXOnAgDnP5fF1HRIx7OFbCAOOrE+FD h5TW+5+epsqM+vhHnA+PizCq X-Received: by 2002:a17:902:854b:b0:1bc:13d0:7219 with SMTP id d11-20020a170902854b00b001bc13d07219mr2783802plo.41.1690821320721; Mon, 31 Jul 2023 09:35:20 -0700 (PDT) Received: from localhost.localdomain ([117.193.209.129]) by smtp.gmail.com with ESMTPSA id w8-20020a170902e88800b001bb1f09189bsm8779541plg.221.2023.07.31.09.35.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 31 Jul 2023 09:35:20 -0700 (PDT) From: Manivannan Sadhasivam To: vireshk@kernel.org, nm@ti.com, sboyd@kernel.org, myungjoo.ham@samsung.com, kyungmin.park@samsung.com, cw00.choi@samsung.com, andersson@kernel.org, konrad.dybcio@linaro.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, jejb@linux.ibm.com, martin.petersen@oracle.com Cc: alim.akhtar@samsung.com, avri.altman@wdc.com, bvanassche@acm.org, linux-scsi@vger.kernel.org, linux-pm@vger.kernel.org, linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, quic_asutoshd@quicinc.com, quic_cang@quicinc.com, quic_nitirawa@quicinc.com, quic_narepall@quicinc.com, quic_bhaskarv@quicinc.com, quic_richardp@quicinc.com, quic_nguyenb@quicinc.com, quic_ziqichen@quicinc.com, bmasney@redhat.com, krzysztof.kozlowski@linaro.org, linux-kernel@vger.kernel.org, Manivannan Sadhasivam Subject: [PATCH v3 5/6] arm64: dts: qcom: sdm845: Add OPP table support to UFSHC Date: Mon, 31 Jul 2023 22:03:56 +0530 Message-Id: <20230731163357.49045-6-manivannan.sadhasivam@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230731163357.49045-1-manivannan.sadhasivam@linaro.org> References: <20230731163357.49045-1-manivannan.sadhasivam@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Krzysztof Kozlowski UFS host controller, when scaling gears, should choose appropriate performance state of RPMh power domain controller along with clock frequency. So let's add the OPP table support to specify both clock frequency and RPMh performance states replacing the old "freq-table-hz" property. Signed-off-by: Krzysztof Kozlowski [mani: Splitted pd change and used rpmhpd_opp_low_svs] Signed-off-by: Manivannan Sadhasivam --- arch/arm64/boot/dts/qcom/sdm845.dtsi | 42 +++++++++++++++++++++------- 1 file changed, 32 insertions(+), 10 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi index 055ca80c0075..2ea6eb44953e 100644 --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi @@ -2605,22 +2605,44 @@ ufs_mem_hc: ufshc@1d84000 { <&gcc GCC_UFS_PHY_RX_SYMBOL_0_CLK>, <&gcc GCC_UFS_PHY_RX_SYMBOL_1_CLK>, <&gcc GCC_UFS_PHY_ICE_CORE_CLK>; - freq-table-hz = - <50000000 200000000>, - <0 0>, - <0 0>, - <37500000 150000000>, - <0 0>, - <0 0>, - <0 0>, - <0 0>, - <75000000 300000000>; + + operating-points-v2 = <&ufs_opp_table>; interconnects = <&aggre1_noc MASTER_UFS_MEM 0 &mem_noc SLAVE_EBI1 0>, <&gladiator_noc MASTER_APPSS_PROC 0 &config_noc SLAVE_UFS_MEM_CFG 0>; interconnect-names = "ufs-ddr", "cpu-ufs"; status = "disabled"; + + ufs_opp_table: opp-table { + compatible = "operating-points-v2"; + + opp-50000000 { + opp-hz = /bits/ 64 <50000000>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <37500000>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <75000000>; + required-opps = <&rpmhpd_opp_low_svs>; + }; + + opp-200000000 { + opp-hz = /bits/ 64 <200000000>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <150000000>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <300000000>; + required-opps = <&rpmhpd_opp_nom>; + }; + }; }; ufs_mem_phy: phy@1d87000 { -- 2.25.1