From patchwork Mon Oct 5 15:03:01 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 11816763 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 79C5A13B2 for ; Mon, 5 Oct 2020 15:04:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5F333208A9 for ; Mon, 5 Oct 2020 15:04:28 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="eE5U32q4" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726748AbgJEPD3 (ORCPT ); Mon, 5 Oct 2020 11:03:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44686 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726637AbgJEPDZ (ORCPT ); Mon, 5 Oct 2020 11:03:25 -0400 Received: from mail-wr1-x432.google.com (mail-wr1-x432.google.com [IPv6:2a00:1450:4864:20::432]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 61A8EC0613CE; Mon, 5 Oct 2020 08:03:25 -0700 (PDT) Received: by mail-wr1-x432.google.com with SMTP id t9so1329994wrq.11; Mon, 05 Oct 2020 08:03:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=1RG5O/blRX088Gf+ChfJZxqZON6Zi0SmLcrgY0NHzZU=; b=eE5U32q4J8OCVWaOdW3/PJpFoCfS6AAVQm9eTgbi93rZR5nbVgvY6jg3wLTVSVzqA9 lDWl3Mfctfen6dcJAFhpEfB+vyb7XKf/EbbuNTvGn+OFCxUJ/Pe13Q7Wwzq0LT8Mv2eb J4NfeYRKR0zn184450Y/uR5sl+HIipqAcK8ZL1j1YIX+ywVpiZ7uXpJQQrfVnDKdUMpZ 58Dzomy4ER6t4+mB9laQoLcmoKk/WlIImrPWZnCa3GpVrpnpsjLb7obowoR1fAPU7l+J m5QIYvPibFXgbybuUtpJQJHY+2lu1oFsUyy+JukLW/rNG21ixCx81bgXO1XTvqhUJhir 55tw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=1RG5O/blRX088Gf+ChfJZxqZON6Zi0SmLcrgY0NHzZU=; b=hZNuPJYiJPWz/vlbvBFoUS7KyTveN1grbnkOqbIMD5HO2NaRN94EJ7YESV6IascsEW KLkXECNJ3F0AnMaZ6ASzx3Lu+UlKHAMJrmEz/ESp1uUgKc6j8B7CM7lr1KJlBZmMYO0N wFqpSe3h+NpTIsLv9mN/bAp2V0eUwogANSVIDl5z5lfJvAAJAcmT02kZcdm6bWsNM+ZB Uoa+bB9XsKaqNxP1bwxFepjNeSinRxymc6ClVVKo4zufeM8HqQRpFbAFQLVAdNNHF0Gu W29ZBkwASGiXBqOUvdfsSFNNv5XBAsgM1tmuLToYkp0FPPKgmZ0TXs1tbmCT8uTXnD9B tI0Q== X-Gm-Message-State: AOAM533zrAwokYKgwd6LGgOf0wodCCSUTY7mJ7neMatL2oOxrNLw2P0/ FaF5B5uHjqqOXfpWYsYHuBg= X-Google-Smtp-Source: ABdhPJytBOxbYlIVvXxNG0jVtNFycKep6mZQv1jCqxUnOC4v0KiopSbE4QroV2dV4BeZxqPSX/WQFg== X-Received: by 2002:adf:f4c6:: with SMTP id h6mr12104118wrp.310.1601910204126; Mon, 05 Oct 2020 08:03:24 -0700 (PDT) Received: from localhost.localdomain (abab191.neoplus.adsl.tpnet.pl. [83.6.165.191]) by smtp.googlemail.com with ESMTPSA id c132sm4662wmf.25.2020.10.05.08.03.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Oct 2020 08:03:23 -0700 (PDT) From: Konrad Dybcio To: konradybcio@gmail.com Cc: ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Andy Gross , Bjorn Andersson , Rob Herring , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 01/11] arm64: dts: qcom: pm8994: Add VADC node Date: Mon, 5 Oct 2020 17:03:01 +0200 Message-Id: <20201005150313.149754-2-konradybcio@gmail.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201005150313.149754-1-konradybcio@gmail.com> References: <20201005150313.149754-1-konradybcio@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Add VADC note and some of its channels to allow for voltage/temperature reading. Signed-off-by: Konrad Dybcio --- arch/arm64/boot/dts/qcom/pm8994.dtsi | 36 +++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/pm8994.dtsi b/arch/arm64/boot/dts/qcom/pm8994.dtsi index 7e4f777746cb..ea2a3d53f859 100644 --- a/arch/arm64/boot/dts/qcom/pm8994.dtsi +++ b/arch/arm64/boot/dts/qcom/pm8994.dtsi @@ -1,7 +1,8 @@ // SPDX-License-Identifier: GPL-2.0 +#include +#include #include #include -#include &spmi_bus { @@ -35,6 +36,39 @@ pwrkey { }; + pm8994_vadc: adc@3100 { + compatible = "qcom,spmi-vadc"; + reg = <0x3100>; + interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>; + #address-cells = <1>; + #size-cells = <0>; + #io-channel-cells = <1>; + + adc-chan@7 { + reg = ; + qcom,pre-scaling = <1 3>; + label = "vph_pwr"; + }; + adc-chan@8 { + reg = ; + label = "die_temp"; + }; + adc-chan@9 { + reg = ; + label = "ref_625mv"; + }; + adc-chan@a { + reg = ; + label = "ref_1250mv"; + }; + adc-chan@e { + reg = ; + }; + adc-chan@f { + reg = ; + }; + }; + pm8994_gpios: gpios@c000 { compatible = "qcom,pm8994-gpio"; reg = <0xc000>;