From patchwork Sun Jun 9 11:05:43 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanislav Jakubek X-Patchwork-Id: 13691236 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 345E6C27C53 for ; Sun, 9 Jun 2024 11:06:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Subject:Cc:To: From:Date:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=nSW2jNx95WBuijX1z3cnQiTdmwyNLO17AF5/oV6yexU=; b=e3enDPXkYGBH/R dc7XGtRhfNGyeSy0IMG1BsJxuMGSPPV6cfXuGNEOSTqFDVrT4N4zllYqWJdGGIeQd0Hxu9qYmTKZE FoYGCW9mgQSpHlwk8mY2itZihYyCPpVT6VrEFlS1hM2mXfPcEqBq+ixMd5QletOJkuRQVgQDyWHXO eUUT0TfLL8FnEm9egmxl1VC0ZGd2GXDo9IarU3yg7bWwVhsPWRHSciy97d9hHM88UOlWW4xTqmhsL 1xDMaJAxOq21prEoQ5iUUTbi2G+sk5P5vny3gdm2DUexVHQMPLHriGxbFY/OsupyV/sa5OE9bn9CH Zfz1BD/9/l+DANEU8fuQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sGGN2-00000002Shu-1TqD; Sun, 09 Jun 2024 11:05:56 +0000 Received: from mail-ej1-x635.google.com ([2a00:1450:4864:20::635]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sGGMv-00000002SgW-40hr for linux-arm-kernel@lists.infradead.org; Sun, 09 Jun 2024 11:05:53 +0000 Received: by mail-ej1-x635.google.com with SMTP id a640c23a62f3a-a6ef8bf500dso141997166b.0 for ; Sun, 09 Jun 2024 04:05:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1717931146; x=1718535946; darn=lists.infradead.org; h=content-disposition:mime-version:message-id:subject:cc:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=wpM5CSHQ7BjZsm86jY13nUms8C9enIOcpR5asKG1/Ro=; b=ckaBtereq3CLQLE6LH6XbWoGqwfe2NPGchBvTBKbrsR3Fx9MWGboXZDBzcdXz3UYxY kGT+wzGIhn8ewFOO4Nwm9uajWveDsEx3l7h90BgON2AtYmziz4tmwT+CtCP8H5Ps2Yg9 xzA/EmJ81T0wDh6uUzNlz1jIREE6NmtK6XYpI9LLBeKi3Yersw0yfXTrxdAtuGbBK+7Q RwiMPREJ8gqZwiOLoE4CVh3g5sOks/Ppz1cXGsGL2HwOHcYlmY3K8XwoeOasmE6fbJwk +eRj6MCTiMD0lD88xe2lmbIAx/l2GBbw6LsCsHZKmm7v5Yekoh9MuZcO3w87lxB4cHaY GRnA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717931146; x=1718535946; h=content-disposition:mime-version:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=wpM5CSHQ7BjZsm86jY13nUms8C9enIOcpR5asKG1/Ro=; b=HsO6wFEF175dsPiIZmXJVqOCsavGOafIpKHpJwG3dmP517UPmoqP7GxB9fcRqzNcF6 3IW9gsv+cOLME7+OI4fI+GOOElCj6lXKGopZLbHqepRj5RYzpqddiyEkdRLuOvki8YzX R02+ReMOMgm1DPoKodG020JS6Vii5fId2LeAI3ZRJQgYoBObYc4oAQQR3ClLd3ihbQ57 KR2mLyYicAxDLlDfWkmybx3ysLj+O313Vd8TiKn9eklkUncW6sbDOdzBNoitC3BGZGPN QiCTtQC2jDhRkGGVEP/+hYl3SKWgqn8VJ3UEoixGpe4JuoMpb9jXUk86Ul7zv0viyb+U x5JA== X-Forwarded-Encrypted: i=1; AJvYcCVbnOSRUEsDFDFIL96+AYO6F4R6Wyfd1npOgIojs492kNw0I7XPKrrxleHeQUjlmAdDAtfOBJmMXtBXPPVbQThD8oIQEgXOQ3W9cG2iz+niAUZyImI= X-Gm-Message-State: AOJu0YwENInrNUJT18uTbjQTj8XrjManfLUwQFR+jV0e6w/Tx5wTWZ5Y U4ejT3f7P1CkuUTMWIpluf1NCp0ennkrdT0IS3NotYjtjq7a4T87 X-Google-Smtp-Source: AGHT+IFMn/iHi3S62iXJonXfBdAPUVD5+Y6loLLU+/1VysHfn0b6aGHs2T+z7LzchWh08FlOKqtnxQ== X-Received: by 2002:a17:907:7d9e:b0:a6f:ea6:9534 with SMTP id a640c23a62f3a-a6f0ea698d6mr217343866b.76.1717931145707; Sun, 09 Jun 2024 04:05:45 -0700 (PDT) Received: from standask-GA-A55M-S2HP (lu-nat-113-247.ehs.sk. [188.123.113.247]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a6c806eaa41sm508317766b.115.2024.06.09.04.05.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 09 Jun 2024 04:05:45 -0700 (PDT) Date: Sun, 9 Jun 2024 13:05:43 +0200 From: Stanislav Jakubek To: Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, phone-devel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] ARM: dts: qcom: motorola-falcon: add accelerometer, magnetometer Message-ID: MIME-Version: 1.0 Content-Disposition: inline X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240609_040551_679975_6624E36E X-CRM114-Status: GOOD ( 10.11 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Add the accelerometer and magnetometer that are present on the Motorola Moto G (2013) device. Signed-off-by: Stanislav Jakubek Reviewed-by: Konrad Dybcio --- .../boot/dts/qcom/msm8226-motorola-falcon.dts | 53 +++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/arch/arm/boot/dts/qcom/msm8226-motorola-falcon.dts b/arch/arm/boot/dts/qcom/msm8226-motorola-falcon.dts index 029e1b1659c9..5dbca83f2230 100644 --- a/arch/arm/boot/dts/qcom/msm8226-motorola-falcon.dts +++ b/arch/arm/boot/dts/qcom/msm8226-motorola-falcon.dts @@ -96,6 +96,35 @@ reserved@fb00000 { }; }; +&blsp1_i2c2 { + status = "okay"; + + magnetometer@c { + compatible = "asahi-kasei,ak8963"; + reg = <0xc>; + interrupts-extended = <&tlmm 66 IRQ_TYPE_EDGE_FALLING>; + reset-gpios = <&tlmm 62 GPIO_ACTIVE_LOW>; + vdd-supply = <&pm8226_l19>; + vid-supply = <&pm8226_lvs1>; + pinctrl-0 = <&mag_int_default &mag_reset_default>; + pinctrl-names = "default"; + }; + + accelerometer@19 { + compatible = "st,lis3dh-accel"; + reg = <0x19>; + interrupts-extended = <&tlmm 63 IRQ_TYPE_EDGE_FALLING>; + vdd-supply = <&pm8226_l19>; + vddio-supply = <&pm8226_lvs1>; + pinctrl-0 = <&accel_int_default>; + pinctrl-names = "default"; + mount-matrix = "0", "1", "0", + "1", "0", "0", + "0", "0", "-1"; + st,drdy-int-pin = <1>; + }; +}; + &blsp1_i2c3 { status = "okay"; @@ -321,6 +350,30 @@ &smbb { }; &tlmm { + accel_int_default: accel-int-default-state { + pins = "gpio63"; + function = "gpio"; + drive-strength = <2>; + bias-disable; + output-disable; + }; + + mag_int_default: mag-int-default-state { + pins = "gpio66"; + function = "gpio"; + drive-strength = <2>; + bias-disable; + output-disable; + }; + + mag_reset_default: mag-reset-default-state { + pins = "gpio62"; + function = "gpio"; + drive-strength = <2>; + bias-disable; + output-high; + }; + reg_lcd_default: reg-lcd-default-state { pins = "gpio31", "gpio33"; function = "gpio";