From patchwork Tue Jul 30 19:28:05 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dimitri John Ledkov X-Patchwork-Id: 1139323 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=ubuntu.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; secure) header.d=surgut.co.uk header.i=@surgut.co.uk header.b="XHVDbjYT"; dkim-atps=neutral Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 45ymmx3RyHz9sDQ; Wed, 31 Jul 2019 05:28:17 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1hsXnA-0003tS-Hf; Tue, 30 Jul 2019 19:28:12 +0000 Received: from mail-io1-f66.google.com ([209.85.166.66]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1hsXn7-0003sz-Ew for kernel-team@lists.ubuntu.com; Tue, 30 Jul 2019 19:28:09 +0000 Received: by mail-io1-f66.google.com with SMTP id i10so17480651iol.13 for ; Tue, 30 Jul 2019 12:28:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=surgut.co.uk; s=google; h=sender:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=1NpgnDCEK24rHqd+qaLmg2aX6Y+RISfGmQVHisih60s=; b=XHVDbjYT92BvwVlk6tcVWUxI9hy9OvMNsM05fKI8iQZ4GQ/wk87MidG6c/9dZUE2X8 xJST2zXgMBVl6ek7M9TGxSPnirfzE/gQtfxomcJplmffCvlk/cHQEPixjDjvbaGWwFBl 54pV1z80/chVc2tN3Dl9VNaJPJW8KCoT2o/nM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; bh=1NpgnDCEK24rHqd+qaLmg2aX6Y+RISfGmQVHisih60s=; b=mlZSfYs1dEOYRysRruxMmU0UMl6OBK54BfWEIX8+TGt9X5Xtat6MYulpBXjZPDV6VC YRdyfLf+uLGzIe5BA7AL21h9FZZCrE3N/wKjvUeDVvJTbISjyXxc+MBLpvhbrU2sKBgV Xh/ndlt/70bPoC0yVN9w7KckMQK34BLvzzJg+4LFlbZtp33LVo3SZThs9u33zIAN6MXP s1eI/od6d/MIM2YP8/49qHBUi8sNcIma/kcych5Bk/DEktNaTD8pMx0V1QTSIUiPLfoO a4rURv1NVQEF8RuMZpsPc/ert9KijFFBKk2arn9oiYcuYRiSreqI4jux8Jf8wiWa9O6q rA9g== X-Gm-Message-State: APjAAAWUT19GZwvM+d3QpEZ/B1NFKr7F2jghnWMvsCWYVtAW/lNY0GBF nEIyx53wY7fePkLwrgIieRq0bkfY X-Google-Smtp-Source: APXvYqzr1pkhmz0VkYh06VKe1c2gLA1FV3smMxNIJoF+d3dT4ReXt9AbiyWoFoe74F3y4psUb7xe4g== X-Received: by 2002:a6b:d81a:: with SMTP id y26mr2255729iob.126.1564514887906; Tue, 30 Jul 2019 12:28:07 -0700 (PDT) Received: from localhost ([162.223.5.78]) by smtp.gmail.com with ESMTPSA id y20sm50929597iol.34.2019.07.30.12.28.06 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Tue, 30 Jul 2019 12:28:07 -0700 (PDT) From: Dimitri John Ledkov To: kernel-team@lists.ubuntu.com Subject: [EOAN][UNSTABLE][PATCH] UBUNTU: SAUCE: arm64: dts: qcom: Add support for AArch64 laptops Date: Tue, 30 Jul 2019 15:28:05 -0400 Message-Id: <20190730192805.15334-1-xnox@ubuntu.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: aarch64-laptops@lists.linaro.org, Dimitri John Ledkov , Lee Jones , AArch64 Laptops Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" From: AArch64 Laptops This is squashed merged of multiple patches from https://github.com/aarch64-laptops/linux/tree/laptops-ubuntu Note that some of these, with different names are getting upstreamed targetted for v5.4. Once those are all merged and available, this patch will become obsolete and will be dropped. This enables booting using flash-kernel in eoan on Lenovo Mixx 630 & Yoga C630, Asus TP370QL, HP Envy x2. Squashed commit messages below: arm64: dts: qcom: Add support for MSM8668 based laptops 3 files are being introduced to describe the differences between the newly released Snapdragon 835 (MSM8668) based AArch64 Laptops. There are 3 currently available: * ASUS NovaGo TP370QL * HP Envy x2ta * Lenovo Miix 630 The later two (HP and Lenovo) are very similar and are as yet able to share the same Device Tree Binaries. Once any difference arise, a new file 'laptop-lenovo-miix-360.dts' will have to be drafted. These files ensure the following work on each of the devices: * Touchpad * Keyboard * SDCHI SD card reader (card detect) arm64: config: laptops: Enable the RPM PM8998 regulators arm64: dts: qcom: Pull up trackpad IRQ on the Asus Stops IRQ storm and renders trackpad functional instead of laggy. arm64: dts: qcom: Provide Lenovo Mixx 630 with its own DTB arm64: dts: qcom: Add Lenovo Yoga C630 The Lenovo Yoga C630 is built on the SDM850 from Qualcomm, but this seem to be similar enough to the SDM845 that we can reuse the sdm845.dtsi. Supported by this patch is: keyboard, battery monitoring, UFS storage, USB host and Bluetooth. arm64: dts: qcom: Move HID device at 0x2C to its rightful place According to the ACPI tables the HID device at I2C address 0x2C should be located under the I2C Controller with address 0x88C000, presented as I2C3 in DT and I2C4 in ACPI. Signed-off-by: Lee Jones Signed-off-by: Dimitri John Ledkov --- arch/arm64/boot/dts/qcom/Makefile | 5 + .../boot/dts/qcom/laptop-asus-tp370ql.dts | 49 ++ arch/arm64/boot/dts/qcom/laptop-common.dtsi | 26 + .../arm64/boot/dts/qcom/laptop-hp-envy-x2.dts | 29 ++ .../boot/dts/qcom/laptop-lenovo-mixx-630.dts | 29 ++ .../boot/dts/qcom/laptop-lenovo-yoga-c630.dts | 11 + .../boot/dts/qcom/sdm850-lenovo-yoga-c630.dts | 455 ++++++++++++++++++ drivers/regulator/qcom-rpmh-regulator.c | 2 +- 8 files changed, 605 insertions(+), 1 deletion(-) create mode 100644 arch/arm64/boot/dts/qcom/laptop-asus-tp370ql.dts create mode 100644 arch/arm64/boot/dts/qcom/laptop-common.dtsi create mode 100644 arch/arm64/boot/dts/qcom/laptop-hp-envy-x2.dts create mode 100644 arch/arm64/boot/dts/qcom/laptop-lenovo-mixx-630.dts create mode 100644 arch/arm64/boot/dts/qcom/laptop-lenovo-yoga-c630.dts create mode 100644 arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts diff --git a/arch/arm64/boot/dts/qcom/Makefile b/arch/arm64/boot/dts/qcom/Makefile index 0a7e5dfce6f7..03452c893c94 100644 --- a/arch/arm64/boot/dts/qcom/Makefile +++ b/arch/arm64/boot/dts/qcom/Makefile @@ -2,6 +2,10 @@ dtb-$(CONFIG_ARCH_QCOM) += apq8016-sbc.dtb dtb-$(CONFIG_ARCH_QCOM) += apq8096-db820c.dtb dtb-$(CONFIG_ARCH_QCOM) += ipq8074-hk01.dtb +dtb-$(CONFIG_ARCH_QCOM) += laptop-asus-tp370ql.dtb +dtb-$(CONFIG_ARCH_QCOM) += laptop-hp-envy-x2.dtb +dtb-$(CONFIG_ARCH_QCOM) += laptop-lenovo-mixx-630.dtb +dtb-$(CONFIG_ARCH_QCOM) += laptop-lenovo-yoga-c630.dtb dtb-$(CONFIG_ARCH_QCOM) += msm8916-mtp.dtb dtb-$(CONFIG_ARCH_QCOM) += msm8992-bullhead-rev-101.dtb dtb-$(CONFIG_ARCH_QCOM) += msm8994-angler-rev-101.dtb @@ -14,3 +18,4 @@ dtb-$(CONFIG_ARCH_QCOM) += sdm845-db845c.dtb dtb-$(CONFIG_ARCH_QCOM) += sdm845-mtp.dtb dtb-$(CONFIG_ARCH_QCOM) += qcs404-evb-1000.dtb dtb-$(CONFIG_ARCH_QCOM) += qcs404-evb-4000.dtb +dtb-$(CONFIG_ARCH_QCOM) += sdm850-lenovo-yoga-c630.dtb diff --git a/arch/arm64/boot/dts/qcom/laptop-asus-tp370ql.dts b/arch/arm64/boot/dts/qcom/laptop-asus-tp370ql.dts new file mode 100644 index 000000000000..72b59783c964 --- /dev/null +++ b/arch/arm64/boot/dts/qcom/laptop-asus-tp370ql.dts @@ -0,0 +1,49 @@ +// SPDX-License-Identifier: GPL-2.0 +/* Copyright (c) 2019, The Linux Foundation. All rights reserved. */ + +/dts-v1/; + +#include "laptop-common.dtsi" + +/ { + model = "Qualcomm Technologies, Inc. MSM8998 v1 Asus TP370QL"; + compatible = "qcom,msm8998-asus-tp370ql"; + + qcom,board-id = <8 0>; +}; + +&tlmm { + touchpad: touchpad { + config { + pins = "gpio123"; + bias-pull-up; /* pull up */ + }; + }; +}; + +&sdhc2 { + cd-gpios = <&tlmm 95 GPIO_ACTIVE_HIGH>; +}; + +&blsp1_i2c6 { + status = "okay"; + + keyboard@3a { + compatible = "hid-over-i2c"; + interrupt-parent = <&tlmm>; + interrupts = <0x25 IRQ_TYPE_LEVEL_LOW>; + reg = <0x3a>; + hid-descr-addr = <0x0001>; + }; + + touchpad@15 { + compatible = "hid-over-i2c"; + interrupt-parent = <&tlmm>; + interrupts = <0x7b IRQ_TYPE_LEVEL_LOW>; + reg = <0x15>; + hid-descr-addr = <0x0001>; + + pinctrl-names = "default"; + pinctrl-0 = <&touchpad>; + }; +}; diff --git a/arch/arm64/boot/dts/qcom/laptop-common.dtsi b/arch/arm64/boot/dts/qcom/laptop-common.dtsi new file mode 100644 index 000000000000..184b33ad8694 --- /dev/null +++ b/arch/arm64/boot/dts/qcom/laptop-common.dtsi @@ -0,0 +1,26 @@ +// SPDX-License-Identifier: GPL-2.0 +/* Copyright (c) 2019, The Linux Foundation. All rights reserved. */ + +/dts-v1/; + +#include "msm8998-mtp.dtsi" + +&rpm_requests { + pm8998-regulators { + compatible = "qcom,rpm-pm8998-regulators"; + + status = "okay"; + + vdd_l9-supply = <&vph_pwr>; + vdd_l10_l23_l25-supply = <&vph_pwr>; + vdd_l13_l19_l21-supply = <&vph_pwr>; + vdd_l16_l28-supply = <&vph_pwr>; + vdd_l18_l22-supply = <&vph_pwr>; + vdd_l20_l24-supply = <&vph_pwr>; + }; + + pmi8998-regulators { + compatible = "qcom,rpm-pmi8998-regulators"; + status = "disabled"; + }; +}; diff --git a/arch/arm64/boot/dts/qcom/laptop-hp-envy-x2.dts b/arch/arm64/boot/dts/qcom/laptop-hp-envy-x2.dts new file mode 100644 index 000000000000..4727e12c7dbf --- /dev/null +++ b/arch/arm64/boot/dts/qcom/laptop-hp-envy-x2.dts @@ -0,0 +1,29 @@ +// SPDX-License-Identifier: GPL-2.0 +/* Copyright (c) 2019, The Linux Foundation. All rights reserved. */ + +/dts-v1/; + +#include "laptop-common.dtsi" + +/ { + model = "Qualcomm Technologies, Inc. MSM8998 v1 HP Envy X2"; + compatible = "qcom,msm8998-hp-envy-x2"; + + qcom,board-id = <8 0>; +}; + +&sdhc2 { + cd-gpios = <&tlmm 95 GPIO_ACTIVE_LOW>; +}; + +&blsp1_i2c6 { + status = "okay"; + + keyboard@3a { + compatible = "hid-over-i2c"; + interrupt-parent = <&tlmm>; + interrupts = <0x79 IRQ_TYPE_LEVEL_LOW>; + reg = <0x3a>; + hid-descr-addr = <0x0001>; + }; +}; diff --git a/arch/arm64/boot/dts/qcom/laptop-lenovo-mixx-630.dts b/arch/arm64/boot/dts/qcom/laptop-lenovo-mixx-630.dts new file mode 100644 index 000000000000..8b03cb7176ce --- /dev/null +++ b/arch/arm64/boot/dts/qcom/laptop-lenovo-mixx-630.dts @@ -0,0 +1,29 @@ +// SPDX-License-Identifier: GPL-2.0 +/* Copyright (c) 2019, The Linux Foundation. All rights reserved. */ + +/dts-v1/; + +#include "laptop-common.dtsi" + +/ { + model = "Qualcomm Technologies, Inc. MSM8998 v1 Levovo Mixx 630"; + compatible = "qcom,msm8998-lenovo-mixx-630"; + + qcom,board-id = <8 0>; +}; + +&sdhc2 { + cd-gpios = <&tlmm 95 GPIO_ACTIVE_HIGH>; +}; + +&blsp1_i2c6 { + status = "okay"; + + keyboard@3a { + compatible = "hid-over-i2c"; + interrupt-parent = <&tlmm>; + interrupts = <0x79 IRQ_TYPE_LEVEL_LOW>; + reg = <0x3a>; + hid-descr-addr = <0x0001>; + }; +}; diff --git a/arch/arm64/boot/dts/qcom/laptop-lenovo-yoga-c630.dts b/arch/arm64/boot/dts/qcom/laptop-lenovo-yoga-c630.dts new file mode 100644 index 000000000000..e75bff57cc0e --- /dev/null +++ b/arch/arm64/boot/dts/qcom/laptop-lenovo-yoga-c630.dts @@ -0,0 +1,11 @@ +// SPDX-License-Identifier: GPL-2.0 +/* Copyright (c) 2019, The Linux Foundation. All rights reserved. */ + +/dts-v1/; + +#include "sdm850-lenovo-yoga-c630.dts" + +/ { + model = "Lenovo Yoga C630"; + compatible = "lenovo,yoga-c630", "qcom,sdm845"; +}; diff --git a/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts new file mode 100644 index 000000000000..0d9aab66ecb4 --- /dev/null +++ b/arch/arm64/boot/dts/qcom/sdm850-lenovo-yoga-c630.dts @@ -0,0 +1,455 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * Lenovo Yoga C630 + * + * Copyright (c) 2019, Linaro Ltd. + */ + +/dts-v1/; + +#include +#include "sdm845.dtsi" +#include "pm8998.dtsi" + +/ { + model = "Lenovo Yoga C630"; + compatible = "lenovo,yoga-c630", "qcom,sdm845"; + + aliases { + hsuart0 = &uart6; + }; +}; + +&apps_rsc { + pm8998-rpmh-regulators { + compatible = "qcom,pm8998-rpmh-regulators"; + qcom,pmic-id = "a"; + + vdd-l2-l8-l17-supply = <&vreg_s3a_1p35>; + vdd-l7-l12-l14-l15-supply = <&vreg_s5a_2p04>; + + vreg_s2a_1p125: smps2 { + }; + + vreg_s3a_1p35: smps3 { + regulator-min-microvolt = <1352000>; + regulator-max-microvolt = <1352000>; + regulator-initial-mode = ; + }; + + vreg_s4a_1p8: smps4 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-initial-mode = ; + }; + + vreg_s5a_2p04: smps5 { + regulator-min-microvolt = <2040000>; + regulator-max-microvolt = <2040000>; + regulator-initial-mode = ; + }; + + vreg_s7a_1p025: smps7 { + }; + + vdd_qusb_hs0: + vdda_hp_pcie_core: + vdda_mipi_csi0_0p9: + vdda_mipi_csi1_0p9: + vdda_mipi_csi2_0p9: + vdda_mipi_dsi0_pll: + vdda_mipi_dsi1_pll: + vdda_qlink_lv: + vdda_qlink_lv_ck: + vdda_qrefs_0p875: + vdda_pcie_core: + vdda_pll_cc_ebi01: + vdda_pll_cc_ebi23: + vdda_sp_sensor: + vdda_ufs1_core: + vdda_ufs2_core: + vdda_usb1_ss_core: + vdda_usb2_ss_core: + vreg_l1a_0p875: ldo1 { + regulator-min-microvolt = <880000>; + regulator-max-microvolt = <880000>; + regulator-initial-mode = ; + }; + + vddpx_10: + vreg_l2a_1p2: ldo2 { + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <1200000>; + regulator-initial-mode = ; + regulator-always-on; + }; + + vreg_l3a_1p0: ldo3 { + }; + + vdd_wcss_cx: + vdd_wcss_mx: + vdda_wcss_pll: + vreg_l5a_0p8: ldo5 { + regulator-min-microvolt = <800000>; + regulator-max-microvolt = <800000>; + regulator-initial-mode = ; + }; + + vddpx_13: + vreg_l6a_1p8: ldo6 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-initial-mode = ; + }; + + vreg_l7a_1p8: ldo7 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-initial-mode = ; + }; + + vreg_l8a_1p2: ldo8 { + }; + + vreg_l9a_1p8: ldo9 { + }; + + vreg_l10a_1p8: ldo10 { + }; + + vreg_l11a_1p0: ldo11 { + }; + + vdd_qfprom: + vdd_qfprom_sp: + vdda_apc1_cs_1p8: + vdda_gfx_cs_1p8: + vdda_qrefs_1p8: + vdda_qusb_hs0_1p8: + vddpx_11: + vreg_l12a_1p8: ldo12 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + regulator-initial-mode = ; + }; + + vddpx_2: + vreg_l13a_2p95: ldo13 { + }; + + vreg_l14a_1p88: ldo14 { + regulator-min-microvolt = <1880000>; + regulator-max-microvolt = <1880000>; + regulator-initial-mode = ; + }; + + vreg_l15a_1p8: ldo15 { + }; + + vreg_l16a_2p7: ldo16 { + }; + + vreg_l17a_1p3: ldo17 { + regulator-min-microvolt = <1304000>; + regulator-max-microvolt = <1304000>; + regulator-initial-mode = ; + }; + + vreg_l18a_2p7: ldo18 { + }; + + vreg_l19a_3p0: ldo19 { + regulator-min-microvolt = <3100000>; + regulator-max-microvolt = <3108000>; + regulator-initial-mode = ; + }; + + vreg_l20a_2p95: ldo20 { + regulator-min-microvolt = <2960000>; + regulator-max-microvolt = <2960000>; + regulator-initial-mode = ; + }; + + vreg_l21a_2p95: ldo21 { + }; + + vreg_l22a_2p85: ldo22 { + }; + + vreg_l23a_3p3: ldo23 { + }; + + vdda_qusb_hs0_3p1: + vreg_l24a_3p075: ldo24 { + regulator-min-microvolt = <3075000>; + regulator-max-microvolt = <3083000>; + regulator-initial-mode = ; + }; + + vreg_l25a_3p3: ldo25 { + regulator-min-microvolt = <3104000>; + regulator-max-microvolt = <3112000>; + regulator-initial-mode = ; + }; + + vdda_hp_pcie_1p2: + vdda_hv_ebi0: + vdda_hv_ebi1: + vdda_hv_ebi2: + vdda_hv_ebi3: + vdda_mipi_csi_1p25: + vdda_mipi_dsi0_1p2: + vdda_mipi_dsi1_1p2: + vdda_pcie_1p2: + vdda_ufs1_1p2: + vdda_ufs2_1p2: + vdda_usb1_ss_1p2: + vdda_usb2_ss_1p2: + vreg_l26a_1p2: ldo26 { + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <1208000>; + regulator-initial-mode = ; + }; + + vreg_l28a_3p0: ldo28 { + }; + + vreg_lvs1a_1p8: lvs1 { + }; + + vreg_lvs2a_1p8: lvs2 { + }; + }; +}; + +&apps_smmu { + /* TODO: Figure out how to survive booting with this enabled */ + status = "disabled"; +}; + +&gcc { + protected-clocks = , + , + ; +}; + +&i2c1 { + status = "okay"; + clock-frequency = <400000>; + + battery@70 { + compatible = "some,battery"; + reg = <0x70>; + }; +}; + +&i2c3 { + status = "okay"; + clock-frequency = <400000>; + + hid@15 { + compatible = "hid-over-i2c"; + reg = <0x15>; + hid-descr-addr = <0x1>; + + interrupts-extended = <&tlmm 37 IRQ_TYPE_EDGE_RISING>; + +// pinctrl-names = "default"; +// pinctrl-0 = <&i2c2_hid_active>; + }; + + hid@2c { + compatible = "hid-over-i2c"; + reg = <0x2c>; + hid-descr-addr = <0x20>; + + interrupts-extended = <&tlmm 37 IRQ_TYPE_EDGE_RISING>; + + pinctrl-names = "default"; + pinctrl-0 = <&i2c2_hid_active>; + }; +}; + +&i2c5 { + status = "okay"; + clock-frequency = <400000>; + + hid@10 { + compatible = "hid-over-i2c"; + reg = <0x10>; + hid-descr-addr = <0x1>; + + interrupts-extended = <&tlmm 125 IRQ_TYPE_EDGE_FALLING>; + + pinctrl-names = "default"; + pinctrl-0 = <&i2c6_hid_active>; + }; +}; + +&i2c11 { + status = "okay"; + clock-frequency = <400000>; + + hid@5c { + compatible = "hid-over-i2c"; + reg = <0x5c>; + hid-descr-addr = <0x1>; + + interrupts-extended = <&tlmm 92 IRQ_TYPE_LEVEL_LOW>; + + pinctrl-names = "default"; + pinctrl-0 = <&i2c12_hid_active>; + }; +}; + +&qupv3_id_0 { + status = "okay"; +}; + +&qupv3_id_1 { + status = "okay"; +}; + +&tlmm { + gpio-reserved-ranges = <0 4>, <81 4>; + + i2c2_hid_active: i2c2-hid-active { + pins = <37>; + function = "gpio"; + + input-enable; + bias-pull-up; + drive-strength = <2>; + }; + + i2c6_hid_active: i2c6-hid-active { + pins = <125>; + function = "gpio"; + + input-enable; + bias-pull-up; + drive-strength = <2>; + }; + + i2c12_hid_active: i2c12-hid-active { + pins = <92>; + function = "gpio"; + + input-enable; + bias-pull-up; + drive-strength = <2>; + }; +}; + +&uart6 { + status = "okay"; + + bluetooth { + compatible = "qcom,wcn3990-bt"; + + vddio-supply = <&vreg_s4a_1p8>; + vddxo-supply = <&vreg_l7a_1p8>; + vddrf-supply = <&vreg_l17a_1p3>; + vddch0-supply = <&vreg_l25a_3p3>; + max-speed = <3200000>; + }; +}; + +&ufs_mem_hc { + status = "okay"; + + vcc-supply = <&vreg_l20a_2p95>; + vcc-max-microamp = <600000>; +}; + +&ufs_mem_phy { + status = "okay"; + + vdda-phy-supply = <&vdda_ufs1_core>; + vdda-pll-supply = <&vdda_ufs1_1p2>; +}; + +&usb_1 { + status = "okay"; +}; + +&usb_1_dwc3 { + dr_mode = "host"; +}; + +&usb_1_hsphy { + status = "okay"; + + vdd-supply = <&vdda_usb1_ss_core>; + vdda-pll-supply = <&vdda_qusb_hs0_1p8>; + vdda-phy-dpdm-supply = <&vdda_qusb_hs0_3p1>; + + qcom,imp-res-offset-value = <8>; + qcom,hstx-trim-value = ; + qcom,preemphasis-level = ; + qcom,preemphasis-width = ; +}; + +&usb_1_qmpphy { + status = "okay"; + + vdda-phy-supply = <&vdda_usb1_ss_1p2>; + vdda-pll-supply = <&vdda_usb1_ss_core>; +}; + +&usb_2 { + status = "okay"; +}; + +&usb_2_dwc3 { + dr_mode = "host"; +}; + +&usb_2_hsphy { + status = "okay"; + + vdd-supply = <&vdda_usb2_ss_core>; + vdda-pll-supply = <&vdda_qusb_hs0_1p8>; + vdda-phy-dpdm-supply = <&vdda_qusb_hs0_3p1>; + + qcom,imp-res-offset-value = <8>; + qcom,hstx-trim-value = ; +}; + +&usb_2_qmpphy { + status = "okay"; + + vdda-phy-supply = <&vdda_usb2_ss_1p2>; + vdda-pll-supply = <&vdda_usb2_ss_core>; +}; + +/* PINCTRL - additions to nodes defined in sdm845.dtsi */ + +&qup_i2c12_default { + drive-strength = <2>; + bias-disable; +}; + +&qup_uart6_default { + pinmux { + pins = "gpio45", "gpio46", "gpio47", "gpio48"; + function = "qup6"; + }; + + cts { + pins = "gpio45"; + bias-pull-down; + }; + + rts-tx { + pins = "gpio46", "gpio47"; + drive-strength = <2>; + bias-disable; + }; + + rx { + pins = "gpio48"; + bias-pull-up; + }; +}; diff --git a/drivers/regulator/qcom-rpmh-regulator.c b/drivers/regulator/qcom-rpmh-regulator.c index b2c2d01d1637..aa0272497be4 100644 --- a/drivers/regulator/qcom-rpmh-regulator.c +++ b/drivers/regulator/qcom-rpmh-regulator.c @@ -207,7 +207,7 @@ static int rpmh_regulator_is_enabled(struct regulator_dev *rdev) { struct rpmh_vreg *vreg = rdev_get_drvdata(rdev); - return vreg->enabled; + return vreg->enabled > 0; } static int rpmh_regulator_set_enable_state(struct regulator_dev *rdev,