Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp601ybe; Tue, 10 Sep 2019 13:25:14 -0700 (PDT) X-Google-Smtp-Source: APXvYqw+WgWp54rDFYFB/42TWtOKTTbyFzWRpzNlC4Ob+POurWFPzaGhdwF0FOH6EXIbf6MZa5U6 X-Received: by 2002:a17:906:53c1:: with SMTP id p1mr26348913ejo.227.1568147113924; Tue, 10 Sep 2019 13:25:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568147113; cv=none; d=google.com; s=arc-20160816; b=hyIl3IgaQ7J3OOcRb4lt2RWGbfy0kM4ijkDbYn6Nyz5cY4ti+L0GxThoGCxKImR1NK 7YazIJLh43oWW/6ehLR4tNxy/kRLAwO/X7+/kxF29kQps8pJIg0ydwMqxIZeJ/aEIF4S 1pDXMVswfo2Zp3vI9gAuAvx4JLaFQ/wOn8biN2eXX1UOarBq+TN6vnr2BREMPyEfg9qn wx9cfuRouyM2yZAprlQRcyWEWWVphxo6YBs1KVQt6nMZrqQh3344Vl18A2B9UXkCbeMY t2hu2V0yAqX9DRnIXUu8g9YN1afFUiiVNinihyB2e5Nojf00r0tk6/8i4OSEsxoFKzrC r65g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=iO4sXiZllAyhfFkUiIY3RuYQeVAp8pbvG9rv+ztxnwQ=; b=muTZntoYnQ4oquElnGDMW/S/K18tNUUugfmMPdCk58QsQxa36vBLK9IKgyfhZLm2Eo /SHI6lumgI0pTuryDihn+FI8P+mK55FMOUeK7g3nS0kCY0ujiKRRm8BG8fyjfxvE7ZIn 3cCiIqHGNULqA4YphyhIglEczuoJIjygkrIvCHbVWUREuNli9xVm4EtHpVzhmuduepVH FhlSS42zzT+DREzdB95GeJ5P8hq6u5cSWGc9gaPrS+nVXMUqK5WnCPQ6x8xPwri0FSgP QlPrFjhOcwp6XtPpiAGr8d/2kFEsbkN7O5L/oYajcnJ7L/+NjkPtndhW/DjkSrTQ8oni nOhA== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id qq6si9654191ejb.209.2019.09.10.13.24.48; Tue, 10 Sep 2019 13:25:13 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726287AbfIJUJP (ORCPT + 99 others); Tue, 10 Sep 2019 16:09:15 -0400 Received: from cyberdimension.org ([80.67.179.20]:40988 "EHLO gnutoo.cyberdimension.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726108AbfIJUJP (ORCPT ); Tue, 10 Sep 2019 16:09:15 -0400 X-Greylist: delayed 398 seconds by postgrey-1.27 at vger.kernel.org; Tue, 10 Sep 2019 16:09:14 EDT Received: from gnutoo.cyberdimension.org (localhost [127.0.0.1]) by cyberdimension.org (OpenSMTPD) with ESMTP id b7f2586b; Tue, 10 Sep 2019 19:59:28 +0000 (UTC) Received: from primarylaptop.localdomain (localhost.localdomain [IPv6:::1]) by gnutoo.cyberdimension.org (OpenSMTPD) with ESMTP id 311edd07; Tue, 10 Sep 2019 19:59:28 +0000 (UTC) From: Denis 'GNUtoo' Carikli To: Chanwoo@gnutoo.cyberdimension.org, Choi@gnutoo.cyberdimension.org Cc: linux-kernel@vger.kernel.org, Paul Kocialkowski , Wolfgang Wiedmeyer , Denis 'GNUtoo' Carikli Subject: [PATCH 1/2] mfd: max77693: Add defines for charger current control Date: Tue, 10 Sep 2019 22:02:32 +0200 Message-Id: <20190910200233.3195-1-GNUtoo@cyberdimension.org> X-Mailer: git-send-email 2.23.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Wolfgang Wiedmeyer This prepares for an updated regulator and charger driver. The defines are needed to set the maximum input current and the fast charge current. Signed-off-by: Wolfgang Wiedmeyer GNUtoo@cyberdimension.org: small fix Signed-off-by: Denis 'GNUtoo' Carikli --- include/linux/mfd/max77693-private.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/linux/mfd/max77693-private.h b/include/linux/mfd/max77693-private.h index e798c81aec31..1853f8602f65 100644 --- a/include/linux/mfd/max77693-private.h +++ b/include/linux/mfd/max77693-private.h @@ -217,6 +217,9 @@ enum max77693_charger_battery_state { #define CHG_CNFG_01_CHGRSTRT_MASK (0x3 << CHG_CNFG_01_CHGRSTRT_SHIFT) #define CHG_CNFG_01_PQEN_MAKS BIT(CHG_CNFG_01_PQEN_SHIFT) +/* MAX77693_CHG_REG_CHG_CNFG_02 register */ +#define CHG_CNFG_02_CC_MASK 0x3F + /* MAX77693_CHG_REG_CHG_CNFG_03 register */ #define CHG_CNFG_03_TOITH_SHIFT 0 #define CHG_CNFG_03_TOTIME_SHIFT 3 @@ -245,6 +248,10 @@ enum max77693_charger_battery_state { /* MAX77693 CHG_CNFG_09 Register */ #define CHG_CNFG_09_CHGIN_ILIM_MASK 0x7F +#define CHG_CNFG_09_CHGIN_ILIM_500_MAX 500000 +#define CHG_CNFG_09_CHGIN_ILIM_500_MIN 470000 +#define CHG_CNFG_09_CHGIN_ILIM_0_MAX 60000 +#define CHG_CNFG_09_CHGIN_ILIM_0_MIN 0 /* MAX77693 CHG_CTRL Register */ #define SAFEOUT_CTRL_SAFEOUT1_MASK 0x3 -- 2.23.0