90c32e99d6
Utilization of chip interrupt line is mandatory to assure proper charger state control. Handle interrupt to prepare the driver for implementation of such functionality. Modify charger status update so the current state is fetched in the interrupt handler. Use level based interrupts combined with interrupt disabling for a period of time after interrupt handling to reduce number of interrupts triggered by the charger. There may be a case where the charger produces burst of interrupts for a several seconds and if the code attempts to handle every single interrupt separatery then the system might be significantly overloaded. Co-authored-by: Bartosz Bilas <b.bilas@grinn-global.com> Signed-off-by: Lukasz Madej <l.madej@grinn-global.com>
13 lines
277 B
Plaintext
13 lines
277 B
Plaintext
# Copyright 2023 Grinn
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
config CHARGER_MAX20335
|
|
bool "MAX20335 battery charger driver"
|
|
default y
|
|
depends on DT_HAS_MAXIM_MAX20335_CHARGER_ENABLED
|
|
select GPIO
|
|
select I2C
|
|
select MFD
|
|
help
|
|
Enable the MAX20335 battery charger driver.
|