[RFC PATCH v1 1/2] dm: i2c: allow disabling driver model in SPL

Heiko Schocher hs at denx.de
Mon Feb 8 13:56:35 CET 2021


Hello Igor,

On 05.02.21 16:10, Igor Opaniuk wrote:
> From: Igor Opaniuk <igor.opaniuk at foundries.io>
> 
> At present if U-Boot proper uses driver model for I2C, then SPL has to
> also. While this is desirable, it places a significant barrier to moving
> to driver model in some cases. For example, with a space-constrained SPL
> it may be necessary to enable CONFIG_SPL_OF_PLATDATA which involves
> adjusting some drivers.
> 
> This patch introduces a separate Kconfig symbols for enabling DM_I2C and
> DM_I2C_GPIO support in SPL.
> 
> This will also help to get away from dirty workarounds to
> achieve non-DM I2C support for SPL, which is currently used in some
> board header files like:
> 
> ifdef CONFIG_SPL_BUILD
> undef CONFIG_DM_I2C
> endif
> 
> Signed-off-by: Igor Opaniuk <igor.opaniuk at foundries.io>
> ---
> 
>  drivers/i2c/Kconfig   | 21 +++++++++++++++++++++
>  drivers/i2c/Makefile  |  4 ++--
>  drivers/misc/Makefile |  2 +-
>  3 files changed, 24 insertions(+), 3 deletions(-)

Reviewed-by: Heiko Schocher <hs at denx.de>

bye,
Heiko
-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-52   Fax: +49-8142-66989-80   Email: hs at denx.de


More information about the U-Boot mailing list