From patchwork Mon May 8 00:33:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 679956 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 51B11C7EE26 for ; Mon, 8 May 2023 00:33:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232177AbjEHAdT (ORCPT ); Sun, 7 May 2023 20:33:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51278 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231897AbjEHAdQ (ORCPT ); Sun, 7 May 2023 20:33:16 -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 9A1488A6E for ; Sun, 7 May 2023 17:33:12 -0700 (PDT) Received: by mail-lf1-x136.google.com with SMTP id 2adb3069b0e04-4ec8133c59eso4426488e87.0 for ; Sun, 07 May 2023 17:33:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683505991; x=1686097991; 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=kDKMbXnJIvuQzh8ILfzPlhqGHSGT1sdNjiXjnJAa1jI=; b=aOemtY/voHimGspIjk8noHBn5hdmmzfEOdTHyeecc1aXVlP+fmw9Fip+qw2awvUiCq AQ+46uiFRlP4pdjzKl2vGzV2gd9ySyzZcDyJ19FabROYOCNvxxD7/97uSaWZIbMLSHGV KB+GibLShnJfFndq8WzhJCdGs+W6G6HJr4FoQ4IehX3D0KhFMsKN0FKVfmRfVF5/IFQK bArQy0hcEGjIVTI2NpJnm9mA1cnUfHB0fYa8REK4Kg8dGo9XOOnUuTXbBWldmArWTChi aP3TQPZ7rDAcvdYTa5tw3TezJTK3a1nCvrN3iaI599pEX0b2DJUBFPsLfgQbH2VjIxI8 hUnA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683505991; x=1686097991; 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=kDKMbXnJIvuQzh8ILfzPlhqGHSGT1sdNjiXjnJAa1jI=; b=E5PEvrdMqqLQEScSoEnd7ZIVida//KfNJTHyxbl11CocGv91AhddeJ35n8sfNuIHCk Ar93q3eYwtGdY7wkfPXhVuh8yIc5I2ltbhnKurmvT2VditqzcX9ta97D0aF9WaMImxen UP4zT9TkjEQ+52dg1UP+/dZldsJDfrPzsHvfe6ZxQSoelOTygQRnzITaTtrXkcWi2dbW EgUAg4UWOIaEyQ7WSkNRHHcav8l4gPp0+IwAM8tPt09HxDrf8+7ZL9mr+zbr/E9H4AwF xQhi2W4XqTY3ExfvSc0So4qWE9htZosjKKhUaxwvw0LZ7Qk6jJLynbvG/wuwg7rQUiRW AsAg== X-Gm-Message-State: AC+VfDwULsA/QOgsWuppFKKRDDwRqmeXrOBQ9tSR65YlVBJedlhSrtg/ MRoUhuImGoZ8AqXmVimsW0EVXA== X-Google-Smtp-Source: ACHHUZ5L5mYXfYEX4glhtdoGY9YXd7EcX8HGqt297P7fo7SQRPt2pynB4Zuto+fc42F00r+NP1ofgw== X-Received: by 2002:a05:6512:983:b0:4ec:8d50:d124 with SMTP id w3-20020a056512098300b004ec8d50d124mr1811831lft.48.1683505990904; Sun, 07 May 2023 17:33:10 -0700 (PDT) Received: from lothlorien.lan (dzdqv0yyyyyyyyyyybm5y-3.rev.dnainternet.fi. [2001:14ba:a0db:1f00::ab2]) by smtp.gmail.com with ESMTPSA id m22-20020ac24256000000b004eca2b8b6bdsm1114807lfl.4.2023.05.07.17.33.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 07 May 2023 17:33:10 -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 1/6] dt-bindings: power: reset: qcom-pon: define pm8941-pon Date: Mon, 8 May 2023 03:33:04 +0300 Message-Id: <20230508003309.2363787-2-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508003309.2363787-1-dmitry.baryshkov@linaro.org> References: <20230508003309.2363787-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@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. 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 00:33:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 679955 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 31DF6C7EE2F for ; Mon, 8 May 2023 00:33:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231882AbjEHAdU (ORCPT ); Sun, 7 May 2023 20:33:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51310 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232095AbjEHAdR (ORCPT ); Sun, 7 May 2023 20:33:17 -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 B5A0893C2 for ; Sun, 7 May 2023 17:33:14 -0700 (PDT) Received: by mail-lf1-x133.google.com with SMTP id 2adb3069b0e04-4f13ef4ad91so4485407e87.3 for ; Sun, 07 May 2023 17:33:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683505993; x=1686097993; 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=K1wI9viazUk4MMRKC5k2TgaknGOtp8xfB+NZ3J6gsmc=; b=nLabFqI7hTdKlm1IOb+KK/Nehh3xTJNzcDQ+59LuNs4UBVDgAMuVHD6O3FwUi0C2Kw u//lmqQoxDv0tmFklaKfIUeSVIU3QTgDXW1O0t+0WK2j7hYjhGEr32IdynKFzgg6xA/d ox7TAFbZnfAR/BwYozAG+ie/MFkatbzoYY4TETIrW4CK4RpdqvVQK5aXkRjWmvOprd+l AvIGMgQ3soKaSkCZ8le8wPBzRiAQLz/IjiJFy7plu6lq5cfhc+LLWE3zVABIqNz8O5c7 UTXwT5mI+6R9KUIRxfQAzW4PIO+IV0t4N45hLwjeARiiwzniW/M6RyB/yMU4tKvuxyLH GvFA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683505993; x=1686097993; 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=K1wI9viazUk4MMRKC5k2TgaknGOtp8xfB+NZ3J6gsmc=; b=lED65OGYCoA5mcRsJps3nLOtV+zPGW7AnTjYI0yvoZfHDiXggI5Zx5h9GuZoQgVKQj y5/8OEe61Nci/zm0iLt1Aid95MCqLIVSIa51zLq0NGwTX3JubZIAEKHCZTY/yYK402jd 575TRd7sCi/bwi1nR/4Kif0KLaum+xa2pr9iO0ZC1wOPKEtp0XAVbv8dDB2tDiukHdfE H29SCrXyBZgJh/eE+vH9GV3+GsyYspmO0/59tMkS232Sj/aFJNYsHaApV4BbOXtN6gtn 6dhHS3js9dzojE3U0K68H/6M+58oh7RyECJWfvVMhHQVCNqwB4qVgikgHSTYcOT3hc/G RTRQ== X-Gm-Message-State: AC+VfDzXHZWd+N7QQ3l65O5suA0t1PHXrVeNCTcgC4zXI4N+WRINAVLA fYpcLd2wNw47BbMujLMilVm5Aw== X-Google-Smtp-Source: ACHHUZ6/q1j48+E9petP95PUM7S1AuOFAS4TsIXUxGaajCHK9jzPr1hWaEAujUmJR7acyKn2NLQrow== X-Received: by 2002:ac2:4428:0:b0:4ef:f670:3bd with SMTP id w8-20020ac24428000000b004eff67003bdmr2115844lfl.18.1683505993013; Sun, 07 May 2023 17:33:13 -0700 (PDT) Received: from lothlorien.lan (dzdqv0yyyyyyyyyyybm5y-3.rev.dnainternet.fi. [2001:14ba:a0db:1f00::ab2]) by smtp.gmail.com with ESMTPSA id m22-20020ac24256000000b004eca2b8b6bdsm1114807lfl.4.2023.05.07.17.33.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 07 May 2023 17:33:12 -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 4/6] ARM: dts: qcom: apq8074-dragonboard: add resin and gpio keys Date: Mon, 8 May 2023 03:33:07 +0300 Message-Id: <20230508003309.2363787-5-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508003309.2363787-1-dmitry.baryshkov@linaro.org> References: <20230508003309.2363787-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@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 | 41 +++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts b/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts index 72f7e09a5bbf..2017bdf81677 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" @@ -20,6 +22,26 @@ chosen { stdout-path = "serial0:115200n8"; }; + gpio-keys { + compatible = "gpio-keys"; + autorepeat; + + pinctrl-names = "default"; + pinctrl-0 = <&msm_keys_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>; + }; + }; + reserved-memory { mpss_region: mpss@ac00000 { reg = <0x0ac00000 0x2500000>; @@ -90,6 +112,25 @@ &mdss { status = "okay"; }; +&pm8941_gpios { + msm_keys_default: pm8941-gpio-keys-state { + pinconf { + pins = "gpio5", "gpio23"; + function = "normal"; + input-enable; + drive-push-pull; + bias-pull-up; + qcom,drive-strength = ; + power-source = ; /* 1.8V */ + }; + }; +}; + +&pm8941_resin { + status = "okay"; + linux,code = ; +}; + &pm8941_wled { qcom,cs-out; qcom,switching-freq = <3200>; From patchwork Mon May 8 00:33:08 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 679954 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 47112C7EE33 for ; Mon, 8 May 2023 00:33:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232011AbjEHAdW (ORCPT ); Sun, 7 May 2023 20:33:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51280 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232149AbjEHAdS (ORCPT ); Sun, 7 May 2023 20:33:18 -0400 Received: from mail-lf1-x132.google.com (mail-lf1-x132.google.com [IPv6:2a00:1450:4864:20::132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8003D9EC3 for ; Sun, 7 May 2023 17:33:15 -0700 (PDT) Received: by mail-lf1-x132.google.com with SMTP id 2adb3069b0e04-4f14e499ffcso2575958e87.0 for ; Sun, 07 May 2023 17:33:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1683505994; x=1686097994; 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=eZ39LePwzfXGUX5T8kPy8FR1120Whr91g1ULF3PXJPQ=; b=fLv/w6nSTVC2C1/Q7ISdCiQd7n5tS52T31v/Pb3ESMpuqcloYojscVSDZXKzQfFsCZ 2ba5zR2IZ6K8Cc2AP5BzpwqXMj2gf2GaARC99uaI0AwCIrc0L/vH7yqFSHU2Epx9gE77 1JT0RoMjePLD8+hkEiiIII58kODj10fehq5/q3n7yIr3x98EVoa9xKLAUahL3bQ4zLL0 hpDaKw6ZnypE1llninsKKb83EERQ+FXS0grE07bdYPjlzuvVZNBaviFAegC1SaMtY2Mo iF9hj5QOWwrhF/P3GUJ/zia3qejbJleh4W2IbJl4hktKKVBhhaIIX3+6nU02jTtGMu/g Ux1Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683505994; x=1686097994; 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=eZ39LePwzfXGUX5T8kPy8FR1120Whr91g1ULF3PXJPQ=; b=Ya7ZeUmM9IEamWiToasTsF+u5EKIctCwftPB+Q+yEn6RLSo2ldYDiCME5KTC5lOvcd 8iYHFF170wJURxJxjQ4Kn2387qCvE5VN1xo3NdmK+7H4FN/8ztBScsL4koq26L6NdQBk vK2wkiBNY0WGFQKbcqXphN9Of8Oi8Kg9P5cUsi6y73u9rCNCnVMLjoP3Q7jvIkSS34L9 x7rdPMHQ93uUP/8kyqlBH1KijpCof0QqzhEGIHKPN6DaLiYejajOHYNUkWhMO5jLH2ug Gl3r6rmT+sHsW+lkWwnP64VAjI5N//bTRcPSozhkA06ky0GIg4t70AnYrTla0AKb4Dpu Q6Ow== X-Gm-Message-State: AC+VfDzONf1JWrPoCIo7MCVY5EYmgTrkj5+Xo+tzW4RTEHuQdRgMAvMb Z/6Muc8i1XcgKsisTZXGyH9peg== X-Google-Smtp-Source: ACHHUZ6c46A+L0LTHo+BJXLdpuWw6r0Yxf/FeK0ARsHgolnU7SgB6GwinbyprvwCrIKIEmaTbM0+dg== X-Received: by 2002:ac2:442a:0:b0:4dd:afd7:8f1 with SMTP id w10-20020ac2442a000000b004ddafd708f1mr2070131lfl.52.1683505993858; Sun, 07 May 2023 17:33:13 -0700 (PDT) Received: from lothlorien.lan (dzdqv0yyyyyyyyyyybm5y-3.rev.dnainternet.fi. [2001:14ba:a0db:1f00::ab2]) by smtp.gmail.com with ESMTPSA id m22-20020ac24256000000b004eca2b8b6bdsm1114807lfl.4.2023.05.07.17.33.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 07 May 2023 17:33:13 -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 5/6] ARM: dts: qcom: apq8074-dragonboard: add onboard leds Date: Mon, 8 May 2023 03:33:08 +0300 Message-Id: <20230508003309.2363787-6-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230508003309.2363787-1-dmitry.baryshkov@linaro.org> References: <20230508003309.2363787-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org The dragonboard as three LEDs: red, green and blue. Add corresponding description. Signed-off-by: Dmitry Baryshkov --- .../arm/boot/dts/qcom-apq8074-dragonboard.dts | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts b/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts index 2017bdf81677..16d609b85dfe 100644 --- a/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts +++ b/arch/arm/boot/dts/qcom-apq8074-dragonboard.dts @@ -1,6 +1,7 @@ // SPDX-License-Identifier: GPL-2.0 #include #include +#include #include #include "qcom-msm8974.dtsi" #include "qcom-pm8841.dtsi" @@ -126,6 +127,29 @@ pinconf { }; }; +&pm8941_lpg { + qcom,power-source = <1>; + status = "okay"; + + led@5 { + reg = <5>; + color = ; + function = LED_FUNCTION_INDICATOR; + }; + + led@6 { + reg = <6>; + color = ; + function = LED_FUNCTION_INDICATOR; + }; + + led@7 { + reg = <7>; + color = ; + function = LED_FUNCTION_INDICATOR; + }; +}; + &pm8941_resin { status = "okay"; linux,code = ;