On Sun, Jan 12, 2025 at 4:36 PM Marek Vasut <[email protected]> wrote: > > Introduce common weak board_early_init_f() in rcar64-common.c > which is the default implementation in case there is no other > board specific board_early_init_f(). Remove board_early_init_f() > from Salvator-X, ULCB and Draak boards where this function is > empty.
Isn't there a config option to enable/disable board_early_init_f? If they are do-nothing functions, can the config option be disabled? adam > > Signed-off-by: Marek Vasut <[email protected]> > --- > Cc: Adam Ford <[email protected]> > Cc: Biju Das <[email protected]> > Cc: Lad Prabhakar <[email protected]> > Cc: Nobuhiro Iwamatsu <[email protected]> > Cc: Paul Barker <[email protected]> > Cc: Simon Glass <[email protected]> > Cc: Tom Rini <[email protected]> > Cc: [email protected] > --- > board/renesas/common/rcar64-common.c | 5 +++++ > board/renesas/draak/draak.c | 5 ----- > board/renesas/salvator-x/salvator-x.c | 5 ----- > board/renesas/ulcb/ulcb.c | 5 ----- > 4 files changed, 5 insertions(+), 15 deletions(-) > > diff --git a/board/renesas/common/rcar64-common.c > b/board/renesas/common/rcar64-common.c > index 74ec0a46e6f..69229ea3cb0 100644 > --- a/board/renesas/common/rcar64-common.c > +++ b/board/renesas/common/rcar64-common.c > @@ -65,3 +65,8 @@ int __weak board_init(void) > { > return 0; > } > + > +int __weak board_early_init_f(void) > +{ > + return 0; > +} > diff --git a/board/renesas/draak/draak.c b/board/renesas/draak/draak.c > index a8c40ff1f07..6caa63d553f 100644 > --- a/board/renesas/draak/draak.c > +++ b/board/renesas/draak/draak.c > @@ -12,11 +12,6 @@ > #include <asm/arch/rcar-mstp.h> > #include <asm/arch/renesas.h> > > -int board_early_init_f(void) > -{ > - return 0; > -} > - > #define HSUSB_MSTP704 BIT(4) /* HSUSB */ > > /* HSUSB block registers */ > diff --git a/board/renesas/salvator-x/salvator-x.c > b/board/renesas/salvator-x/salvator-x.c > index abb17c3fdc5..9bfcf0d66ad 100644 > --- a/board/renesas/salvator-x/salvator-x.c > +++ b/board/renesas/salvator-x/salvator-x.c > @@ -14,11 +14,6 @@ > #include <asm/arch/renesas.h> > #include <init.h> > > -int board_early_init_f(void) > -{ > - return 0; > -} > - > #define HSUSB_MSTP704 BIT(4) /* HSUSB */ > > /* HSUSB block registers */ > diff --git a/board/renesas/ulcb/ulcb.c b/board/renesas/ulcb/ulcb.c > index a441ff0e0d8..bd06db23b16 100644 > --- a/board/renesas/ulcb/ulcb.c > +++ b/board/renesas/ulcb/ulcb.c > @@ -15,11 +15,6 @@ > > #define HSUSB_MSTP704 BIT(4) /* HSUSB */ > > -int board_early_init_f(void) > -{ > - return 0; > -} > - > /* HSUSB block registers */ > #define HSUSB_REG_LPSTS 0xE6590102 > #define HSUSB_REG_LPSTS_SUSPM_NORMAL BIT(14) > -- > 2.45.2 >

