[PATCH v4 0/3] Add MAX14526 MUIC driver

Svyatoslav Ryhel clamor95 at gmail.com
Tue Apr 25 09:57:19 CEST 2023


MAX14526 MUIC is used by LG P880/P895 which are currently
in the process of merging.

MAX14526 is a powerful extcon device which has the ability to
accurately determine plugged devices. In this implementation
muic can be configured to represent 3 modes: CP-USB/UART and
AP-USB. Unfortunately AP-UART was disabled on P880/P895.
Additionally the driver configures some stuff required by
the charger.

Extcon class has empty platform struct and ops, all configuration
is performed in the probe. Filling of struct and ops is welcomed.

---
Changes from v3:
- fix typo in commit title
- added reviewed-by

Changes from v2:
- created a new simple extcon uclass

Changes from v1:
- used log_* instead of printf
- log messages made simpler
---

Svyatoslav Ryhel (3):
  dm: extcon: add an uclass for extcon
  test: Add tests for the extcon
  extcon: add MAX14526 MUIC support

 arch/sandbox/dts/test.dts        |   4 +
 drivers/Kconfig                  |   2 +
 drivers/Makefile                 |   1 +
 drivers/extcon/Kconfig           |  31 +++++++
 drivers/extcon/Makefile          |   7 ++
 drivers/extcon/extcon-max14526.c | 151 +++++++++++++++++++++++++++++++
 drivers/extcon/extcon-sandbox.c  |  17 ++++
 drivers/extcon/extcon-uclass.c   |  16 ++++
 include/dm/uclass-id.h           |   1 +
 include/extcon.h                 |  19 ++++
 test/dm/Makefile                 |   1 +
 test/dm/extcon.c                 |  21 +++++
 12 files changed, 271 insertions(+)
 create mode 100644 drivers/extcon/Kconfig
 create mode 100644 drivers/extcon/Makefile
 create mode 100644 drivers/extcon/extcon-max14526.c
 create mode 100644 drivers/extcon/extcon-sandbox.c
 create mode 100644 drivers/extcon/extcon-uclass.c
 create mode 100644 include/extcon.h
 create mode 100644 test/dm/extcon.c

-- 
2.39.2



More information about the U-Boot mailing list