[U-Boot] [PATCH 2/2] dm: i2c: Add a compatbility layer

Simon Glass sjg at chromium.org
Wed Jan 21 01:36:22 CET 2015


On 12 January 2015 at 18:02, Simon Glass <sjg at chromium.org> wrote:
> For boards which use multiple I2C devices, or for SOCs which support
> multiple boards, we might want to convert these to driver model at different
> times. At present this is difficult because we need to either use
> CONFIG_DM_I2C for a board or not.
>
> Add a compatibility layer which implements the old API, thus allowing a
> board to move to driver model for I2C without requiring that everything it
> uses is moved in the same commit.
>
> Signed-off-by: Simon Glass <sjg at chromium.org>
> ---
>
>  Makefile                        |  7 +++
>  drivers/i2c/Makefile            |  1 +
>  drivers/i2c/i2c-uclass-compat.c | 98 +++++++++++++++++++++++++++++++++++++++++
>  include/i2c.h                   | 59 +++++++++++++++++++++++++
>  4 files changed, 165 insertions(+)
>  create mode 100644 drivers/i2c/i2c-uclass-compat.c
>

Applied to u-boot-dm.


More information about the U-Boot mailing list