]> git.kernelconcepts.de Git - karo-tx-uboot.git/commit
cros_ec: Support the LDO access method used by spring
authorSimon Glass <sjg@chromium.org>
Mon, 3 Aug 2015 14:19:24 +0000 (08:19 -0600)
committerLothar Waßmann <LW@KARO-electronics.de>
Thu, 10 Sep 2015 06:17:14 +0000 (08:17 +0200)
commit9daa9e0616934ab2425f2f2051615e8a23b4e912
treed61b56a4fa3e3c55218a6cb5ecc5717c2e6a952e
parentc667cba8e7eaa597fc3f9d7e8acdb95e909b8e0c
cros_ec: Support the LDO access method used by spring

Add a driver to support the special LDO access used by spring. This is a
custom method in the cros_ec protocol - it does not use an I2C
pass-through.

There are two implementation choices:

1. Write a special LDO driver which can talk across the EC. Duplicate all
the logic from TPS65090 for retrying when the LDO fails to come up.

2. Write a special I2C bus driver which pretends to be a TPS65090 and
transfers reads and writes using the LDO message.

Either is distasteful. The latter method is chosen since it results in less
code duplication and a fairly simple (30-line) implementation of the core
logic.

The crosec 'ldo' subcommand could be removed (since i2c md/mw will work
instead) but is retained as a convenience.

Signed-off-by: Simon Glass <sjg@chromium.org>
drivers/i2c/Kconfig
drivers/i2c/Makefile
drivers/i2c/cros_ec_ldo.c [new file with mode: 0644]
drivers/misc/cros_ec.c
include/cros_ec.h