On 9/17/25 12:15 PM, Fenglin Wu via B4 Relay wrote:
From: Fenglin Wu <redacted>
The X1E80100 battery management firmware sends a notification with
code 0x83 when the battery charging state changes, such as switching
between fast charge, taper charge, end of charge, or any other error
charging states. The same notification code is used with bit[16] set
if charging stops due to reaching the charge control end threshold.
Additionally, a 2-bit value is added in bit[18:17] with the same code
and used to indicate the charging source capability: a value of 2
represents a strong charger, 1 is a weak charger, and 0 is no charging
source. The 3-MSB [18:16] in the notification code is not much useful
for now, hence just ignore them and trigger a power supply change event
whenever 0x83 notification code is received. This helps to eliminate the
unknown notification error messages.
Thank you for explaining the technical background.
Please hit enter somewhere in your commit message, this is a very
long paragraph, making it difficult to read.
I believe this maps to:
0 -> POWER_SUPPLY_CHARGE_TYPE_NONE
1 -> POWER_SUPPLY_CHARGE_TYPE_TRICKLE
2 -> POWER_SUPPLY_CHARGE_TYPE_FAST (or _STANDARD, I see battmgr code
reports them both as 2)
However, we already set it to none/trickle/standard(taper) based on
the usual notifications, so I'm not sure if these are more common or
arrive outside the normal state changes - if so, perhaps we can take
them into account as well?
I think it also warrants a:
Reported-by: Sebastian Reichel <redacted>
Konrad