Hi Tom, On 7/10/2026 3:50 PM, Tom Rini wrote: > On Thu, Jul 09, 2026 at 09:12:24AM +0200, Jonas Karlman wrote: >> Hi Tom, >> >> On 7/9/2026 3:52 AM, Tom Rini wrote: >>> On Wed, Jul 08, 2026 at 10:05:34PM +0000, Jonas Karlman wrote: >>> >>>> Change to depend on the xPL symbol instead of the SUPPORT_xPL symbol to >>>> only make the xPL_SYS_I2C_LEGACY symbols available when xPL is enabled. >>>> >>>> Signed-off-by: Jonas Karlman <[email protected]> >>>> --- >>>> drivers/i2c/Kconfig | 4 ++-- >>>> 1 file changed, 2 insertions(+), 2 deletions(-) >>>> >>>> diff --git a/drivers/i2c/Kconfig b/drivers/i2c/Kconfig >>>> index ab5af17858c8..125dc84819e6 100644 >>>> --- a/drivers/i2c/Kconfig >>>> +++ b/drivers/i2c/Kconfig >>>> @@ -78,14 +78,14 @@ config SYS_I2C_LEGACY >>>> >>>> config SPL_SYS_I2C_LEGACY >>>> bool "Enable legacy I2C subsystem and drivers in SPL" >>>> - depends on SUPPORT_SPL && !SPL_DM_I2C >>>> + depends on SPL && !SPL_DM_I2C >>>> help >>>> Enable the legacy I2C subsystem and drivers in SPL. This is useful >>>> in some size constrained situations. >>>> >>>> config TPL_SYS_I2C_LEGACY >>>> bool "Enable legacy I2C subsystem and drivers in TPL" >>>> - depends on SUPPORT_TPL && !SPL_DM_I2C >>>> + depends on TPL && !TPL_DM_I2C >>>> help >>>> Enable the legacy I2C subsystem and drivers in TPL. This is useful >>>> in some size constrained situations. >>> >>> Building on the last email, I think these might need to be >>> [ST]PL_FRAMEWORK not [ST]PL. >>> >> >> I have mostly tested this series with additional changes that alias >> putc()/puts() to printch()/printascii() in xPL builds when >> common/console.o is unavailable and DEBUG_UART=y, patches that will >> be sent as a separate series. >> >> It is possible such change may have hidden some latent issues, now >> trying to push a branch that contains changes that ends at the patches >> included in this series, but due to timeouts it was not possible prior >> to sending this reply. >> >> This patch can also be dropped if it causes any issues, I only added it >> after a search for SUPPORT_xPL and noticed that these depends seem to be >> incorrect. SUPPORT_xPL is used to tell if xPL can be enabled or not, >> not if xPL is enabled/disabled. > > I don't want to drop this, but there are a handful of platforms that > change: > 10: Kconfig: i2c: Depend on correct xPL symbol > aarch64: (for 1/1 boards) all -60.0 text -60.0 > ls1043aqds_tfa : all -60 text -60 > u-boot: add: 0/-1, grow: 0/-1 bytes: 0/-60 (-60) > function old new > delta > board_early_init_f 68 64 > -4 > i2c_early_init_f 56 - > -56 > > Can you please look in to it and see what needs to be changed? Thanks.
>From a quick look this size change may be caused due to use of an 'imply SPL_SYS_I2C_LEGACY' instead of using an 'imply SYS_I2C_LEGACY' in arch/arm/cpu/armv8/fsl-layerscape/Kconfig. 'config MACH_SUN8I_R40' is another platform that also possible miss an 'imply SYS_I2C_LEGACY' to match other similar sunxi platforms. Building this target I also noticed some more SPL_<name> symbols that may be missing a 'depends on SPL': > grep CONFIG_SPL .config # CONFIG_SPL_SYS_L2_PL310 is not set # CONFIG_SPL is not set # CONFIG_SPL_SYS_STDIO_DEREGISTER is not set # CONFIG_SPL_NVMEM is not set CONFIG_SPL_SYS_NAND_SELF_INIT=y # CONFIG_SPL_PHY_ATHEROS is not set # CONFIG_SPL_PHY_TI_DP83867 is not set # CONFIG_SPL_LZMA_SIZE_OPTIMIZATION is not set Should possible add 'depends on' to some of them in a v2. Regards, Jonas

