From patchwork Fri May 13 06:13:40 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 572479 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id AF126C433F5 for ; Fri, 13 May 2022 06:14:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377225AbiEMGOU (ORCPT ); Fri, 13 May 2022 02:14:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48204 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377196AbiEMGOO (ORCPT ); Fri, 13 May 2022 02:14:14 -0400 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 59EE826FA14 for ; Thu, 12 May 2022 23:14:11 -0700 (PDT) Received: by mail-wm1-x336.google.com with SMTP id k126-20020a1ca184000000b003943fd07180so4158703wme.3 for ; Thu, 12 May 2022 23:14:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=uAJqhZC1C/Q9FHKuHNivRCwHP2aLTusrcVUMg5OeoKQ=; b=pZngk5SldFVYgLXXBUjf0GnPLvqAwiuSj5OAwlHA/Uxop92U+gROcpDiOQyfUuKnFw KbgJnN7J55/tJMwkSCFuRws/4gbAvRxvUu8liqkyvPsMl15NtCNkftbBtlhimy1bV0X+ i0K0JzbRIzik9Xqp93oD7s1lz3p7emwy6ZYeysit21s3N+1+eRzORU6c2bSldwf8VrJJ 8QuNlBFUejvRkavEs+Hsxh3WnY097JhjmuzSPH4vLx3EDvd95ESyOiY6LuqlJerFQXJN mJUz2934SH6RwTS3GSKaQENADo94uF9B7WtrIB3jPzdntgoPx/Mr1hJgsVykZk847+VP SI6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=uAJqhZC1C/Q9FHKuHNivRCwHP2aLTusrcVUMg5OeoKQ=; b=gj8G6Ohk7IrvopaVaeC9JBTLxdZePauDluwaWrQjHqn2Jpqn3PkNVPT/ANDGfeTy9J /6rRPd9kspJlAYBHDyKkAZ+0DoSIgUB75zvrIs+gsviAk+iJSu4SVgzOQlzDlXXUY1Q0 OBSc5F9RDt3+8mgVVy3FHgfOiOqLZNfAAxGfCLQ0A6nSXJLbRjD2+5bkxlmqNLNInS7B VXznWJ//C9Ro0vMDuzixVl1zlZkzgH1oY+g4FssXARVDrkAcPvv52/pAYP78Pp+15fmQ JBY7RcDmc9c40ls00uLLI7PP+1ZGSAYKIkUJrl4iK1VtTdUszrX0llgLqrmsdELqbS2D WRTA== X-Gm-Message-State: AOAM531xmmWcdRu/3F/42hpMaYOoZMBtJVIdjhQC07wR8vw7Z4vP63A2 lAtW9IvSy268iSbXhvsE4dDznA== X-Google-Smtp-Source: ABdhPJxSoqFZu5xWQFZQMJH5obw3FV3uE+uXkptGPzvYlWeY5QI75GpqhfaoLqhsUfXF3WXIIQ9wjQ== X-Received: by 2002:a7b:cbc2:0:b0:388:faec:2036 with SMTP id n2-20020a7bcbc2000000b00388faec2036mr3031170wmi.190.1652422449908; Thu, 12 May 2022 23:14:09 -0700 (PDT) Received: from localhost.localdomain (xdsl-188-155-176-92.adslplus.ch. [188.155.176.92]) by smtp.gmail.com with ESMTPSA id g4-20020adfbc84000000b0020c5253d8f3sm1477760wrh.63.2022.05.12.23.14.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 12 May 2022 23:14:09 -0700 (PDT) From: Krzysztof Kozlowski To: Andy Gross , Bjorn Andersson , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Viresh Kumar , Nishanth Menon , Alim Akhtar , Avri Altman , "James E.J. Bottomley" , "Martin K. Petersen" , "Rafael J. Wysocki" , Taniya Das , linux-arm-msm@vger.kernel.org, linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, linux-scsi@vger.kernel.org Cc: Krzysztof Kozlowski , Manivannan Sadhasivam Subject: [PATCH v3 0/7] ufs: set power domain performance state when scaling gears Date: Fri, 13 May 2022 08:13:40 +0200 Message-Id: <20220513061347.46480-1-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.32.0 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org Hi, Changes since v2 ================ 1. PM: Split PM OPP patch into two - getting clocks and rates. (Viresh) 2. PM: Do not set clock rates from PM OPPs but rely on set_opp helper. (Viresh) 3. PM: Use clk bulk operations in PM OPP for getting/releasing the clocks. (Bjorn) 4. UFS: Rework clock scalling to be called in the same place as old method, so pre/post changes notification will work. (Mani) 5. UFS: Bail out if both freq-table-hz and operating-points are provided. (Mani) 6. Add review tags. Changes since v1 ================ 1. Patch #1 qcom,gcc-sdm845: fix typo (Stephen). 2. Patch #2 ufs dt-bindings: not adding Rob's review because patch changed significantly. 3. PM: add new code for handling multiple clocks. 4. UFS: deprecate freq-table-hz property and use PM opps instead. Dependencies ============ The UFS patch depends on PM OPP patches adding multiple clocks/rates support. Best regards, Krzysztof Cc: Manivannan Sadhasivam Krzysztof Kozlowski (7): dt-bindings: clock: qcom,gcc-sdm845: add parent power domain dt-bindings: opp: accept array of frequencies dt-bindings: ufs: common: add OPP table arm64: dts: qcom: sdm845: control RPMHPD performance states with UFS PM: opp: allow control of multiple clocks PM: opp: parse multiple frequencies in each OPP ufs: use PM OPP when scaling gears .../bindings/clock/qcom,gcc-sdm845.yaml | 3 + .../devicetree/bindings/opp/opp-v2-base.yaml | 10 + .../devicetree/bindings/ufs/ufs-common.yaml | 34 ++- arch/arm64/boot/dts/qcom/sdm845.dtsi | 43 +++- drivers/opp/core.c | 207 +++++++++++++----- drivers/opp/of.c | 47 ++++ drivers/opp/opp.h | 9 +- drivers/opp/ti-opp-supply.c | 6 +- drivers/scsi/ufs/ufshcd-pltfrm.c | 73 ++++++ drivers/scsi/ufs/ufshcd.c | 150 ++++++++++--- drivers/scsi/ufs/ufshcd.h | 6 + include/linux/pm_opp.h | 32 ++- 12 files changed, 518 insertions(+), 102 deletions(-) Reviewed-by: Manivannan Sadhasivam