Message ID | 20230413131705.3073911-2-brgl@bgdev.pl |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1030966vqo; Thu, 13 Apr 2023 06:22:13 -0700 (PDT) X-Google-Smtp-Source: AKy350b7omkWu0PVR2SlVa1j313FKmAojNLh50LpBe9QDBLMpyPpZ7auTw6AqXnjruvoKGxxzrc9 X-Received: by 2002:a05:6808:6c5:b0:38b:5349:e112 with SMTP id m5-20020a05680806c500b0038b5349e112mr401083oih.46.1681392132751; Thu, 13 Apr 2023 06:22:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681392132; cv=none; d=google.com; s=arc-20160816; b=v0Glmy+1BPSd+FlIjOMWgWgd5GRQyY4KitsTJExrSLxF2eVHNtFS5+IhDv5v+GOqIo kfVYc9qCUG0gt3ORqqXq+8NTpP+MTi/w58xmQ3ShK/wG/AFkGhmq64uWxyXPbqFtQoeE opq7Y9xtImSlejfdn9HQcNFhtYQsBKpIh8ARHkpQKSBPPZ6gkUX42q+6xcrKMa20hRUQ 7fz7om3x3d1a72vmmuE8syvmtmdZkY49Bs7fRtJg75oxTpjrIF/Rp1MG47SNiegaTMAV Ipoe+CpNbiJe0L/p+HgF6CsQESpFRGkFosslpYBikiw3z3JX/e4lixCnIbcQupPrJZqc acTg== 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=aESHnUR1O/61n5/lfPsi3I+Fy8BChJQIQxTnoiWBoZM=; b=I7HttWKh5I1ErsUmTQ0nWACmgXeDamQUAUJPYxMe3wAPqYCAmb2zGbvGKTd5VE19i9 Kn1KQbcE6eqe3tFR/iWJ7boRBmI4DPybdx2UzKx7OBv6nijexjmANP6QUGPa199JGtYQ r+VYCe0O93ZKryOGOmAP5S83DMO1Y64wLmcZTlVvhogmaDr5vjSSkGXbIExLS11uctfF YySPXVn+0w8j1DnqVAHG475jW8ZVAFp36ff5GMSIfC3TZEnp+h2mWFLtQT6X7RpdQckA Fab9XOQGK+iNOXT3sPCyHLqBpO+ZtflDGitbDQ/3UOpOPf24SVZc8O1VSp6J6yDOUqB5 Vk4A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bgdev-pl.20221208.gappssmtp.com header.s=20221208 header.b=NPDKRqRh; 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c13-20020aca1c0d000000b0038b5a6e061bsi1559267oic.215.2023.04.13.06.21.59; Thu, 13 Apr 2023 06:22:12 -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=@bgdev-pl.20221208.gappssmtp.com header.s=20221208 header.b=NPDKRqRh; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230520AbjDMNRY (ORCPT <rfc822;peter110.wang@gmail.com> + 99 others); Thu, 13 Apr 2023 09:17:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46670 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230392AbjDMNRV (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 13 Apr 2023 09:17:21 -0400 Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1AE16194 for <linux-kernel@vger.kernel.org>; Thu, 13 Apr 2023 06:17:19 -0700 (PDT) Received: by mail-wm1-x334.google.com with SMTP id hg25-20020a05600c539900b003f05a99a841so15947164wmb.3 for <linux-kernel@vger.kernel.org>; Thu, 13 Apr 2023 06:17:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20221208.gappssmtp.com; s=20221208; t=1681391837; x=1683983837; 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=aESHnUR1O/61n5/lfPsi3I+Fy8BChJQIQxTnoiWBoZM=; b=NPDKRqRhXu9gB7ad0+HipO+LO7EdyiPdFBX+cbn+ldIWVtVPPCcFpHknPNruo3Ieh8 8jDqsJFjadsfs1LNgvOtQGADuxSTFi75F70ITZ1dh3zd6WvL1bCQIAH88bqfvzsCG5CW N/7uV3cxhXayOT7o225y4swYx/6OnLovSNig3tRePA9Bry8EVc59XaKjpeWQQgrWUWAC JREEs84Lh0H8EYlccci+RqxNyDumE/veGS6XuRwDAgT7mlf55btS9Jhw+l8TnnYjK0xb w2VUds0UzqLNlmWJwEmUzDLhNicsRolmmeKucRXMF+uONI/6xJwi/nf5EZWA5UdQSimO 1lGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681391837; x=1683983837; 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=aESHnUR1O/61n5/lfPsi3I+Fy8BChJQIQxTnoiWBoZM=; b=Y1cj6FrF/hNrBROjVevdcBRz0mEOrXR//msYRiehAxGoj6U1EYdsuopfoksRF5AcHJ HZp+ewqqwhJ/SD+Ux1iffmY+5PfLFB74Cx9e4risil1NIb7FgOLoITMp7RTAE7I3g2G+ bRP0YIg9pNEO/CfaVUM11aN6z/+wddWOYsmt0vOZUApaLV84TbwIsWUUSqQz0LI9YlxR V57szVTPSZkvtj9x4TTrtkho3DATD6nyJTjOdkWLRWCRO9i+xwszQRoVCnbXRzCagDjl a3e6ELwU9SMwvW/7ti5McmJMKDN6Gs/ZQbDTw6lKKjDao1EC+g+kZaxNg0BKQf9d6kUZ Ebww== X-Gm-Message-State: AAQBX9doez0JFQ8XqF/qvtie5gdQCZa0YBzNwfpVCuG/8GXoks3zNLcJ DPXkcK66vsxyFb2Jwn9P3LNMKw== X-Received: by 2002:a7b:c7cd:0:b0:3ed:a82d:dffb with SMTP id z13-20020a7bc7cd000000b003eda82ddffbmr1778585wmk.40.1681391837607; Thu, 13 Apr 2023 06:17:17 -0700 (PDT) Received: from brgl-uxlite.home ([2a01:cb1d:334:ac00:814c:fc8a:da02:39ad]) by smtp.gmail.com with ESMTPSA id v3-20020a1cf703000000b003f04646838esm1796400wmh.39.2023.04.13.06.17.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Apr 2023 06:17:17 -0700 (PDT) From: Bartosz Golaszewski <brgl@bgdev.pl> To: Sebastian Reichel <sre@kernel.org>, Rob Herring <robh+dt@kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Andy Gross <agross@kernel.org>, Bjorn Andersson <andersson@kernel.org>, Konrad Dybcio <konrad.dybcio@linaro.org>, Catalin Marinas <catalin.marinas@arm.com>, Will Deacon <will@kernel.org>, Arnd Bergmann <arnd@arndb.de> Cc: linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Parikshit Pareek <quic_ppareek@quicinc.com>, Bartosz Golaszewski <bartosz.golaszewski@linaro.org> Subject: [PATCH 1/4] arm64: dts: qcom: sa8775p: pmic: remove the PON modes Date: Thu, 13 Apr 2023 15:17:02 +0200 Message-Id: <20230413131705.3073911-2-brgl@bgdev.pl> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20230413131705.3073911-1-brgl@bgdev.pl> References: <20230413131705.3073911-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_NONE 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1763067437275857324?= X-GMAIL-MSGID: =?utf-8?q?1763067437275857324?= |
Series |
arm64: qcom: fix the reboot reason handling on sa8775p
|
|
Commit Message
Bartosz Golaszewski
April 13, 2023, 1:17 p.m. UTC
From: Parikshit Pareek <quic_ppareek@quicinc.com> Remove the power on reasons with reboot from the pmm8654au_0_pon. Instead, the PoN reaons should be part of different sdam_0 mode, to be interoduced. Signed-off-by: Parikshit Pareek <quic_ppareek@quicinc.com> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> --- arch/arm64/boot/dts/qcom/sa8775p-pmics.dtsi | 2 -- 1 file changed, 2 deletions(-)
Comments
On 13/04/2023 15:17, Bartosz Golaszewski wrote: > From: Parikshit Pareek <quic_ppareek@quicinc.com> > > Remove the power on reasons with reboot from the pmm8654au_0_pon. > Instead, the PoN reaons should be part of different sdam_0 mode, to typo: reasons > be interoduced. introduced Anyway it does not say why. Are these power reasons not correct? > > Signed-off-by: Parikshit Pareek <quic_ppareek@quicinc.com> > Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> > --- Best regards, Krzysztof
On 4/13/2023 9:42 PM, Krzysztof Kozlowski wrote: > On 13/04/2023 15:17, Bartosz Golaszewski wrote: >> From: Parikshit Pareek <quic_ppareek@quicinc.com> >> >> Remove the power on reasons with reboot from the pmm8654au_0_pon. >> Instead, the PoN reaons should be part of different sdam_0 mode, to > > typo: reasons > >> be interoduced. > > introduced > > Anyway it does not say why. Are these power reasons not correct? > Hi Krzysztof, Since sm8350 the PMIC PON peripheral was split into PON_HLOS and PON_PBS to avoid security concerns with HLOS APPS being able to trigger a PMIC WARM_RESET unilaterally. When the split occurred, the spare registers ended up in PON_PBS, not PON_HLOS. Thus at that time, we moved to using an SDAM register for Linux “reboot reason” configuration. And bootloader also SDAM register to get these reboot region data to get into bootloader/edl, so to have this working we need to use SDAM. >> >> Signed-off-by: Parikshit Pareek <quic_ppareek@quicinc.com> >> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> >> --- > > Best regards, > Krzysztof > -Shazad
On 18/04/2023 06:39, Shazad Hussain wrote: > > > On 4/13/2023 9:42 PM, Krzysztof Kozlowski wrote: >> On 13/04/2023 15:17, Bartosz Golaszewski wrote: >>> From: Parikshit Pareek <quic_ppareek@quicinc.com> >>> >>> Remove the power on reasons with reboot from the pmm8654au_0_pon. >>> Instead, the PoN reaons should be part of different sdam_0 mode, to >> >> typo: reasons >> >>> be interoduced. >> >> introduced >> >> Anyway it does not say why. Are these power reasons not correct? >> > > Hi Krzysztof, > Since sm8350 the PMIC PON peripheral was split into PON_HLOS and PON_PBS > to avoid security concerns with HLOS APPS being able to trigger a PMIC > WARM_RESET unilaterally. When the split occurred, the spare registers > ended up in PON_PBS, not PON_HLOS. Thus at that time, we moved to using > an SDAM register for Linux “reboot reason” configuration. And bootloader > also SDAM register to get these reboot region data to get into > bootloader/edl, so to have this working we need to use SDAM. The explanation of their correctness should be in commit msg. Best regards, Krzysztof
On 18.04.2023 06:39, Shazad Hussain wrote: > > > On 4/13/2023 9:42 PM, Krzysztof Kozlowski wrote: >> On 13/04/2023 15:17, Bartosz Golaszewski wrote: >>> From: Parikshit Pareek <quic_ppareek@quicinc.com> >>> >>> Remove the power on reasons with reboot from the pmm8654au_0_pon. >>> Instead, the PoN reaons should be part of different sdam_0 mode, to >> >> typo: reasons >> >>> be interoduced. >> >> introduced >> >> Anyway it does not say why. Are these power reasons not correct? >> > > Hi Krzysztof, > Since sm8350 the PMIC PON peripheral was split into PON_HLOS and PON_PBS > to avoid security concerns with HLOS APPS being able to trigger a PMIC > WARM_RESET unilaterally. When the split occurred, the spare registers > ended up in PON_PBS, not PON_HLOS. Thus at that time, we moved to using > an SDAM register for Linux “reboot reason” configuration. And bootloader > also SDAM register to get these reboot region data to get into > bootloader/edl, so to have this working we need to use SDAM. > Does that imply all PMICs following the PMK8350 scheme (separate HLOS and PBS) should direct reboot mode writes to SDAM? Konrad >>> >>> Signed-off-by: Parikshit Pareek <quic_ppareek@quicinc.com> >>> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> >>> --- >> >> Best regards, >> Krzysztof >> > > -Shazad
On 4/18/2023 3:13 PM, Konrad Dybcio wrote: > > > On 18.04.2023 06:39, Shazad Hussain wrote: >> >> >> On 4/13/2023 9:42 PM, Krzysztof Kozlowski wrote: >>> On 13/04/2023 15:17, Bartosz Golaszewski wrote: >>>> From: Parikshit Pareek <quic_ppareek@quicinc.com> >>>> >>>> Remove the power on reasons with reboot from the pmm8654au_0_pon. >>>> Instead, the PoN reaons should be part of different sdam_0 mode, to >>> >>> typo: reasons >>> >>>> be interoduced. >>> >>> introduced >>> >>> Anyway it does not say why. Are these power reasons not correct? >>> >> >> Hi Krzysztof, >> Since sm8350 the PMIC PON peripheral was split into PON_HLOS and PON_PBS >> to avoid security concerns with HLOS APPS being able to trigger a PMIC >> WARM_RESET unilaterally. When the split occurred, the spare registers >> ended up in PON_PBS, not PON_HLOS. Thus at that time, we moved to using >> an SDAM register for Linux “reboot reason” configuration. And bootloader >> also SDAM register to get these reboot region data to get into >> bootloader/edl, so to have this working we need to use SDAM. >> > Does that imply all PMICs following the PMK8350 scheme (separate HLOS and > PBS) should direct reboot mode writes to SDAM? > > Konrad Yes, that's what the expectation is with bootloader using SDAM as well. >>>> >>>> Signed-off-by: Parikshit Pareek <quic_ppareek@quicinc.com> >>>> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> >>>> --- >>> >>> Best regards, >>> Krzysztof >>> >> >> -Shazad -Shazad
diff --git a/arch/arm64/boot/dts/qcom/sa8775p-pmics.dtsi b/arch/arm64/boot/dts/qcom/sa8775p-pmics.dtsi index 7602cca47bae..5abdc239d3a6 100644 --- a/arch/arm64/boot/dts/qcom/sa8775p-pmics.dtsi +++ b/arch/arm64/boot/dts/qcom/sa8775p-pmics.dtsi @@ -108,8 +108,6 @@ pmm8654au_0_pon: pon@1200 { compatible = "qcom,pmk8350-pon"; reg = <0x1200>, <0x800>; reg-names = "hlos", "pbs"; - mode-recovery = <0x1>; - mode-bootloader = <0x2>; pmm8654au_0_pon_pwrkey: pwrkey { compatible = "qcom,pmk8350-pwrkey";