Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp3061612imj; Mon, 18 Feb 2019 18:51:06 -0800 (PST) X-Google-Smtp-Source: AHgI3Ibby+K1ufqtq7OSWs3HQG1SKT8Zk8AZ6mcU0NWsBZJ9kkiDYY67aUh4pGSy/Gr4RQG6oR01 X-Received: by 2002:a63:1b49:: with SMTP id b9mr21821100pgm.112.1550544666838; Mon, 18 Feb 2019 18:51:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550544666; cv=none; d=google.com; s=arc-20160816; b=i2LuuyhZcjIaC6eZnl4SdClG08Vip4n2RdI1N16IzGRvGXFEl1gPDbw3fXyObgCgw3 ACEsvozeBmUOvPC25CkTpllW0DKsErcIo5TWN93QrOV6J6taDiX7wWQPvMZE0gvhsaye X++58tnsxkS7DGW3JI69b3/ju+WUTcXtbkREGNXn9YJtO+Q81ZK/avNNiIeGM7lQCVIK wQmcrOUDoYCGg3yaHSolnnaNS2Xaj7TQzU9KKkCVJLdeX2R9gzASGGzCuzcyKOLQOy1E X7Bm7R7pSxJ3TjOOh3rG/Bf5pgg1VOm20zQ+/3WXN+UgwdrqZXYp29uhnfD0/eHYRLJb LlFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:dkim-signature:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=u04421xOHlorr7fOQ/enfO8bj267alBHi9ZeDwY2PIY=; b=eN7pJc41L+t8NU5nhhack9odYuokToGlQc9MtBRSmAumBqJ8oZyS3XBC/fHW8b+QRn pVNXR/GLR71DsQFAxHpCWvruni3wwJ3ePG9ctfdWW7gJ8TOe0FPqSxeRzdwPUogwNdk9 5zZZ48ZH62VsNPYbINnSXs1Mm7Lvs5CBE6idw1viHqOorpfY98nsvK6+Neex7O6zu+JD YK38j+WFKcW1o6kRoyFIXzRI2PzlymwzzJFwiB2zPMEI3Zc2yU/m2PKgq/K+zcVKM/H6 w9AZoMaekJYHqZZx2v/2HWjPvNbi38JfjHzWFzL+ht2kQwh27woHKYp5kG1pZTyQ+Qnu 2zdA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nvidia.com header.s=n1 header.b=hAuIREPF; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t3si3114944plq.430.2019.02.18.18.50.51; Mon, 18 Feb 2019 18:51:06 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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=@nvidia.com header.s=n1 header.b=hAuIREPF; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725989AbfBSCHc (ORCPT + 99 others); Mon, 18 Feb 2019 21:07:32 -0500 Received: from hqemgate16.nvidia.com ([216.228.121.65]:14004 "EHLO hqemgate16.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725766AbfBSCHb (ORCPT ); Mon, 18 Feb 2019 21:07:31 -0500 Received: from hqpgpgate101.nvidia.com (Not Verified[216.228.121.13]) by hqemgate16.nvidia.com (using TLS: TLSv1.2, DES-CBC3-SHA) id ; Mon, 18 Feb 2019 18:07:34 -0800 Received: from hqmail.nvidia.com ([172.20.161.6]) by hqpgpgate101.nvidia.com (PGP Universal service); Mon, 18 Feb 2019 18:07:29 -0800 X-PGP-Universal: processed; by hqpgpgate101.nvidia.com on Mon, 18 Feb 2019 18:07:29 -0800 Received: from [192.168.88.246] (172.20.13.39) by HQMAIL101.nvidia.com (172.20.187.10) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Tue, 19 Feb 2019 02:07:27 +0000 Subject: Re: [PATCH v3 2/4] mfd: max77620: add documentation for backup battery charging To: Rob Herring , Bartosz Golaszewski CC: Lee Jones , Mark Rutland , , "linux-kernel@vger.kernel.org" , References: <20190212064353.7451-1-markz@nvidia.com> <20190212064353.7451-3-markz@nvidia.com> From: Mark Zhang Message-ID: <91d3d8f8-0b96-c442-5674-3eff8209848b@nvidia.com> Date: Tue, 19 Feb 2019 10:07:23 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.5.0 MIME-Version: 1.0 In-Reply-To: X-Originating-IP: [172.20.13.39] X-ClientProxiedBy: HQMAIL106.nvidia.com (172.18.146.12) To HQMAIL101.nvidia.com (172.20.187.10) Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1550542054; bh=u04421xOHlorr7fOQ/enfO8bj267alBHi9ZeDwY2PIY=; h=X-PGP-Universal:Subject:To:CC:References:From:Message-ID:Date: User-Agent:MIME-Version:In-Reply-To:X-Originating-IP: X-ClientProxiedBy:Content-Type:Content-Language: Content-Transfer-Encoding; b=hAuIREPFRbHgc+z7Om7FOiY0oQ09HeNJ6uDF3FsysMkDjoSMdkq499Iti1A4ERGQU /OlDDJ0RPtrDOFpT47Wblxw4A6MT9y6C0d3FCNw76DgwPurGg8znfEnCa8eAyc6XK6 6vjx4WFvjSXnqQiSOAQ6mER96xc4V1lD/rO+MCIXRoobVFDgmyCa3hsgapSCm0V0Ri TFXvExj988NK3K6nusH/suNPdnNtdgP0/q1llCfr/HvuuFnjWWRJTXN52qXYY0IdyY n4PVydVUUrzvGHIEnjd9OPmhgchlVqfaOfnoLWptSbPEqLAlT7nsw8wYarK8VYhyxE hdVzzfoehc4UA== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2/19/2019 2:06 AM, Rob Herring wrote: > On Tue, Feb 12, 2019 at 12:44 AM Mark Zhang wrote: >> >> Adding documentation for 3 new backup battery charging dts >> properties: >> - maxim,charging-current-microamp >> - maxim,charging-voltage-microvolt >> - maxim,output-resister-ohms > > What's the difference between the 77620 and 77650 as there's patches > on the list for the 77650 too. The properties are similar, but seems > to be main vs. backup battery charger. We should have common > properties for this. Rob, it's different. The RTC in max77620 is supplied from a backup battery and consumes 2.0uA (IBBATT) when no other power sources are available. So unlike max77620 battery charging, which provides features like: static enum power_supply_property max77650_charger_properties[] = { POWER_SUPPLY_PROP_STATUS, POWER_SUPPLY_PROP_ONLINE, POWER_SUPPLY_PROP_CHARGE_TYPE }; For backup battery charging in max77620, what we can do is just setting those 3 parameters. We don't know whether it's charging, whether the backup battery is online, the percentage of the charging progress, and etc. That's why I mentioned before that it's not appropriate to create it as a power supply driver. Mark > >> Signed-off-by: Mark Zhang >> --- >> .../devicetree/bindings/mfd/max77620.txt | 20 +++++++++++++++++++ >> 1 file changed, 20 insertions(+) >> >> diff --git a/Documentation/devicetree/bindings/mfd/max77620.txt b/Documentation/devicetree/bindings/mfd/max77620.txt >> index 9c16d51cc15b..88825eaf2567 100644 >> --- a/Documentation/devicetree/bindings/mfd/max77620.txt >> +++ b/Documentation/devicetree/bindings/mfd/max77620.txt >> @@ -122,6 +122,26 @@ For DT binding details of different sub modules like GPIO, pincontrol, >> regulator, power, please refer respective device-tree binding document >> under their respective sub-system directories. >> >> +Backup Battery: >> +============== >> +This sub-node configure charging backup battery of the device. Device has >> +support of charging the backup battery. The subnode name is "backup-battery". >> +The property for backup-battery child nodes as: >> +Presence of this child node will enable the backup battery charging. >> + >> +Optional properties: >> + -maxim,charging-current-microamp: Charging current setting. >> + The device supports 50/100/200/400/600/800uA. >> + If this property is unavailable then it will >> + charge with 50uA. >> + -maxim,charging-voltage-microvolt: Charging Voltage Limit Setting. >> + Device supports 2500000/3000000/3300000/350000uV. >> + Default will be set to 2500mV. The voltage will be roundoff >> + to nearest lower side if other than above is configured. >> + -maxim,output-resister-ohms: Output resistor on Ohm. >> + Device supports 100/1000/3000/6000 Ohms. >> + Default will be set to 1000 Ohm. >> + >> Example: >> -------- >> #include >> -- >> 2.19.2 >>