From patchwork Sun Jul 4 07:40:44 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shawn Guo X-Patchwork-Id: 470035 Delivered-To: patch@linaro.org Received: by 2002:a02:c94a:0:0:0:0:0 with SMTP id u10csp2941506jao; Sun, 4 Jul 2021 00:41:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzjLu1o0UDwbH6IVc2aK7FryDLQsYsqpxwiHhrGdKr5tRtV9tuBZDyNrHiMgXZvU5SGUS93 X-Received: by 2002:a05:6e02:1a04:: with SMTP id s4mr5964791ild.294.1625384476841; Sun, 04 Jul 2021 00:41:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1625384476; cv=none; d=google.com; s=arc-20160816; b=yTzsrQ6EAIhjlRduyiaqJi2E13muAQoIMgHhsZ5vwkWKjbqDL8UnBw21WQpEdewgMC dr0w/CfuuCMaKrcky7HuDXBQE2cw/Kim9+DyjkdHqHQKsFJp4/FcAMWx3EmO1FOoknn1 S0dD+1lML8ZbYQikFE/dLWXyUNoRNucaVJ3CA+Ct4TckMC7Apek+samAZdzhw1kK6NQz jvMg2bOaYq9Xh/pnFZs3eGx54tGZN2Rr0jvmDUJrwhBi9Xl6Mle8colEa6iZi0Ga5CIq KrdFgOzVnSGDW0wQs73wPeNcwsCyiJpK7wFqkFPxvzYSyqrsgj9FyfNgvGvR7crb3iXQ kYSg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :cc:to:from:dkim-signature; bh=Y2JvDwp3TfASNY2nYjyfxKqjVkgvIs8uvDCzlvHG2AA=; b=PrONpENoINFHGZ7SarA6DJXFDnBcqBM20Bo8C6T6Gr/rFLMKhq78BpH3mWNjchaOIp tmkohsiuc33Tzhs/aKTiZ2GY1o4qo8EwQknktmQKU606km5PmtxxyK8BshHyN2q8Xuap 92v+B4qrzNyKQTJ71MOWD09Ynb6EKqfbfVj5yz4yRpYfFnBNSfjV/WZoekJu+nNXBkku 0QSZ6TK65psw69SAHjiFvCTPIubgKuN7jlSZ5M4EQrPFOfP4920LaLlW7vAfegZx2NQy bGwk3j9BLCWDCAUMl9hCUwy5PVD/LcDEQBmC9isuw1QOfBewpj2X11xb/DawokwOp1hd Hrrg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cbrduWji; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a1si9488287ioe.96.2021.07.04.00.41.16; Sun, 04 Jul 2021 00:41:16 -0700 (PDT) Received-SPF: pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cbrduWji; spf=pass (google.com: domain of devicetree-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=devicetree-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 S229602AbhGDHnu (ORCPT + 7 others); Sun, 4 Jul 2021 03:43:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41546 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229540AbhGDHnt (ORCPT ); Sun, 4 Jul 2021 03:43:49 -0400 Received: from mail-pj1-x102a.google.com (mail-pj1-x102a.google.com [IPv6:2607:f8b0:4864:20::102a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0B426C061762 for ; Sun, 4 Jul 2021 00:41:15 -0700 (PDT) Received: by mail-pj1-x102a.google.com with SMTP id in17-20020a17090b4391b0290170ba0ec7fcso12164004pjb.4 for ; Sun, 04 Jul 2021 00:41:15 -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:in-reply-to:references; bh=Y2JvDwp3TfASNY2nYjyfxKqjVkgvIs8uvDCzlvHG2AA=; b=cbrduWjiQDcg1zBJYNfFqJlwRhenjmvi02OUBwr8M4hyh8/l3aDFwt2Vy1ZRblRZ6K 1SOfwbZhNI/1AhuNfkurXrnNtEIQp0pcEel+V7xEswXE8qJW3b2gSmIDaTxUNi7RLeca vfuEVL191zztFFkSQ7e2PTS+A641GNx76vDII+QCNt7DEsLVNNUpVsKel1P5tcA6s/6e BlLVFtK3093ZAiV7/rjobH8nig1pxRbCgsTXE9da1w3CHhbvHP6cP1yKOjXN1nRWUNEW F+Hi1pGWY9ajJzGRZdf4BU4PFhVynDvZm5FRQNSz08BY0JrxQ4LfyJzv5zGRDnzVsZhj GwgA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=Y2JvDwp3TfASNY2nYjyfxKqjVkgvIs8uvDCzlvHG2AA=; b=eWmddTk3pkECnkbnMP0tmgLD/Y6UsAfF7YSXqKVLVaWJC/S9rd3+g38gqVcAIrZqhU MIn6WpNsh/+Z01hEAhDF/yRX1h0NICdZoqb96V/7ZpwJ1GHPjhH2jjqhy49+NrhqMPyC GZ6ia5gyNYPeu7vVC3D8xR5R153ZZNWQvebb/EPHmrHUXuZovNh8iadVU0ZyBe/5oz8e K8UHfzJlOwdZCObFQbl37vuh+4aZ0SEQdbDQSqFc+CLXe58+4WINJxVTWHeN1gaqDA8n 0csmlNzibCQPc9P+zEIaJW3D82KGXTEPwOEn85FJJgEyFqTnZRH8GCtXWht/GXuCNZXM SfTQ== X-Gm-Message-State: AOAM530+HFnBuUeYTUBkJg/tpxUGA7c0Bd+1OXscodYR1eZwRXMtTIEo K7G+ZoOVVVEo5VAX7hNAV12/dA== X-Received: by 2002:a17:90a:d506:: with SMTP id t6mr8292715pju.26.1625384474616; Sun, 04 Jul 2021 00:41:14 -0700 (PDT) Received: from localhost.localdomain (80.251.214.228.16clouds.com. [80.251.214.228]) by smtp.gmail.com with ESMTPSA id gz24sm7052956pjb.0.2021.07.04.00.41.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 04 Jul 2021 00:41:14 -0700 (PDT) From: Shawn Guo To: Sebastian Reichel Cc: Rob Herring , Vinod Koul , Bjorn Andersson , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-pm@vger.kernel.org, Shawn Guo Subject: [PATCH 2/3] dt-bindings: qcom,pon: Add 'qcom,mode-in-imem' support Date: Sun, 4 Jul 2021 15:40:44 +0800 Message-Id: <20210704074045.21643-3-shawn.guo@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210704074045.21643-1-shawn.guo@linaro.org> References: <20210704074045.21643-1-shawn.guo@linaro.org> Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org It's not always the case that reboot mode value gets stored in PON register. For example, Sony Xperia M4 Aqua phone (MSM8939) uses a different set of mode value and stores them in IMEM. Add property 'qcom,mode-in-imem' to distinguish this mechanism from the existing one. Signed-off-by: Shawn Guo --- .../bindings/power/reset/qcom,pon.yaml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) -- 2.17.1 diff --git a/Documentation/devicetree/bindings/power/reset/qcom,pon.yaml b/Documentation/devicetree/bindings/power/reset/qcom,pon.yaml index 7764c804af1d..a6270e39b7a2 100644 --- a/Documentation/devicetree/bindings/power/reset/qcom,pon.yaml +++ b/Documentation/devicetree/bindings/power/reset/qcom,pon.yaml @@ -23,6 +23,10 @@ properties: reg: maxItems: 1 + qcom,mode-in-imem: + description: Reboot mode is stored in IMEM rather than PON register + type: boolean + patternProperties: "^mode-.+": $ref: /schemas/types.yaml#/definitions/uint32 @@ -35,6 +39,7 @@ required: additionalProperties: false examples: + # Example 1: Reboot mode is stored in PON register - | pmic { #address-cells = <1>; @@ -47,3 +52,17 @@ examples: mode-recovery = <0x1>; }; }; + # Example 2: Reboot mode is stored in IMEM + - | + pmic { + #address-cells = <1>; + #size-cells = <0>; + + pon@800 { + compatible = "qcom,pm8916-pon"; + reg = <0x860065c>; + qcom,mode-in-imem; + mode-bootloader = <0x77665500>; + mode-recovery = <0x77665502>; + }; + };