From patchwork Thu Aug 25 16:42:00 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Doug Anderson X-Patchwork-Id: 12955076 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 50D01ECAA25 for ; Thu, 25 Aug 2022 16:43:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231594AbiHYQnV (ORCPT ); Thu, 25 Aug 2022 12:43:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43530 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233141AbiHYQnD (ORCPT ); Thu, 25 Aug 2022 12:43:03 -0400 Received: from mail-pj1-x102d.google.com (mail-pj1-x102d.google.com [IPv6:2607:f8b0:4864:20::102d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F3B04BB92C for ; Thu, 25 Aug 2022 09:42:35 -0700 (PDT) Received: by mail-pj1-x102d.google.com with SMTP id t5so1739615pjs.0 for ; Thu, 25 Aug 2022 09:42:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc; bh=e/fD7sKxnTMTED8wIUFpATFsGKD6ybPH9oG2WPNRWok=; b=ltchGKz8TzyNo0cZcFPvC2GBTH9V9f+1y1mjExbH8r1jZCj+Nx0pOjOD1k81FWocER DOMGax9JdqjwayYbU9wBTXo9xnYVv3315yF3troEEiIHEG3A1Qp/C6zeDEJn3/AOTwkY OVWn3oUfs/zfPIKdARPwQDXxuJkB+Qf8fV8fM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc; bh=e/fD7sKxnTMTED8wIUFpATFsGKD6ybPH9oG2WPNRWok=; b=IsOMS5vgtTWUrnsWrO0s6V8QhTwW6l498YVp490j72OSkr56lNqtvCPqrH/CmLpBLf RZcIVJn+zRJ5BS1kFCTt5gXJmOogZ1hqPgBXlDXvk9OhO4k/k8I73skGZgHhQY96IkyM SgLWc4IqF73/yLqsDui9fsBtBRXJxPensXw9GOGYoNtBaZsZPs0a6oLUCf/QA+z187qM eedDinFOqenKhFLwxLySts5DSliC1A62pdLYy+JXS5/GgLqLUbajAPf4elz0G+/TPjT7 fTC3UONIvn7GNgEZ+Ye/An0ashKxOuoBgQ3N3TGI2l/vPS/6WljYp3XTDtmX20KnlTgQ VxNQ== X-Gm-Message-State: ACgBeo0UeRJ7K4dCBsME1b7IvxpQPOrEoxwr+qFBzTqcQB4fzy2uLQIq k1CFBhS3iVuRGzRhyBtGcDIJDA== X-Google-Smtp-Source: AA6agR7eGfeqQGJzsdcwY0kKSKRwuBqDU7PrLa/tRF93qIGxFFnclul+YZxqN2K0cOcynGFvY2M+vg== X-Received: by 2002:a17:902:e851:b0:172:dda3:77d3 with SMTP id t17-20020a170902e85100b00172dda377d3mr4482458plg.19.1661445754631; Thu, 25 Aug 2022 09:42:34 -0700 (PDT) Received: from tictac2.mtv.corp.google.com ([2620:15c:202:201:b7f2:d739:e847:6e53]) by smtp.gmail.com with ESMTPSA id y13-20020a17090a154d00b001f2ef3c7956sm3775799pja.25.2022.08.25.09.42.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Aug 2022 09:42:33 -0700 (PDT) From: Douglas Anderson To: Bjorn Andersson Cc: Andrew Halaney , Mark Brown , Douglas Anderson , Andy Gross , Johan Hovold , Konrad Dybcio , Krzysztof Kozlowski , Rob Herring , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/7] arm64: dts: qcom: sa8295p-adp: Specify which LDO modes are allowed Date: Thu, 25 Aug 2022 09:42:00 -0700 Message-Id: <20220825094155.2.I430a56702ab0af65244e62667bb7743107de0c96@changeid> X-Mailer: git-send-email 2.37.2.672.g94769d06f0-goog In-Reply-To: <20220825164205.4060647-1-dianders@chromium.org> References: <20220825164205.4060647-1-dianders@chromium.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org This board uses RPMH, specifies "regulator-allow-set-load" for LDOs, but doesn't specify any modes with "regulator-allowed-modes". Prior to commit efb0cb50c427 ("regulator: qcom-rpmh: Implement get_optimum_mode(), not set_load()") the above meant that we were able to set either LPM or HPM mode. After that commit (and fixes [1]) we'll be stuck at the initial mode. Discussion of this has resulted in the decision that the old dts files were wrong and should be fixed to fully restore old functionality. Let's re-enable the old functionality by fixing the dts. [1] https://lore.kernel.org/r/20220824142229.RFT.v2.2.I6f77860e5cd98bf5c67208fa9edda4a08847c304@changeid Fixes: 519183af39b2 ("arm64: dts: qcom: add SA8540P and ADP") Signed-off-by: Douglas Anderson Reviewed-by: Andrew Halaney Reviewed-by: Konrad Dybcio --- arch/arm64/boot/dts/qcom/sa8295p-adp.dts | 45 ++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sa8295p-adp.dts b/arch/arm64/boot/dts/qcom/sa8295p-adp.dts index 9398f0349944..6d05cb54e32f 100644 --- a/arch/arm64/boot/dts/qcom/sa8295p-adp.dts +++ b/arch/arm64/boot/dts/qcom/sa8295p-adp.dts @@ -36,6 +36,9 @@ vreg_l3a: ldo3 { regulator-max-microvolt = <1208000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l5a: ldo5 { @@ -44,6 +47,9 @@ vreg_l5a: ldo5 { regulator-max-microvolt = <912000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l7a: ldo7 { @@ -52,6 +58,9 @@ vreg_l7a: ldo7 { regulator-max-microvolt = <1800000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l13a: ldo13 { @@ -60,6 +69,9 @@ vreg_l13a: ldo13 { regulator-max-microvolt = <3072000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; }; @@ -73,6 +85,9 @@ vreg_l1c: ldo1 { regulator-max-microvolt = <912000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l2c: ldo2 { @@ -81,6 +96,9 @@ vreg_l2c: ldo2 { regulator-max-microvolt = <3072000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l3c: ldo3 { @@ -89,6 +107,9 @@ vreg_l3c: ldo3 { regulator-max-microvolt = <1200000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l4c: ldo4 { @@ -97,6 +118,9 @@ vreg_l4c: ldo4 { regulator-max-microvolt = <1208000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l6c: ldo6 { @@ -105,6 +129,9 @@ vreg_l6c: ldo6 { regulator-max-microvolt = <1200000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l7c: ldo7 { @@ -113,6 +140,9 @@ vreg_l7c: ldo7 { regulator-max-microvolt = <1800000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l10c: ldo10 { @@ -121,6 +151,9 @@ vreg_l10c: ldo10 { regulator-max-microvolt = <2504000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l17c: ldo17 { @@ -129,6 +162,9 @@ vreg_l17c: ldo17 { regulator-max-microvolt = <2504000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; }; @@ -142,6 +178,9 @@ vreg_l3g: ldo3 { regulator-max-microvolt = <1200000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l7g: ldo7 { @@ -150,6 +189,9 @@ vreg_l7g: ldo7 { regulator-max-microvolt = <1800000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; vreg_l8g: ldo8 { @@ -158,6 +200,9 @@ vreg_l8g: ldo8 { regulator-max-microvolt = <880000>; regulator-initial-mode = ; regulator-allow-set-load; + regulator-allowed-modes = + ; }; }; };