From patchwork Sat Nov 19 20:46:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Lin, Meng-Bo" X-Patchwork-Id: 23329 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp861772wrr; Sat, 19 Nov 2022 12:47:50 -0800 (PST) X-Google-Smtp-Source: AA0mqf5D0CagH33citL8CpEHUVxvsiLdG2HeNpr9VGl1wII2tHcXSEErcy5F2NXx13ACPs+sA4Xl X-Received: by 2002:a17:90a:d190:b0:20d:747a:c507 with SMTP id fu16-20020a17090ad19000b0020d747ac507mr13849523pjb.145.1668890870107; Sat, 19 Nov 2022 12:47:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668890870; cv=none; d=google.com; s=arc-20160816; b=NY9sNrP6Dcc8aTT7IzmIbTii0jAO/HZ+2VI4nB8VDgRNy5htN06YtPEtQ6KCkCdqCt uXct6gsGByLsrOdB2gKS44jBzhKBosfQ+6RLkIB9I1eA/W++e9elXf8Tn91YVBONugvH EuXkUMRslNbKowP7/0I553r3jLbIQn+TdhHuKLtcKZhQ/uAJajjhT68wKIBlLuQmAWyo Ui55sw4v46LciFl64X+ug26TdD7hzkYj2apvbQjy6ry9Den8a4Z3f6WXEHxngfoS1TOt huDZakgibvnZMi/vJ5/kz7SYWQhgCTHR31Z1I5BIOHB91H/yOClfGlLl5+A6ce8Q8cuR 4MTQ== 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 :feedback-id:references:in-reply-to:message-id:subject:cc:from:to :dkim-signature:date; bh=eIEl89I/FCcRoTqjgCQKLi93kH0LmWEm09LZk3oD43E=; b=gGmKtYZgatUFmvIbpnbsgQS+HW8OHsakRYA4/buwfg1JWTNqb8VyP6fcoVE0shNtbP 21pIQF8sa5GWHO0TDpcIasCzI+NZhV02EZV6qXqXdPBsmGLIdjwsT9dl55VQvBqjIp4+ yz6tWFgRtRd1KDpFHynhpiJ4/KnkEyzb9pQTNZ8Ypip0lBB+etzJ78KkprE1QdwYR7vu 4LgRA+GUfMaFU5pxyTCB/VBPD37WQv/WmSN07Q8MMBKam7VuKldDItPYHhan/Cgn6IsI cSYwhUuA5I1wZ/+imXFmSTrLGf9ZpEj4o3BCgi9piIAvi7vNxNjXzN8q7AWq+OkLtsDO AzXQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@protonmail.com header.s=protonmail3 header.b=o9jdWtIz; 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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=protonmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w8-20020aa79548000000b00561fb77aed3si6398300pfq.368.2022.11.19.12.47.37; Sat, 19 Nov 2022 12:47:50 -0800 (PST) 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=@protonmail.com header.s=protonmail3 header.b=o9jdWtIz; 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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=protonmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234741AbiKSUqU (ORCPT + 99 others); Sat, 19 Nov 2022 15:46:20 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51138 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234544AbiKSUqQ (ORCPT ); Sat, 19 Nov 2022 15:46:16 -0500 Received: from mail-4325.protonmail.ch (mail-4325.protonmail.ch [185.70.43.25]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4590113D2D; Sat, 19 Nov 2022 12:46:16 -0800 (PST) Date: Sat, 19 Nov 2022 20:46:10 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1668890774; x=1669149974; bh=eIEl89I/FCcRoTqjgCQKLi93kH0LmWEm09LZk3oD43E=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=o9jdWtIzMRGBJEgsVnmuit/HdR3EJp5gPgs3+JEXIk6r6Glpm24NbJYu9brKu/oy6 RO9hgmsgxNNAtdC+k/HthoX5SnPvrOOO0Tp9WG2yn2vzNOuU2D8rhLmuP7ewOy1WlM 26U7zNYUk+/Vpm2GBAbfxw8UqrU8Nj7px4KQDeBFxBDr+7X8J1+gs4LplQ7nbAg+ia N8x2b0ObtNk11amTxf6cDwrSiBH7z8/VYcKBsEapIkPEJ03Wjge9mgn0MEjP91JG8R L/2UilzBWnSvY+MZ8UaVha//mXWSn2rkT7490G10kd5hCcYity9728MnoOzSBl9qey CnZftt6fDrmCg== To: linux-kernel@vger.kernel.org From: "Lin, Meng-Bo" Cc: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Stephan Gerhold , Nikita Travkin , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht Subject: [PATCH v2 1/3] dt-bindings: qcom: Document bindings for new msm8916-acer-a1-724 device Message-ID: <20221119204405.94233-1-linmengbo0689@protonmail.com> In-Reply-To: <20221119204209.94125-1-linmengbo0689@protonmail.com> References: <20221119204209.94125-1-linmengbo0689@protonmail.com> Feedback-ID: 40467236:user:proton MIME-Version: 1.0 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,SPF_HELO_PASS,SPF_PASS autolearn=ham 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749958913126488445?= X-GMAIL-MSGID: =?utf-8?q?1749958913126488445?= Document the new acer,a1-724 device tree bindings used in its device tree. Signed-off-by: Lin, Meng-Bo Acked-by: Krzysztof Kozlowski --- Documentation/devicetree/bindings/arm/qcom.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/arm/qcom.yaml b/Documentation/devicetree/bindings/arm/qcom.yaml index 463509f0f23a..83f6748979a9 100644 --- a/Documentation/devicetree/bindings/arm/qcom.yaml +++ b/Documentation/devicetree/bindings/arm/qcom.yaml @@ -180,6 +180,7 @@ properties: - items: - enum: + - acer,a1-724 - alcatel,idol347 - asus,z00l - huawei,g7 From patchwork Sat Nov 19 20:46:25 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Lin, Meng-Bo" X-Patchwork-Id: 23333 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp870628wrr; Sat, 19 Nov 2022 13:17:40 -0800 (PST) X-Google-Smtp-Source: AA0mqf4uCIO+Ei/bXZEdYEG2hFnAEvtGuhEH1vkqXzgWmjTR6/3545oi6KCepghP0nyFH4xm7q5/ X-Received: by 2002:a17:906:cd10:b0:7ad:c0e7:7a99 with SMTP id oz16-20020a170906cd1000b007adc0e77a99mr10021002ejb.689.1668892660798; Sat, 19 Nov 2022 13:17:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668892660; cv=none; d=google.com; s=arc-20160816; b=iPO7e4KIC/pflI5wLJZErF9+PuOXJvBYf8oFalZZcscCmRqRFASRDOdQ9PTZ4vbSvn IRnidZVmiuBDa7HDmu0rkd7E8OPsAOK8aPj96dcehG9VCQ6mz6j3i5A+r/YgRNhRJNAG y62Zj50VsQd50Eu+5ErB0n86YpMshhJt9hZu3AYxyfIqJC5mdWLuq0PHOIU0Yaj0YGzT 1gNHubsylVGXJjrfCLZ1oC5G/XriO1yFvWKCOE8q1Z31gXAHGVRonQ8mywGcvSvDKHPH SjCGaBT16/p8xK2G4dyqMn+6QeeBY8m/RLo3F6+KE/F6Bulk5o/hVTRnHIpSIYKxlDN2 W5jw== 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 :feedback-id:references:in-reply-to:message-id:subject:cc:from:to :dkim-signature:date; bh=hPoacXHlZ89+oEM9rfwXsaEVZ93x+4FJwRdNup6QWe0=; b=UtkxeyVvGZ4b7jlaIgC4XPYgZegJZNfh9IT2iZpPkt/sIO+nbPjhNBNVa0vqm2QzrK 4DmgJW6GDdbKaAysOStScC9o0xwPgNV5wzKdtr9ObQAcoZDa9bTt4gK+vLSh8XmgaBBw 4GLenY97f5VQcGXrDmB2Vjmt0EcGd4CdeNyBOB0TuRI9Ftp9VZpFr5nD4URo/K7P75W8 FyoOGoJxhzbOgQTxT+tR9jW8mfSsgoLtAVBtyFuUT62dtWMBop3cY5yY5ziesb5nhAYr JPlxGcvMuQARUVNdScCYqiV8DFmo1y+0s0eDQGzjLYta6nxgnbUxg02CojNQltm7A8Vh inGw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@protonmail.com header.s=protonmail3 header.b=N4x3ILov; 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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=protonmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id et19-20020a170907295300b0078d25914115si4531239ejc.570.2022.11.19.13.17.16; Sat, 19 Nov 2022 13:17:40 -0800 (PST) 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=@protonmail.com header.s=protonmail3 header.b=N4x3ILov; 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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=protonmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235022AbiKSUqn (ORCPT + 99 others); Sat, 19 Nov 2022 15:46:43 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51532 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234897AbiKSUqj (ORCPT ); Sat, 19 Nov 2022 15:46:39 -0500 Received: from mail-40130.protonmail.ch (mail-40130.protonmail.ch [185.70.40.130]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9EEC013DF0; Sat, 19 Nov 2022 12:46:38 -0800 (PST) Date: Sat, 19 Nov 2022 20:46:25 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1668890796; x=1669149996; bh=hPoacXHlZ89+oEM9rfwXsaEVZ93x+4FJwRdNup6QWe0=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=N4x3ILovMSGwWd1F/AqW6OoJwesHFtNoO8rUygTdeyW+rrlbekj/S9wUFrDE+PjPD jsfzsHVLgv/j8YGsdea2haPrJnVTSewh0f9siKlOqCy0YqNrjfk4mfHEjN5sTpE2GX OFSv7qFVQ3g7SB9JLmIiGaSb21fG5PngScKQzIHovTn4wnVJCY9JKrePAOB2RNIikR o4swcDYC9ds49yuvePdY/McOs3gd5OO6/XWslaiZWx4rNnr1uoZBtC8P6zgLb6kWbq 7u6EbxGz5A8+cvNKMhTK6EQYsN30cLBPRT4FJ6Y9Cfe9e2/WDOue7ObTSYpF/UbaBn 8D5AadsrvtyNQ== To: linux-kernel@vger.kernel.org From: "Lin, Meng-Bo" Cc: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Stephan Gerhold , Nikita Travkin , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht Subject: [PATCH v2 2/3] arm64: dts: qcom: msm8916-acer-a1-724: Add initial device tree Message-ID: <20221119204414.94287-1-linmengbo0689@protonmail.com> In-Reply-To: <20221119204209.94125-1-linmengbo0689@protonmail.com> References: <20221119204209.94125-1-linmengbo0689@protonmail.com> Feedback-ID: 40467236:user:proton MIME-Version: 1.0 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS autolearn=ham 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749956372908267948?= X-GMAIL-MSGID: =?utf-8?q?1749960790932301280?= Acer Iconia Talk S A1-724 is a tablet using the MSM8916 SoC released in 2014. Note: The original firmware from Acer can only boot 32-bit kernels. To boot arm64 kernels it is necessary to flash 64-bit TZ/HYP firmware with EDL, e.g. taken from the DragonBoard 410c. This works because Acer didn't set up (firmware) secure boot. Add a device tree for with initial support for: - GPIO keys - pm8916-vibrator - SDHCI (internal and external storage) - USB Device Mode - UART - WCNSS (WiFi/BT) - Regulators Signed-off-by: Lin, Meng-Bo --- arch/arm64/boot/dts/qcom/Makefile | 1 + .../boot/dts/qcom/msm8916-acer-a1-724.dts | 217 ++++++++++++++++++ 2 files changed, 218 insertions(+) create mode 100644 arch/arm64/boot/dts/qcom/msm8916-acer-a1-724.dts diff --git a/arch/arm64/boot/dts/qcom/Makefile b/arch/arm64/boot/dts/qcom/Makefile index afe496a93f94..f38a20074013 100644 --- a/arch/arm64/boot/dts/qcom/Makefile +++ b/arch/arm64/boot/dts/qcom/Makefile @@ -7,6 +7,7 @@ dtb-$(CONFIG_ARCH_QCOM) += ipq6018-cp01-c1.dtb dtb-$(CONFIG_ARCH_QCOM) += ipq8074-hk01.dtb dtb-$(CONFIG_ARCH_QCOM) += ipq8074-hk10-c1.dtb dtb-$(CONFIG_ARCH_QCOM) += ipq8074-hk10-c2.dtb +dtb-$(CONFIG_ARCH_QCOM) += msm8916-acer-a1-724.dtb dtb-$(CONFIG_ARCH_QCOM) += msm8916-alcatel-idol347.dtb dtb-$(CONFIG_ARCH_QCOM) += msm8916-asus-z00l.dtb dtb-$(CONFIG_ARCH_QCOM) += msm8916-huawei-g7.dtb diff --git a/arch/arm64/boot/dts/qcom/msm8916-acer-a1-724.dts b/arch/arm64/boot/dts/qcom/msm8916-acer-a1-724.dts new file mode 100644 index 000000000000..acd909551a75 --- /dev/null +++ b/arch/arm64/boot/dts/qcom/msm8916-acer-a1-724.dts @@ -0,0 +1,217 @@ +// SPDX-License-Identifier: GPL-2.0-only + +/dts-v1/; + +#include "msm8916-pm8916.dtsi" + +#include +#include + +/* + * NOTE: The original firmware from Acer can only boot 32-bit kernels. + * To boot this device tree using arm64 it is necessary to flash 64-bit + * TZ/HYP firmware (e.g. taken from the DragonBoard 410c). + * See https://wiki.postmarketos.org/wiki/Acer_Iconia_Talk_S_(acer-a1-724) + * for suggested installation instructions. + */ + +/ { + model = "Acer Iconia Talk S A1-724"; + compatible = "acer,a1-724", "qcom,msm8916"; + chassis-type = "tablet"; + + aliases { + serial0 = &blsp1_uart2; + }; + + chosen { + stdout-path = "serial0"; + }; + + gpio-keys { + compatible = "gpio-keys"; + + pinctrl-names = "default"; + pinctrl-0 = <&gpio_keys_default>; + + label = "GPIO Buttons"; + + button-volume-up { + label = "Volume Up"; + gpios = <&msmgpio 107 GPIO_ACTIVE_LOW>; + linux,code = ; + }; + }; + + usb_id: usb-id { + compatible = "linux,extcon-usb-gpio"; + id-gpio = <&msmgpio 110 GPIO_ACTIVE_HIGH>; + pinctrl-names = "default"; + pinctrl-0 = <&usb_id_default>; + }; +}; + +&blsp1_uart2 { + status = "okay"; +}; + +&pm8916_resin { + status = "okay"; + linux,code = ; +}; + +&pm8916_vib { + status = "okay"; +}; + +&pronto { + status = "okay"; +}; + +&sdhc_1 { + status = "okay"; + + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&sdc1_clk_on &sdc1_cmd_on &sdc1_data_on>; + pinctrl-1 = <&sdc1_clk_off &sdc1_cmd_off &sdc1_data_off>; +}; + +&sdhc_2 { + status = "okay"; + + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on>; + pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off>; + + cd-gpios = <&msmgpio 38 GPIO_ACTIVE_HIGH>; +}; + +&usb { + status = "okay"; + extcon = <&usb_id>, <&usb_id>; +}; + +&usb_hs_phy { + extcon = <&usb_id>; +}; + +&smd_rpm_regulators { + vdd_l1_l2_l3-supply = <&pm8916_s3>; + vdd_l4_l5_l6-supply = <&pm8916_s4>; + vdd_l7-supply = <&pm8916_s4>; + + s3 { + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <1300000>; + }; + + s4 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <2100000>; + }; + + l1 { + regulator-min-microvolt = <1225000>; + regulator-max-microvolt = <1225000>; + }; + + l2 { + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <1200000>; + }; + + l4 { + regulator-min-microvolt = <2050000>; + regulator-max-microvolt = <2050000>; + }; + + l5 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + }; + + l6 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + }; + + l7 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + }; + + l8 { + regulator-min-microvolt = <2850000>; + regulator-max-microvolt = <2900000>; + }; + + l9 { + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + }; + + l10 { + regulator-min-microvolt = <2700000>; + regulator-max-microvolt = <2800000>; + }; + + l11 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <2950000>; + regulator-allow-set-load; + regulator-system-load = <200000>; + }; + + l12 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <2950000>; + }; + + l13 { + regulator-min-microvolt = <3075000>; + regulator-max-microvolt = <3075000>; + }; + + l14 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <3300000>; + }; + + l15 { + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <3300000>; + }; + + l16 { + regulator-min-microvolt = <2900000>; + regulator-max-microvolt = <2900000>; + }; + + l17 { + regulator-min-microvolt = <2850000>; + regulator-max-microvolt = <2850000>; + }; + + l18 { + regulator-min-microvolt = <2700000>; + regulator-max-microvolt = <2700000>; + }; +}; + +&msmgpio { + gpio_keys_default: gpio-keys-default-state { + pins = "gpio107"; + function = "gpio"; + + drive-strength = <2>; + bias-pull-up; + }; + + usb_id_default: usb-id-default-state { + pins = "gpio110"; + function = "gpio"; + + drive-strength = <8>; + bias-pull-up; + }; +}; From patchwork Sat Nov 19 20:46:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Lin, Meng-Bo" X-Patchwork-Id: 23330 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp862793wrr; Sat, 19 Nov 2022 12:51:31 -0800 (PST) X-Google-Smtp-Source: AA0mqf7O/EtQqj0amm5dHjQ2VYp/uBzwbt0ARfSS2kDWsWK+EpF3fxFg+rPCwv49NFUCVOBP6T28 X-Received: by 2002:a05:6a02:10c:b0:477:5d14:e2a5 with SMTP id bg12-20020a056a02010c00b004775d14e2a5mr1174579pgb.452.1668891091226; Sat, 19 Nov 2022 12:51:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668891091; cv=none; d=google.com; s=arc-20160816; b=jN2WDmXjYQ+uTIeveUL3n5aAnpDD1t9oGozxSD0flrZiwwUygFm3EelfRjqRaBTWzN zs4znS101JBpga6QMVkq36gOIerkwNE5zn40qHgkbb1d0DKmCX36KCtANd1oOFt1GUiE tRlF9vtk3Y9+caIGw/i4FCJbKEYyzXBvX2zpp6LsPCBPYrb9eQjVIhF0yQopKLmw0TZR CSCcLKYBtZkFoYUtmpKglARAGc4xbAnKHCSdAbteATetEfuGUqauwYqRt3Vo37gl5tcF RZE2nQQKSGSxq2KCMRfe7ZnPObhuE1AgOY+xC2zmpEY1PCSStDYkx21GITOlLUTnslHU ZjJg== 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 :feedback-id:references:in-reply-to:message-id:subject:cc:from:to :dkim-signature:date; bh=RZgjb9/5OQctpPzuTFDZDZE4FEfMwb4kqi0lsraby84=; b=JpAdE8EpbAfHOqYrDfb9SmZVMF/N4C1QLKMv6UWTZlIEi0ucofxpj+pAqfQA3gClSo GF4ciMAKY7VOvcjrVuAIdcaGk1qqDWYAXBzDF946exJUljPWYWx3i+DOwwz/yIjwBYQR OSxNK5C30xJFZTUdc1qZpv/AudpcmVi+a937Mt8ojUayS4CA9J5afiHb5mMsNZ3++iXB HzLaEc8cYiEBS4E+YyQUItlkcHWcsNLr+YsdrJzSFJ9Sl6uDSvtXdfm1FcZnX160UWUp ceye8iU1kNtMx5j9ZmDqaS3HW8Xczn7KidFC8I4a2QlkcAnn596f8ut/qDcmDEjHRD06 09+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@protonmail.com header.s=protonmail3 header.b=ARKQ8VA9; 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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=protonmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x5-20020a654145000000b00476bfc9e1f5si7089271pgp.610.2022.11.19.12.51.17; Sat, 19 Nov 2022 12:51:31 -0800 (PST) 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=@protonmail.com header.s=protonmail3 header.b=ARKQ8VA9; 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; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=protonmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235099AbiKSUqr (ORCPT + 99 others); Sat, 19 Nov 2022 15:46:47 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51548 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235049AbiKSUqo (ORCPT ); Sat, 19 Nov 2022 15:46:44 -0500 Received: from mail-4324.protonmail.ch (mail-4324.protonmail.ch [185.70.43.24]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D1AC313D21; Sat, 19 Nov 2022 12:46:42 -0800 (PST) Date: Sat, 19 Nov 2022 20:46:32 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1668890800; x=1669150000; bh=RZgjb9/5OQctpPzuTFDZDZE4FEfMwb4kqi0lsraby84=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=ARKQ8VA9knhvcAfXpsxDnxrvqNwZOf1eeKlNoLCZILlbyINeCmEyiGBmm3yOIzHND rs+0f/vrgcVtTdKQO58lwfH8N9hSjeU1oQtKAyW8vh8oRfAMWuNblgHmBzZjXXrBqD 4eJfFC7RntzQedsBVPZ0CyDPLu4WJr8/6u2uirxeIgod1EuBxKRHq0Qxa152g8GTSd uXLX11E1cMFF9Ddg2BkpB1fRMUi94M2rDMYQek29QPDr1Vlp8Qm4W2OZDLLFP0uVKH Eahkap9GnP3C4uVFZ0L50KQ7qI0sywNMnanQGVuz3a1PdiVdw8i0VdVhJAzLIIKR1O IUMUaw3Fd4GWg== To: linux-kernel@vger.kernel.org From: "Lin, Meng-Bo" Cc: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Stephan Gerhold , Nikita Travkin , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht Subject: [PATCH v2 3/3] arm64: dts: qcom: msm8916-acer-a1-724: Add accelerometer/magnetometer Message-ID: <20221119204424.94341-1-linmengbo0689@protonmail.com> In-Reply-To: <20221119204209.94125-1-linmengbo0689@protonmail.com> References: <20221119204209.94125-1-linmengbo0689@protonmail.com> Feedback-ID: 40467236:user:proton MIME-Version: 1.0 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749959144691030893?= X-GMAIL-MSGID: =?utf-8?q?1749959144691030893?= Iconia Talk S uses a Bosch BMC150 accelerometer/magnetometer combo. The chip provides two separate I2C devices for the accelerometer and magnetometer that are already supported by the bmc150-accel and bmc150-magn driver. Signed-off-by: Lin, Meng-Bo --- .../boot/dts/qcom/msm8916-acer-a1-724.dts | 38 +++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/msm8916-acer-a1-724.dts b/arch/arm64/boot/dts/qcom/msm8916-acer-a1-724.dts index acd909551a75..3461a39ee866 100644 --- a/arch/arm64/boot/dts/qcom/msm8916-acer-a1-724.dts +++ b/arch/arm64/boot/dts/qcom/msm8916-acer-a1-724.dts @@ -6,6 +6,7 @@ #include #include +#include /* * NOTE: The original firmware from Acer can only boot 32-bit kernels. @@ -51,6 +52,35 @@ usb_id: usb-id { }; }; +&blsp_i2c2 { + status = "okay"; + + accelerometer@10 { + compatible = "bosch,bmc150_accel"; + reg = <0x10>; + interrupt-parent = <&msmgpio>; + interrupts = <115 IRQ_TYPE_EDGE_RISING>; + + vdd-supply = <&pm8916_l17>; + vddio-supply = <&pm8916_l6>; + + pinctrl-names = "default"; + pinctrl-0 = <&accel_int_default>; + + mount-matrix = "0", "-1", "0", + "-1", "0", "0", + "0", "0", "1"; + }; + + magnetometer@12 { + compatible = "bosch,bmc150_magn"; + reg = <0x12>; + + vdd-supply = <&pm8916_l17>; + vddio-supply = <&pm8916_l6>; + }; +}; + &blsp1_uart2 { status = "okay"; }; @@ -199,6 +229,14 @@ l18 { }; &msmgpio { + accel_int_default: accel-int-default-state { + pins = "gpio115"; + function = "gpio"; + + drive-strength = <2>; + bias-disable; + }; + gpio_keys_default: gpio-keys-default-state { pins = "gpio107"; function = "gpio";