From patchwork Fri Sep 2 08:42:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Kepplinger X-Patchwork-Id: 12963838 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 BE2B9C54EE9 for ; Fri, 2 Sep 2022 08:44:46 +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:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=osgO1N9AJVSyeKkGDyTjvzhWz2mkqWmYLlE5m0+Y4SQ=; b=isfH0e8tJgXU6A sfyeEMLqqzMG8Jhhx5m0zybcNlgP0MgHiZ9/IlMdPgLNtFHl7FyuL9T7V/yzbfzGhe03boOTMnKnS UwxcvM3gYQuyVUACyAuBXh0OowR/RjiK4IREEOBHerZpZ8qVsHXJV5tkxyDXDfEjakDwI5y7OUsmO kFfG3ZE2ILhECMIdn4Im/akzI0XKyPHVuFBIuTE8f29e3q7JcDSenwDDa6jBigd2vO4tq4+eQ2pE4 Ec/WH+5q9FpYj6/0xOsNh6PC2vMafINUQeQVx1RqCr+kS3k/0WM9M00cVYt4Vw/s1fwjSJKyXd87M GPBdTOqLrXrvEYih77CA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oU2HB-0021He-Fd; Fri, 02 Sep 2022 08:43:45 +0000 Received: from comms.puri.sm ([159.203.221.185]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oU2GY-0020k9-W8 for linux-arm-kernel@lists.infradead.org; Fri, 02 Sep 2022 08:43:08 +0000 Received: from localhost (localhost [127.0.0.1]) by comms.puri.sm (Postfix) with ESMTP id C9FFBDFE53; Fri, 2 Sep 2022 01:42:36 -0700 (PDT) Received: from comms.puri.sm ([127.0.0.1]) by localhost (comms.puri.sm [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GKgNz54uSPJW; Fri, 2 Sep 2022 01:42:36 -0700 (PDT) From: Martin Kepplinger DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=puri.sm; s=comms; t=1662108156; bh=KUxiFlsvpcd+F5TUJQ2y/X50YrcqnyZ008WHXZXuiUc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ep+tjQXP1ddXX5tsKpXiburC+cb0chbIauIEUqek9UVqh2FrMbc7BHNcrL40plePt 3OpHkzaGEzOy75w9UVYjGYNh843PYqEkO3Igq69mhrIaZ2N2C4E3JI/BBhKoiiODxF A3L+WU6WVG17h8PyJYtIbOG7sQK3Lw8Lw4zl7ES8cvmc3k2zgFS/b+cE/VXT+eh1q3 kynz+s1JBaCBcdbhAxwb7KbEcFQmkBSdyICw2mq7QiQUAEhOqJn8RvCvarXIm2i6mS Aq8LvqhXW476jRbtZCcb4h2O8vucT077cUzvTmD2EHu19SfwhmQpL3Glzsse+V6hpU WK+z0orkXom6w== To: festevam@gmail.com, shawnguo@kernel.org Cc: martin.kepplinger@puri.sm, devicetree@vger.kernel.org, kernel@pengutronix.de, kernel@puri.sm, krzk@kernel.org, linux-arm-kernel@lists.infradead.org, linux-imx@nxp.com, linux-kernel@vger.kernel.org, phone-devel@vger.kernel.org, robh@kernel.org, Sebastian Krzyszkowiak Subject: [PATCH v2 3/6] arm64: dts: imx8mq-librem5: Add bq25895 as max17055's power supply Date: Fri, 2 Sep 2022 10:42:13 +0200 Message-Id: <20220902084216.1259202-4-martin.kepplinger@puri.sm> In-Reply-To: <20220902084216.1259202-1-martin.kepplinger@puri.sm> References: <20220902084216.1259202-1-martin.kepplinger@puri.sm> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220902_014307_076141_17CF8F33 X-CRM114-Status: UNSURE ( 8.30 ) X-CRM114-Notice: Please train this message. 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 From: Sebastian Krzyszkowiak This allows the userspace to notice that there's not enough current provided to charge the battery, and also fixes issues with 0% SOC values being considered invalid. Signed-off-by: Sebastian Krzyszkowiak Signed-off-by: Martin Kepplinger --- arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi index 8da7b87c1aa1f..7e6c4ad438092 100644 --- a/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8mq-librem5.dtsi @@ -1109,6 +1109,7 @@ bat: fuel-gauge@36 { interrupts = <20 IRQ_TYPE_LEVEL_LOW>; pinctrl-names = "default"; pinctrl-0 = <&pinctrl_gauge>; + power-supplies = <&bq25895>; maxim,over-heat-temp = <700>; maxim,over-volt = <4500>; maxim,rsns-microohm = <5000>;