From: Baolin Wang <baolin.wang@linaro.org>
To: robh+dt@kernel.org, mark.rutland@arm.com, arnd@arndb.de
Cc: olof@lixom.net, orsonzhai@gmail.com, zhang.lyra@gmail.com,
devicetree@vger.kernel.org, arm@kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, broonie@kernel.org,
baolin.wang@linaro.org
Subject: [PATCH v2 4/5] arm64: dts: sprd: Add SC27XX fuel gauge device
Date: Wed, 13 Feb 2019 20:32:48 +0800 [thread overview]
Message-ID: <46be35679912ffa446d67bb9b81f0cee065c1ca2.1550060544.git.baolin.wang@linaro.org> (raw)
In-Reply-To: <cover.1550060543.git.baolin.wang@linaro.org>
In-Reply-To: <cover.1550060543.git.baolin.wang@linaro.org>
Add Spreadtrum SC27XX fuel gauge device node to calculate the
battery capacity.
Signed-off-by: Baolin Wang <baolin.wang@linaro.org>
---
arch/arm64/boot/dts/sprd/sc2731.dtsi | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/arch/arm64/boot/dts/sprd/sc2731.dtsi b/arch/arm64/boot/dts/sprd/sc2731.dtsi
index dbf6242..4a79ddf 100644
--- a/arch/arm64/boot/dts/sprd/sc2731.dtsi
+++ b/arch/arm64/boot/dts/sprd/sc2731.dtsi
@@ -70,6 +70,11 @@
#size-cells = <1>;
hwlocks = <&hwlock 12>;
+ fgu_calib: calib@6 {
+ reg = <0x6 0x2>;
+ bits = <0 9>;
+ };
+
adc_big_scale: calib@24 {
reg = <0x24 0x2>;
};
@@ -90,6 +95,19 @@
nvmem-cells = <&adc_big_scale>, <&adc_small_scale>;
};
+ fgu@a00 {
+ compatible = "sprd,sc2731-fgu";
+ reg = <0xa00>;
+ bat-detect-gpio = <&pmic_eic 9 GPIO_ACTIVE_HIGH>;
+ io-channels = <&pmic_adc 3>, <&pmic_adc 6>;
+ io-channel-names = "bat-temp", "charge-vol";
+ monitored-battery = <&bat>;
+ nvmem-cell-names = "fgu_calib";
+ nvmem-cells = <&fgu_calib>;
+ interrupt-parent = <&sc2731_pmic>;
+ interrupts = <4>;
+ };
+
vibrator@ec8 {
compatible = "sprd,sc27xx-vibrator", "sprd,sc2731-vibrator";
reg = <0xec8>;
--
1.7.9.5
next prev parent reply other threads:[~2019-02-13 12:34 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-13 12:32 [PATCH v2 0/5] Add new device nodes for Spreadtrum SC9860 platform Baolin Wang
2019-02-13 12:32 ` [PATCH v2 1/5] arm64: dts: sprd: Remove PMIC INTC irq trigger type Baolin Wang
2019-02-13 12:32 ` [PATCH v2 2/5] arm64: dts: sprd: Add ADC calibration support Baolin Wang
2019-02-13 12:32 ` [PATCH v2 3/5] arm64: dts: sprd: Add SC2731 charger device Baolin Wang
2019-02-13 12:32 ` Baolin Wang [this message]
2019-02-13 12:32 ` [PATCH v2 5/5] arm64: dts: sprd: Remove wildcard compatible string Baolin Wang
2019-02-13 14:31 ` Arnd Bergmann
2019-02-14 1:56 ` Baolin Wang
2019-02-18 10:34 ` Arnd Bergmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=46be35679912ffa446d67bb9b81f0cee065c1ca2.1550060544.git.baolin.wang@linaro.org \
--to=baolin.wang@linaro.org \
--cc=arm@kernel.org \
--cc=arnd@arndb.de \
--cc=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=olof@lixom.net \
--cc=orsonzhai@gmail.com \
--cc=robh+dt@kernel.org \
--cc=zhang.lyra@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).