Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp92333rdg; Wed, 11 Oct 2023 22:46:58 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEJId4a1N1WsCgw5VNk39k945zowhQmDjUeBnBwXxBKEFBBU/bUfwiRIsgrJBLCFOVUJ1NF X-Received: by 2002:a17:90a:1e:b0:27d:10ab:2329 with SMTP id 30-20020a17090a001e00b0027d10ab2329mr2742823pja.14.1697089618256; Wed, 11 Oct 2023 22:46:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697089618; cv=none; d=google.com; s=arc-20160816; b=xU4USmn82nRW8hhewci+UkIFPOPIU7w+i+I7pZnd3qgyoguB8D9P8o+BQ5L87f+yDc 2oUCrAyfsfToE3A9/GFILLGQc50bZaPy6VbMtu9lIsyGRBdmvhYWH+ouiWsBmMBvrGqY QyTazBL5jpVUCQsTeDZ472kq2hM3gVYkxunUBwmw1V4rfvN2AkOcQItsIO+oxv++ocQg 3h6vCX+o6yUnexifdaLp+DUwQZX61C2lRQ3l2iljjNo1UdwG05Lk/BBeWaO7vzxg177N +o2KA1YPOgwoI/+/PWmJ37CWw/rTr10zi+amHU+ZDPHnm6coqYUvDif8oxusm0uY4t1b 1igg== 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=HMmysdE7+hFUIPmp9MMMe3xjxP9qrN7IYcx3e2tg+gE=; fh=TvNASacexa2bOmmJR5GW096pcxr3BrqiN2/FCAYREuU=; b=aHoFXBOc4l8tKDCRVbamwXEZH1xtNOqjR6S4v0e3WAbjfUozZD6S84QC3hM8L8mUxM p4nZaTacP+tHFqaQLH6wGogJc+AsdlgV3ecstKR2IG/efTeuAxDxRvapl8AZZSlFQ1tV 84zmN0dpD+7PGTmM8+IWHFT3exG2T2y4yY+6ecoLX98igE2pMCd6LKTV8ulUKvNtoIac Yl9CFSc9+QtBjFzAB9++dq/liALVOSWcZjIaqLcri1h1x9Ztn4t2ohg1nxWThzxuGlJM GYeyYlk87gHLzbnN/RACAyvF/Rv2v6YmxwGyqrzjILFjv51D4FNMW+N7KTcVCPOMI3uv 1vDw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=q2rFxBiC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 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 lipwig.vger.email (lipwig.vger.email. [2620:137:e000::3:3]) by mx.google.com with ESMTPS id k1-20020a170902c40100b001ab29e00303si1568687plk.426.2023.10.11.22.46.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 11 Oct 2023 22:46:58 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) client-ip=2620:137:e000::3:3; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=q2rFxBiC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id B7E52819CC17; Wed, 11 Oct 2023 22:46:55 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377538AbjJLFqh (ORCPT + 99 others); Thu, 12 Oct 2023 01:46:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40616 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235354AbjJLFqS (ORCPT ); Thu, 12 Oct 2023 01:46:18 -0400 Received: from mail-oi1-x231.google.com (mail-oi1-x231.google.com [IPv6:2607:f8b0:4864:20::231]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AFE8D193 for ; Wed, 11 Oct 2023 22:46:05 -0700 (PDT) Received: by mail-oi1-x231.google.com with SMTP id 5614622812f47-3ae65e8eb45so352103b6e.1 for ; Wed, 11 Oct 2023 22:46:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1697089565; x=1697694365; darn=vger.kernel.org; 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=HMmysdE7+hFUIPmp9MMMe3xjxP9qrN7IYcx3e2tg+gE=; b=q2rFxBiC7dVO+AIBAj1om5KfTI5rAPzoQQXsgvhloFK1EqyUUOezeB9hBK9mXj1ZqD 0Nhs8xp3w5eX2hQKN9PAI/T5yW/Fikz9U4QHrZz6ILgxOu8+Wh6g5nqT+RQv/Yl57AbD 15ApKQHLcAeE3XC1kfwEaiYxyO4diEbXXcXpk9EADb6gCP66bHaVyqo/lclR0dxM+Fpm 5+o8C3dM3mC6jUZZOCI90CTr9+mmmW4Art/sFyz8V0Nk7CbUTi6tyVmovmnsDfgpllw1 iW1B2How1TbJ15CmSjYLzwR36T1bMJn6uWbDpK7XlWiQDUu5eo9pDtktYlqZIas3/kZn MjMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697089565; x=1697694365; 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=HMmysdE7+hFUIPmp9MMMe3xjxP9qrN7IYcx3e2tg+gE=; b=HcxuqIS7hbfNNrHFacfrsvMXwiPKf0MeAhPNo+fyTmuDSe42XyQNhYB6qHEzvDfinp /BSMdiDGQa07sUgjBlyQqu/rPTNM2oHfnvB8DulJ/OtgBTcfu5vgVi0TV7wXe2vTl6wG joE1tLg+Aehbf5d2MTmCO2nWoXcl4JwG/3kX+ccV3LMFCAhvDNnKT93Xj001qXgyWNQ6 dN8UFjMzUXYHbakMXIy/+rRS+SATi9uMSdwsiakeRGSA+uWJMmfeD9QdsB8NUIscJAWq rvSeMoDD58ho1r0F36iamYM2z/rZrjArbURzjkO2DrdEPg9UCIZxWzWX2EFJzRXitot1 3FCQ== X-Gm-Message-State: AOJu0Yy5+TRrFCQ+dnDHYoqf7hcImr5vSbGY9jT1RcrlwhA+9LCC0lW1 ve84lZY3U6glN6O+Qziq1RWu X-Received: by 2002:a05:6808:1441:b0:3af:583d:3c5d with SMTP id x1-20020a056808144100b003af583d3c5dmr30255565oiv.52.1697089564929; Wed, 11 Oct 2023 22:46:04 -0700 (PDT) Received: from localhost.localdomain ([120.138.12.180]) by smtp.gmail.com with ESMTPSA id c5-20020a633505000000b0057cb5a780ebsm812396pga.76.2023.10.11.22.45.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 11 Oct 2023 22:46:04 -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 , Dmitry Baryshkov Subject: [PATCH v6 5/5] arm64: dts: qcom: sm8250: Add OPP table support to UFSHC Date: Thu, 12 Oct 2023 11:15:12 +0530 Message-Id: <20231012054512.10963-6-manivannan.sadhasivam@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20231012054512.10963-1-manivannan.sadhasivam@linaro.org> References: <20231012054512.10963-1-manivannan.sadhasivam@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Wed, 11 Oct 2023 22:46:55 -0700 (PDT) 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. Reviewed-by: Dmitry Baryshkov Signed-off-by: Manivannan Sadhasivam --- arch/arm64/boot/dts/qcom/sm8250.dtsi | 39 +++++++++++++++++++++------- 1 file changed, 30 insertions(+), 9 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sm8250.dtsi b/arch/arm64/boot/dts/qcom/sm8250.dtsi index a4e58ad731c3..33abd84aae53 100644 --- a/arch/arm64/boot/dts/qcom/sm8250.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8250.dtsi @@ -2198,21 +2198,42 @@ ufs_mem_hc: ufshc@1d84000 { <&gcc GCC_UFS_PHY_TX_SYMBOL_0_CLK>, <&gcc GCC_UFS_PHY_RX_SYMBOL_0_CLK>, <&gcc GCC_UFS_PHY_RX_SYMBOL_1_CLK>; - freq-table-hz = - <37500000 300000000>, - <0 0>, - <0 0>, - <37500000 300000000>, - <0 0>, - <0 0>, - <0 0>, - <0 0>; + + operating-points-v2 = <&ufs_opp_table>; interconnects = <&aggre1_noc MASTER_UFS_MEM 0 &mc_virt SLAVE_EBI_CH0 0>, <&gem_noc MASTER_AMPSS_M0 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-37500000 { + opp-hz = /bits/ 64 <37500000>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <37500000>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <0>; + required-opps = <&rpmhpd_opp_low_svs>; + }; + + opp-300000000 { + opp-hz = /bits/ 64 <300000000>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <300000000>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <0>, + /bits/ 64 <0>; + required-opps = <&rpmhpd_opp_nom>; + }; + }; }; ufs_mem_phy: phy@1d87000 { -- 2.25.1