Hi Jonas, On Thu, 26 Sept 2024 at 18:13, Jonas Karlman <jo...@kwiboo.se> wrote: > > Hi Simon, > > On 2024-09-27 00:35, Simon Glass wrote: > > Now that SPL means SPL (only) and is not defined for TPL, simplify some > > checks for SPL. > > > > Signed-off-by: Simon Glass <s...@chromium.org> > > --- > > > > arch/arm/include/asm/arch-rockchip/boot0.h | 3 +-- > > arch/arm/mach-rockchip/rk3399/rk3399.c | 2 +- > > drivers/clk/rockchip/clk_rk3368.c | 8 ++++---- > > drivers/ram/rockchip/sdram_rk3288.c | 10 +++++----- > > drivers/ram/rockchip/sdram_rk3399.c | 2 +- > > drivers/ram/rockchip/sdram_rv1126.c | 9 +++------ > > 6 files changed, 15 insertions(+), 19 deletions(-) > > > > diff --git a/arch/arm/include/asm/arch-rockchip/boot0.h > > b/arch/arm/include/asm/arch-rockchip/boot0.h > > index edb2a31c348..918f0495fa0 100644 > > --- a/arch/arm/include/asm/arch-rockchip/boot0.h > > +++ b/arch/arm/include/asm/arch-rockchip/boot0.h > > @@ -54,7 +54,6 @@ _start: > > ARM_VECTORS > > #endif > > > > -#if !defined(CONFIG_TPL_BUILD) && defined(CONFIG_XPL_BUILD) && \ > > - (CONFIG_ROCKCHIP_SPL_RESERVE_IRAM > 0) > > +#if defined(CONFIG_SPL_BUILD) && (CONFIG_ROCKCHIP_SPL_RESERVE_IRAM > 0) > > This was changed from SPL to XPL just to be changed back to SPL in this > patch?, such change probably just clutter git blame, was the change to > use XPL really necessary in the first place? > > Because SPL_BUILD was used together with !TPL_BUILD it is pretty obvious > that SPL_BUILD did not need to change to XPL_BUILD in the first place.
Yes this is a bit of a corner case. For the first patch, CONFIG_SPL_BUILD is defined for any 'SPL' build. For the second it is defined only for SPL. So in this case, yes, it doesn't matter. But across the whole of U-Boot, it does. I got pretty deep down the rabbit hole on this one, and perhaps should not have gone ahead with the 'clean-up'. So I think we can just drop this patch. I'll look at what others might be dropped too. Regards, Simon