From patchwork Sat Jul 15 21:05:31 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Lin, Meng-Bo" X-Patchwork-Id: 120853 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:c923:0:b0:3e4:2afc:c1 with SMTP id j3csp348040vqt; Sat, 15 Jul 2023 14:42:45 -0700 (PDT) X-Google-Smtp-Source: APBJJlHyyoRU3YkQ0spKI2NetwRKwA2P/w3faVPPfuJSn3j/dl/Td+ytveernTIbNf+7MC7el6gP X-Received: by 2002:a17:90a:2f01:b0:267:5bed:f44d with SMTP id s1-20020a17090a2f0100b002675bedf44dmr8044661pjd.21.1689457365090; Sat, 15 Jul 2023 14:42:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689457365; cv=none; d=google.com; s=arc-20160816; b=aOUNqORvSC7xwE8lcMhFaWpgNk9e6hibN04nzzNDkKHpgMl9KYRL69RF9CRMBzJ86N l5EHeLaMCT53RfpVtoE2LHkXbQQm6XASAAGBVh5qwLtk546WAwaDDL9rufB6h7Lpltc8 UXJT+sgcS7YFtknjapJGVhfAzAn4CoQedf0OcGsZJ0e3DvWR3kza7XbqevNq/yNtqHFR 9zSV2jcRDUkmE3wb0xax6D2pyG1OomlqYQaPe/6wnUkc7MMYlEkBgM2cYOmukpN5ZPRE qGwvnd7MzbgBU5xLwvjJ9zyyV42AFuL5bR65/GxytL3BrkkPm8I3PojGYoha0yRtctMF ch/g== 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:message-id:subject:cc:from:to:dkim-signature:date; bh=p4IaxbwpaHv+xOOMu8SedVmfPdSj/FMf57pnmMhXBrA=; fh=MvBPGIPHPulC8Q1odG8LiYECIuv2LKYjDUHt1nt1gLY=; b=LvC50KktZBB1iiK/vrI4UvcdViFiNxo8FAFPcBHAWj5wYSb9S5uyx6K2YYs8KSqyE7 3izkj+ddhCI/BWfAdpi6O9HoDs6V2el/17DvXyfq+rAdzjuh5N0QJF/pVm1Onlf63+3n RGTS2hX5w2X6SXhVhNgA76azuAFrxI3Yyf7p+ZLqRCEiD2f0gI7PmvHb+kgPNXnLfm2z IArbgEUi8rn6jmE1zSZgC7QNdJuMkqEnPiwZXaKbt7v9QEGJga+ClCtwAmp9tabpsP0T ImG1W1EBg+GopmTq24XyUUvzi2f4CiMNjGSRvHOF2AvHJROOcVpCO2iVIzSdnJOLgvcF zh0w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@protonmail.com header.s=protonmail3 header.b=oZPOyal7; 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 t33-20020a634461000000b0054f73ee92basi4437922pgk.8.2023.07.15.14.42.31; Sat, 15 Jul 2023 14:42:45 -0700 (PDT) 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=oZPOyal7; 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 S229815AbjGOVFm (ORCPT + 99 others); Sat, 15 Jul 2023 17:05:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47850 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229530AbjGOVFk (ORCPT ); Sat, 15 Jul 2023 17:05:40 -0400 Received: from mail-4318.protonmail.ch (mail-4318.protonmail.ch [185.70.43.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D1A5A2738; Sat, 15 Jul 2023 14:05:39 -0700 (PDT) Date: Sat, 15 Jul 2023 21:05:31 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1689455137; x=1689714337; bh=p4IaxbwpaHv+xOOMu8SedVmfPdSj/FMf57pnmMhXBrA=; h=Date:To:From:Cc:Subject:Message-ID:Feedback-ID:From:To:Cc:Date: Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector; b=oZPOyal7jiELXgpPFrXV4x0bXBjCM3MRG5a0sj+aF9n/iidZ+kzWf+KxNEdB97+eu cbE//hMFM96tzR2gii+/01V3p3ZKn5l61opRtARNe6unExvHnyh3d8xpFV95UNO1+J I/4CyiSSEw685i2AI6oVf3Y00yNFLQyKycFK65Iv4KjUgCr/bybpczD8ezQNQxkqYz BUvnEGRvH6csy4xhnawLQ61qhTPDTJCFMexnO66lR51xkiyLWhhwDwEXbo42lppHnd RAqTPXwcR4lOIXSKSpiPKl7ydEy4ynhNHKH6MDWGlrOoB5KNZTRMnclEqmOI2CLden S5kaPwopdJVLw== To: linux-kernel@vger.kernel.org From: "Lin, Meng-Bo" Cc: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Stephan Gerhold , Nikita Travkin , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht Subject: [PATCH v2] arm64: dts: qcom: msm8916-samsung-e2015: Add accelerometer (v2) Message-ID: <20230715210515.13783-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_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED 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: INBOX X-GMAIL-THRID: 1771524446209004196 X-GMAIL-MSGID: 1771524446209004196 v2: fix interrupt-parent = <&msmgpio>; E5, E7 and Grand Max have ST LIS2HH12 accelerometer. Add support for it. Signed-off-by: Stephan Gerhold Signed-off-by: Lin, Meng-Bo --- .../qcom/msm8916-samsung-e2015-common.dtsi | 21 +++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/msm8916-samsung-e2015-common.dtsi b/arch/arm64/boot/dts/qcom/msm8916-samsung-e2015-common.dtsi index 0cdd6af7817f..6f65fd4b3ed3 100644 --- a/arch/arm64/boot/dts/qcom/msm8916-samsung-e2015-common.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8916-samsung-e2015-common.dtsi @@ -42,10 +42,27 @@ reg_touch_key: regulator-touch-key { &blsp_i2c2 { /* lis2hh12 accelerometer instead of BMC150 */ - status = "disabled"; - /delete-node/ accelerometer@10; /delete-node/ magnetometer@12; + + accelerometer@1d { + compatible = "st,lis2hh12"; + reg = <0x1d>; + + interrupt-parent = <&tlmm>; + interrupts = <115 IRQ_TYPE_LEVEL_HIGH>; + + vdd-supply = <&pm8916_l5>; + vddio-supply = <&pm8916_l5>; + + st,drdy-int-pin = <1>; + mount-matrix = "1", "0", "0", + "0", "-1", "0", + "0", "0", "1"; + + pinctrl-0 = <&accel_int_default>; + pinctrl-names = "default"; + }; }; ®_motor_vdd {