[U-Boot] [PATCH v3 01/10] dm: i2c: Add a uclass for I2C

Masahiro Yamada yamada.m at jp.panasonic.com
Tue Dec 2 05:35:51 CET 2014


Hi Simon,





On Mon, 1 Dec 2014 21:31:29 -0700
Simon Glass <sjg at chromium.org> wrote:

> +Heiko - are you OK with the new msg-based approach?

This approach looks much better to me.




> >> +     .name           = "i2c_generic_drv",
> >> +     .id             = UCLASS_I2C_GENERIC,
> >> +};
> >
> >
> > Can we move "i2c_generic" to a different file?
> > maybe, drivers/i2c/i2c-generic.c or drivers/i2c/i2c-generic-chip.c ?
> >
> > UCLASS_DRIVER(i2c) is a bus, whereas UCLASS_DRIVER(i2c_generic) is a chip.
> >
> > Mixing up a bus and a chip-device together in the same file
> > looks confusing to me.


I take back this comment.

I thought it again, and
"i2c_generic" is short enough to be included in i2c-uclass.c.
I am fine with it as is.


Best Regards
Masahiro Yamada



More information about the U-Boot mailing list