From patchwork Wed Nov 14 09:07:03 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 151052 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp5441488ljp; Wed, 14 Nov 2018 01:07:45 -0800 (PST) X-Google-Smtp-Source: AJdET5fwZezBP+MLqyh4wTWTM/brcwEIHQ1aSxweaj+CB4VfNI9BX9dd9POTXxY84WnyzLNgRivH X-Received: by 2002:a63:2bc9:: with SMTP id r192mr1032892pgr.172.1542186465233; Wed, 14 Nov 2018 01:07:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542186465; cv=none; d=google.com; s=arc-20160816; b=y1NTSMh9loCyEEJ3lihWYbZfwH1Vw3OU+H16+h+oKiOFcQbBuuCaiaFz3Du5hhIkNO 7FLPll9tL2jp2mdev+AHNKfU5KI4B7OdAtGC4VRU277x1IVRY9osDWSW6LMKXTBCvLQP fh7Mj1HrljWgFRvBsdHlptp0zON8CuXLvy9ppDDdcZjQxV5jEuiua0OUXNoFNaLuqChj 6DMjXAckuXnRYjmtVQkiDJt+fyL7J+QgWj0P59DYU66uzzEh7iWYHz6l43KZqUR9XA5Z MFz+c6Mvqg43s/TZtlw/3KLMJcY2dJDNatBCpdYsW4gKK5Y1voEpDhGrYNCjLqNtLWdk TkSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=6T859OE4NJWTqvgX+TL0bubLH0enxBhyUjtGnzBSLI0=; b=1Fft48kBlMHAlMxZM93RrLj+5BYLUUvePo1pX7+MkOv8HJOFnbzOgXRjXSh0E3oNIf wNIZh+T3IbEmrdR4chJ97U5EZqiFP0xh6ytyrU5kwCeVsDeoIzzcWkOsD0iEhc9NhO9Z MuymFBIi8EBq6HyW5Koq0zNJ6MCvFE2YbqYSAbeGTHSqnor/Pc8uEafVZ5ghjNk7+IcR gQBwZzbFe7T+XCbNLSqospdEQxQhe8STBK7qpH0ZE7TRsrYJmE+9nx3EZqLHU4TjTHNw mf1PA5yl974rK8KLTL42Qzaia+yAuHNPDtdVaK69OZBHs+nGwKcZyaNuP4W8RUdc2vhf vhjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Zps0wWv7; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id ca18-v6si25623306plb.261.2018.11.14.01.07.44; Wed, 14 Nov 2018 01:07:45 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Zps0wWv7; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729451AbeKNTKF (ORCPT + 6 others); Wed, 14 Nov 2018 14:10:05 -0500 Received: from mail-pl1-f195.google.com ([209.85.214.195]:36291 "EHLO mail-pl1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727776AbeKNTKF (ORCPT ); Wed, 14 Nov 2018 14:10:05 -0500 Received: by mail-pl1-f195.google.com with SMTP id w24-v6so7492238plq.3 for ; Wed, 14 Nov 2018 01:07:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=6T859OE4NJWTqvgX+TL0bubLH0enxBhyUjtGnzBSLI0=; b=Zps0wWv7/q7ZRQZ/iIe4l6G9gOy8DfuTwF5+MwHJD71ousE10RZOLRTwGN1HJWc09N n2juAVMnPBg+TCT3Khi77cMx/bUD9xoLHSdxKoXUXlOOzkhrOsBZNen+Fr1ZsoRVvzvv IVzTIoPjfi0hR1R3qZdwCGa3taAWv3pjcXYFY= 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; bh=6T859OE4NJWTqvgX+TL0bubLH0enxBhyUjtGnzBSLI0=; b=cn1wMnA+iNOshZD3gqdBRuzsPBgpRThgh9ZgZP0kXWU7lCEd5/9AlYbyUDKueynTZm HWEdRM25uP+al4F0+Ww002rJpmNuIh0W6axAGn6r2nCG9IEsfMlKYdg1eWE8J0mRdUZC cJ36lohvWl/HtguEf4/6jbRK54unmei/R5SbyHnrw2ASJBY9GLEQSQSPDv/n22lNuM+V iCehXMprqFWnNVrZ+AVF21/0iewjy1bMScEMCExGRl1mSpyfUcYAt3iSk1Os2jocMvC9 omCdfpIl9l6tjkqD772a4yvchwX+I8x9E6i43Mm7w3Bsnt9ryx6Kt61bpJganD5ihuVj iNXw== X-Gm-Message-State: AGRZ1gLCCc9Oxw4OtnCfYr1Pv6TR+W+yXIHvCsdNPQyiLITyEwGgpnhG dCF2gIUFv2nlpo5tyQ5Ov01HYQ== X-Received: by 2002:a17:902:a58a:: with SMTP id az10mr1115186plb.151.1542186463648; Wed, 14 Nov 2018 01:07:43 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.102]) by smtp.gmail.com with ESMTPSA id 127-v6sm25048814pfx.91.2018.11.14.01.07.40 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 14 Nov 2018 01:07:42 -0800 (PST) From: Baolin Wang To: sre@kernel.org, robh+dt@kernel.org, mark.rutland@arm.com Cc: linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, yuanjiang.yu@unisoc.com, baolin.wang@linaro.org, broonie@kernel.org Subject: [PATCH 0/5] Add new features for SC27XX fuel gauge driver Date: Wed, 14 Nov 2018 17:07:03 +0800 Message-Id: X-Mailer: git-send-email 1.7.9.5 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org This patch set adds some new features for SC27XX fuel gauge driver. 1. Read calibration data from eFuse device to calibrate fuel gauge. 2. Add low voltage alarm to adjust the battery capacity in lower voltage stage. 3. Add power management interfaces 4. Save last optimized battery capacity to be used as the initial battery capacity if system is not first power-on. Baolin Wang (2): dt-bindings: power: supply: Add nvmem properties to calibrate FGU power: supply: sc27xx: Add fuel gauge calibration Yuanjiang Yu (3): power: supply: sc27xx: Add fuel gauge low voltage alarm power: supply: sc27xx: Add suspend/resume interfaces power: supply: sc27xx: Save last battery capacity .../devicetree/bindings/power/supply/sc27xx-fg.txt | 4 + drivers/power/supply/sc27xx_fuel_gauge.c | 453 +++++++++++++++++++- 2 files changed, 444 insertions(+), 13 deletions(-) -- 1.7.9.5 Reviewed-by: Rob Herring