From patchwork Tue Mar 10 21:27:25 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Belisko X-Patchwork-Id: 5980621 Return-Path: X-Original-To: patchwork-linux-omap@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 8F739BF6C3 for ; Tue, 10 Mar 2015 21:28:21 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B1A1720220 for ; Tue, 10 Mar 2015 21:28:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D5E172024D for ; Tue, 10 Mar 2015 21:28:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932097AbbCJV2I (ORCPT ); Tue, 10 Mar 2015 17:28:08 -0400 Received: from mail-wg0-f50.google.com ([74.125.82.50]:42973 "EHLO mail-wg0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753572AbbCJV2E (ORCPT ); Tue, 10 Mar 2015 17:28:04 -0400 Received: by wggy19 with SMTP id y19so4784908wgg.9; Tue, 10 Mar 2015 14:28:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=Jj7znJKFj46X7nFpOdcndEtb6tKv3rV1c20SLFEfWy8=; b=sechicsxrme4+fvZ75ikpj+dQBA1GSnHNgFt6qvk0ZzUlhitAfQrzLM4hmr4pcc8SN TQaLd6/HeshxJDN8il7/QH+zt/VRwCwbdQnYX6JMDznXV9AlkqqiCintfcjmQ4AfKSnz 76cJWQJ41JTxV7NpDlGx8gRIBGuOlVvTGvy13BqQwYqwJEQkCVu46c/fDk62eEBS0e07 AzeWja2gOgBBqXFXTjJ8veVzs7F4EW08vWqFBeAwAtNCp7ty1w1xEoQXk7/sgkh0iw1h 53DGcHxSeler/k6MmJBgAMKuaKS4j1bdO6S1K27v7rxBol+9VcLcm7ze4Mz40BQeKR/2 sikQ== X-Received: by 10.180.184.169 with SMTP id ev9mr50136363wic.76.1426022881376; Tue, 10 Mar 2015 14:28:01 -0700 (PDT) Received: from marek.lan (ip-85.163.101.103.o2inet.sk. [85.163.101.103]) by mx.google.com with ESMTPSA id nb18sm3311653wic.3.2015.03.10.14.27.57 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 10 Mar 2015 14:28:00 -0700 (PDT) From: Marek Belisko To: bcousson@baylibre.com, tony@atomide.com, sre@kernel.org, dbaryshkov@gmail.com, dwmw2@infradead.org Cc: robh+dt@kernel.org, pawel.moll@arm.com, mark.rutland@arm.com, ijc+devicetree@hellion.org.uk, galak@codeaurora.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-pm@vger.kernel.org, hns@goldelico.com, Marek Belisko Subject: [PATCH v4 4/6] ARM: dts: omap3-gta04: Add battery support Date: Tue, 10 Mar 2015 22:27:25 +0100 Message-Id: <1426022847-30912-5-git-send-email-marek@goldelico.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1426022847-30912-1-git-send-email-marek@goldelico.com> References: <1426022847-30912-1-git-send-email-marek@goldelico.com> Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID,T_RP_MATCHES_RCVD,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Added battery support for gta04 devices. Signed-off-by: Marek Belisko --- arch/arm/boot/dts/omap3-gta04.dtsi | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/arch/arm/boot/dts/omap3-gta04.dtsi b/arch/arm/boot/dts/omap3-gta04.dtsi index fb3a696..cbf515a 100644 --- a/arch/arm/boot/dts/omap3-gta04.dtsi +++ b/arch/arm/boot/dts/omap3-gta04.dtsi @@ -49,6 +49,32 @@ ti,codec = <&twl_audio>; }; + battery { + compatible = "ti,twl4030-madc-battery"; + capacity-uah = <1200000>; + ti,volt-to-capacity-charging-map = <4200 100>, + <4100 75>, + <4000 55>, + <3900 25>, + <3800 5>, + <3700 2>, + <3600 1>, + <3300 0>; + ti,volt-to-capacity-discharging-map = <4200 100>, + <4100 95>, + <4000 70>, + <3800 50>, + <3700 10>, + <3600 5>, + <3300 0>; + io-channels = <&twl_madc 1>, + <&twl_madc 10>, + <&twl_madc 12>; + io-channel-names = "temp", + "ichg", + "vbat"; + }; + spi_lcd { compatible = "spi-gpio"; #address-cells = <0x1>; @@ -518,3 +544,7 @@ &mcbsp2 { status = "okay"; }; + +&twl_madc { + ti,system-uses-second-madc-irq; +};