Skip to content

Commit ff87f0c

Browse files
author
Al Stone
committed
power: supply: Introduces bypass charging property
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2071846 Tested: This is one of a series of patch sets to enable Arm SystemReady IR support in the kernel for NXP i.MX8 platforms. This set updates the power subsystem. This set has been tested via simple boot tests and the CI loop. commit 05f2281 Author: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com> Date: Mon Feb 14 18:07:56 2022 -0600 power: supply: Introduces bypass charging property Adds a POWER_SUPPLY_CHARGE_TYPE_BYPASS option to the POWER_SUPPLY_PROP_CHARGE_TYPE property to facilitate bypass charging operation. In bypass charging operation, the charger bypasses the charging path around the integrated converter allowing for a "smart" wall adaptor to perform the power conversion externally. This operational mode is critical for the USB PPS standard of power adaptors and is becoming a common feature in modern charging ICs such as: - BQ25980 - BQ25975 - BQ25960 - LN8000 - LN8410 Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com> Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com> (cherry picked from commit 05f2281) Signed-off-by: Al Stone <ahs3@redhat.com>
1 parent 97361c3 commit ff87f0c

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

Documentation/ABI/testing/sysfs-class-power

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -380,13 +380,16 @@ Description:
380380
algorithm to adjust the charge rate dynamically, without
381381
any user configuration required. "Custom" means that the charger
382382
uses the charge_control_* properties as configuration for some
383-
different algorithm.
383+
different algorithm. "Bypass" means the charger bypasses the
384+
charging path around the integrated converter allowing for a
385+
"smart" wall adaptor to perform the power conversion
386+
externally.
384387

385388
Access: Read, Write
386389

387390
Valid values:
388391
"Unknown", "N/A", "Trickle", "Fast", "Standard",
389-
"Adaptive", "Custom"
392+
"Adaptive", "Custom", "Bypass"
390393

391394
What: /sys/class/power_supply/<supply_name>/charge_term_current
392395
Date: July 2014

drivers/power/supply/power_supply_sysfs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ static const char * const POWER_SUPPLY_CHARGE_TYPE_TEXT[] = {
8989
[POWER_SUPPLY_CHARGE_TYPE_ADAPTIVE] = "Adaptive",
9090
[POWER_SUPPLY_CHARGE_TYPE_CUSTOM] = "Custom",
9191
[POWER_SUPPLY_CHARGE_TYPE_LONGLIFE] = "Long Life",
92+
[POWER_SUPPLY_CHARGE_TYPE_BYPASS] = "Bypass",
9293
};
9394

9495
static const char * const POWER_SUPPLY_HEALTH_TEXT[] = {

include/linux/power_supply.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ enum {
4949
POWER_SUPPLY_CHARGE_TYPE_ADAPTIVE, /* dynamically adjusted speed */
5050
POWER_SUPPLY_CHARGE_TYPE_CUSTOM, /* use CHARGE_CONTROL_* props */
5151
POWER_SUPPLY_CHARGE_TYPE_LONGLIFE, /* slow speed, longer life */
52+
POWER_SUPPLY_CHARGE_TYPE_BYPASS, /* bypassing the charger */
5253
};
5354

5455
enum {

0 commit comments

Comments
 (0)