From patchwork Mon May 8 16:04:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 679989 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 E4509C7EE24 for ; Mon, 8 May 2023 16:04:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232967AbjEHQE6 (ORCPT ); Mon, 8 May 2023 12:04:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43262 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232717AbjEHQEw (ORCPT ); Mon, 8 May 2023 12:04:52 -0400 Received: from mail-lf1-x136.google.com (mail-lf1-x136.google.com [IPv6:2a00:1450:4864:20::136]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0AB8659F1 for ; Mon, 8 May 2023 09:04:51 -0700 (PDT) Received: by mail-lf1-x136.google.com with SMTP id 2adb3069b0e04-4eff50911bfso5193646e87.2 for ; Mon, 08 May 2023 09:04:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683561889; x=1686153889; 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=QLu6la4M2S+eq30bRBxEn3j3JQWM6yeWV3xnHdJprV4=; b=U1T92bLP9KjsMOvz+8xGEjU3pO6jpYbf7knLt2es3jGHdIWQ+fHuOrfMSfzK8I0pDD HeQbQh55+iE5rRlGRgw0dety+6AaVR+I7ACbCOwgJLl8CY0EfqF7Sb7Yp4e1iWYpFMr0 j6OK3/2T/3IzhhRZNi/JdAgClF2ADY7KpsFQqTxdkO5u54amHm9PiTgrENVhRUnHRGyp esM2rZ0FwNx9ve4FkqvMQHq82zmYVhoKTG4zAODs3EIcdmrZAs5+aA2PZEIOrxDJEx2m 0J91hBqCSNprTwa637cDer8MnpP355jsTE/JC21EImykDm8RywaiBzRmugN4dswuh6f0 USCA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683561889; x=1686153889; 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=QLu6la4M2S+eq30bRBxEn3j3JQWM6yeWV3xnHdJprV4=; b=NgsLbm2KbJSoAW7JBjejl5G49BIs6NaaSVdQVn01eu0ocr4dYFY7zVIYQFfmc80wQV f0REyZVOsxdOmKjdsyr1+2PV8JzCUT9nAeAsheUPcITFfPgp1usqkL2WCqv7Q3iS/G7V 8SCmp9zHiK9FlTGy+UAWoWyhBwd5lMQEFU+KNA0wE5+I9iopbDOy8Ip4GsDrqh+Sh4/U 4Cy4q36RCRrRt/4pcyjWb6smrcBv99Uzwfep1wuERH3uRIJBbKxhmsQVUwUt2Z0ueMyp DQYqfSmo9RqY6efFtSTBWB6mGzldd0lR46blj1gZIwCAwTm0BfSo6tVammXhHu8rfo1F zcHQ== X-Gm-Message-State: AC+VfDy6aBUpXaMYQqjuohxgBGanqhbE2t/Dw2m1RjhYz81mbopuCpng U7qb5WfPKzVLUMz0yggoeeHONg== X-Google-Smtp-Source: ACHHUZ4QiKu8q75nnHDsmzWRA51cCxJapIE1UKFcsWVd9AN5EFpzV7cAVjfBbVdy+ljY/NLWUCJg2g== X-Received: by 2002:ac2:44c3:0:b0:4f1:36fb:7533 with SMTP id d3-20020ac244c3000000b004f136fb7533mr2476376lfm.66.1683561889310; Mon, 08 May 2023 09:04:49 -0700 (PDT) Received: from lothlorien.lan (dzdqv0yyyyyyyyyyybm5y-3.rev.dnainternet.fi. [2001:14ba:a0db:1f00::ab2]) by smtp.gmail.com with ESMTPSA id h3-20020ac25963000000b004eff4ea8dd3sm32372lfp.76.2023.05.08.09.04.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 09:04:48 -0700 (PDT) From: Dmitry Baryshkov To: Sebastian Reichel , Rob Herring , Krzysztof Kozlowski , Andy Gross , Bjorn Andersson , Konrad Dybcio , Vinod Koul Cc: linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, Krzysztof Kozlowski Subject: [PATCH v2 1/6] dt-bindings: power: reset: qcom-pon: define pm8941-pon Date: Mon, 8 May 2023 19:04:41 +0300 Message-Id: <20230508160446.2374438-2-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508160446.2374438-1-dmitry.baryshkov@linaro.org> References: <20230508160446.2374438-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org On PM8941 pon doesn't store the reset reason. However we still need the wrapping node for pwrkey and resin nodes. Add bindings for pm8941-pon device. Reviewed-by: Krzysztof Kozlowski Signed-off-by: Dmitry Baryshkov --- Documentation/devicetree/bindings/power/reset/qcom,pon.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/power/reset/qcom,pon.yaml b/Documentation/devicetree/bindings/power/reset/qcom,pon.yaml index d96170eecbd2..0f4f55dd4eac 100644 --- a/Documentation/devicetree/bindings/power/reset/qcom,pon.yaml +++ b/Documentation/devicetree/bindings/power/reset/qcom,pon.yaml @@ -19,6 +19,7 @@ properties: compatible: enum: - qcom,pm8916-pon + - qcom,pm8941-pon - qcom,pms405-pon - qcom,pm8998-pon - qcom,pmk8350-pon @@ -63,6 +64,7 @@ allOf: contains: enum: - qcom,pm8916-pon + - qcom,pm8941-pon - qcom,pms405-pon - qcom,pm8998-pon then: From patchwork Mon May 8 16:04:44 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 679988 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 8EFA0C7EE31 for ; Mon, 8 May 2023 16:05:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233057AbjEHQFB (ORCPT ); Mon, 8 May 2023 12:05:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43318 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233188AbjEHQEz (ORCPT ); Mon, 8 May 2023 12:04:55 -0400 Received: from mail-lf1-x133.google.com (mail-lf1-x133.google.com [IPv6:2a00:1450:4864:20::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 34A115BA0 for ; Mon, 8 May 2023 09:04:54 -0700 (PDT) Received: by mail-lf1-x133.google.com with SMTP id 2adb3069b0e04-4f00d41df22so29680813e87.1 for ; Mon, 08 May 2023 09:04:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683561892; x=1686153892; 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=rnmYe/rfjlFDwKC2E96nnEEwnllE4sqeDHA7mWjMQiY=; b=cmp37D61hWml6a51Z27nYwA4HADUospjypZtS0cEKwgfVX+5fJGJJ3VOH/nlVOYHPZ OjkdFNS/LvKPaJeOzmhwBH49RCIEPqfdX/1i895RQfY/pnSEVt5BcTeuqHrIOyc/ytuc s/Xiz3WWiCFQa9uMvntLX4I37mAFS/Gnhk5B83xD35YHzbglM6ukVEpXP4rWp+0i4y6x vsae/NEEa04MVlS8C+XbDKpq7KmCsQsrXhJUA1ornTgzp2ItrUOPZO9T3ioBcvIG+s8f +mkPwtMqCoAUVEU9B3BNdJau+hIJ/v1GcPJAN11lhcrLCm0ndv3cMsqUt0VsRkRgIns8 Ic0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683561892; x=1686153892; 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=rnmYe/rfjlFDwKC2E96nnEEwnllE4sqeDHA7mWjMQiY=; b=Xg5Ui0Usre79Gba0phqQSV0xN09Z/ubZj0DyJLn/A5lHVvDmq2y66sIUTpoDD7nZjf NO+7w/prC1Gi8buB1ThD2CWhVXllVjduYnbQQr3m02jD1yhUs3vaPylJZMs3zU391J4D dzCe9wmXTJ29HuFs20EOK6hLOdomVJxsofr8KozKInTGjrQg6PK6pOgvg46sJEUmC+pJ 3kwymaeVK0Liya6ol/Gck16TC9lp/MguL1NxM1fKQ8vWAfGq+qvbYVRyrTQNZPxZG/i/ Ty/xqXokwfQwtKxQUdcr4Z4pf7+mPGVNUqASAQEai1DmLT2Z71WbmkHDTUafLLDLFoT6 tVuA== X-Gm-Message-State: AC+VfDwVDEzb6FT71+o4Lex931tFVadhH7+QpHBWPWutqemuf5lpGrPh cGDMIwwFTeL++wcrP1PyTvdyDw== X-Google-Smtp-Source: ACHHUZ55UN8LocS9K5LB+b6IEOtnUml9blYqaysfVDqZ0xzxCIa6A3ORKmaMdJPH0sxE7WfahSlYXg== X-Received: by 2002:ac2:4c36:0:b0:4f1:4a5f:8595 with SMTP id u22-20020ac24c36000000b004f14a5f8595mr2106021lfq.15.1683561892555; Mon, 08 May 2023 09:04:52 -0700 (PDT) Received: from lothlorien.lan (dzdqv0yyyyyyyyyyybm5y-3.rev.dnainternet.fi. [2001:14ba:a0db:1f00::ab2]) by smtp.gmail.com with ESMTPSA id h3-20020ac25963000000b004eff4ea8dd3sm32372lfp.76.2023.05.08.09.04.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 09:04:51 -0700 (PDT) From: Dmitry Baryshkov To: Sebastian Reichel , Rob Herring , Krzysztof Kozlowski , Andy Gross , Bjorn Andersson , Konrad Dybcio , Vinod Koul Cc: linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org Subject: [PATCH v2 4/6] ARM: dts: qcom: apq8074-dragonboard: add resin and gpio keys Date: Mon, 8 May 2023 19:04:44 +0300 Message-Id: <20230508160446.2374438-5-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508160446.2374438-1-dmitry.baryshkov@linaro.org> References: <20230508160446.2374438-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Add device nodes for resin (reset, volume-down) and gpio-keys (volume-up, general key) device nodes. Signed-off-by: Dmitry Baryshkov --- .../arm/boot/dts/qcom-apq8074-dragonboard.dts | 39 +++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts b/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts index 1345df7cbd00..630180edecfd 100644 --- a/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts +++ b/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts @@ -1,5 +1,7 @@ // SPDX-License-Identifier: GPL-2.0 #include +#include +#include #include "qcom-msm8974.dtsi" #include "qcom-pm8841.dtsi" #include "qcom-pm8941.dtsi" @@ -17,6 +19,26 @@ aliases { chosen { stdout-path = "serial0:115200n8"; }; + + gpio-keys { + compatible = "gpio-keys"; + autorepeat; + + pinctrl-0 = <&msm_keys_default>; + pinctrl-names = "default"; + + button-volup { + label = "Volume Up"; + linux,code = ; + gpios = <&pm8941_gpios 5 GPIO_ACTIVE_LOW>; + }; + + button-general { + label = "General"; + linux,code = ; + gpios = <&pm8941_gpios 23 GPIO_ACTIVE_LOW>; + }; + }; }; &blsp1_uart2 { @@ -35,6 +57,23 @@ eeprom: eeprom@52 { }; }; +&pm8941_gpios { + msm_keys_default: pm8941-gpio-keys-state { + pins = "gpio5", "gpio23"; + function = "normal"; + input-enable; + drive-push-pull; + bias-pull-up; + qcom,drive-strength = ; + power-source = ; /* 1.8V */ + }; +}; + +&pm8941_resin { + linux,code = ; + status = "okay"; +}; + &rpm_requests { regulators-0 { compatible = "qcom,rpm-pm8841-regulators"; From patchwork Mon May 8 16:04:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 679987 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 1D9E5C7EE24 for ; Mon, 8 May 2023 16:05:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233098AbjEHQFD (ORCPT ); Mon, 8 May 2023 12:05:03 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43356 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233594AbjEHQE6 (ORCPT ); Mon, 8 May 2023 12:04:58 -0400 Received: from mail-lf1-x131.google.com (mail-lf1-x131.google.com [IPv6:2a00:1450:4864:20::131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1A53559F1 for ; Mon, 8 May 2023 09:04:56 -0700 (PDT) Received: by mail-lf1-x131.google.com with SMTP id 2adb3069b0e04-4ecb137af7eso5329226e87.2 for ; Mon, 08 May 2023 09:04:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683561894; x=1686153894; 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=Z+Jhe48VXAoN+8wGaqTOooemilYAfgL+ZuJTPfMlkfg=; b=TTypQOY+hHf3wO324ueVxAch2AT6S/ea9n9ojC3nDAJa//ZeKbhvoDg9Qc6oiJRs/z EurZywZXEK3V8VIIoX6hdy6T2zvDXKlu6pVryNV22xBgwSZeuC9mZCU+fFy+5kZMuJna 9az+ATyULir7gLKnRp2k/d+4kKVXBYAio/SfehztA5iphcnl54J5VV9iYQnKQgQF1CXw AgoaNxA9azUsNz5Cl39fQhsY8eiCBQjywtpQC0FibEPnXsa0CqP2C1GTXbGqJ2Ziqcbe 43RVpkZUR6+c+FNXZeJpUaitMFsF517n+vQiu+kmjoUFVSpN1mMg3EwAUYyxqLfANO1U Jn+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683561894; x=1686153894; 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=Z+Jhe48VXAoN+8wGaqTOooemilYAfgL+ZuJTPfMlkfg=; b=VR/xevdolnj5VidC/Ih1v8kS9h68p4psxXpuH8RVbQDwQntmZFt1FhNZBfeo6Kq5gw 8Z9LU8ugu4YwznhxR7klcC3ZPGBiig2n/XHxMiz439dc1kNOucINUNlNTWr02GuHRwkh StPTmutIfZQIkKFuaBoQU5a10bwZAjhqmQx9OIc+VHsbLCEcBj/3nNL8tqacbLmdJIOX PgdA0piF9tmhi0OoGXxEqXmBPheFTH43wjx/PEitWRW3UuUqu5AgdGgcCEATCpkLQ2+x p7RHUExs/17IfP+n0EflYIJWWBYEPShkAtcI15ovR29gbZkcxQHxl3rK9i0ZHfswqQ1C Ey0Q== X-Gm-Message-State: AC+VfDy9vxuuOwRnyh9EuSzc5u3vLAwmhd7kq83nO7LV5jo0Nvp+wtQU 7NkJrod5L/L3P6PeWA2LOmrSFQ== X-Google-Smtp-Source: ACHHUZ5+5DsVvjw0JvnA7oomUxPS+m38axatsdA/piUWxUQ3chP4cbNENEf1Gzs+rCD6LYZbeco5uA== X-Received: by 2002:a19:f007:0:b0:4ed:b061:18ee with SMTP id p7-20020a19f007000000b004edb06118eemr2697395lfc.22.1683561894413; Mon, 08 May 2023 09:04:54 -0700 (PDT) Received: from lothlorien.lan (dzdqv0yyyyyyyyyyybm5y-3.rev.dnainternet.fi. [2001:14ba:a0db:1f00::ab2]) by smtp.gmail.com with ESMTPSA id h3-20020ac25963000000b004eff4ea8dd3sm32372lfp.76.2023.05.08.09.04.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 May 2023 09:04:53 -0700 (PDT) From: Dmitry Baryshkov To: Sebastian Reichel , Rob Herring , Krzysztof Kozlowski , Andy Gross , Bjorn Andersson , Konrad Dybcio , Vinod Koul Cc: linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org Subject: [PATCH v2 6/6] ARM: dts: qcom: apq8074-dragonboard: enable coincell charger Date: Mon, 8 May 2023 19:04:46 +0300 Message-Id: <20230508160446.2374438-7-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508160446.2374438-1-dmitry.baryshkov@linaro.org> References: <20230508160446.2374438-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Enable coincell charger for the coin battery which can be installed on the APQ8074 dragonboard. Reviewed-by: Konrad Dybcio Signed-off-by: Dmitry Baryshkov --- arch/arm/boot/dts/qcom-apq8074-dragonboard.dts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts b/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts index 07db6451f273..93a059641957 100644 --- a/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts +++ b/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts @@ -58,6 +58,12 @@ eeprom: eeprom@52 { }; }; +&pm8941_coincell { + qcom,rset-ohms = <2100>; + qcom,vset-millivolts = <3000>; + status = "okay"; +}; + &pm8941_gpios { msm_keys_default: pm8941-gpio-keys-state { pins = "gpio5", "gpio23";