arm: mediatek: use default weak mtk_soc_early_init()

Add a weak default implementation of mtk_soc_early_init() in spl.c to
avoid having to define it in every SoC init.c file that does not need
any additional early initialization.

The init.h header file is no longer needed in this case and is removed.

Signed-off-by: David Lechner <dlechner@baylibre.com>
This commit is contained in:
David Lechner 2026-02-09 10:39:26 -06:00 committed by Tom Rini
parent 42b3ee7fa5
commit 1af249f511
6 changed files with 4 additions and 32 deletions

View File

@ -1,11 +0,0 @@
/* SPDX-License-Identifier: GPL-2.0 */
/*
* Copyright (C) 2018 MediaTek Inc.
*/
#ifndef __MEDIATEK_INIT_H_
#define __MEDIATEK_INIT_H_
extern int mtk_soc_early_init(void);
#endif /* __MEDIATEK_INIT_H_ */

View File

@ -16,11 +16,6 @@ DECLARE_GLOBAL_DATA_PTR;
struct boot_argument *preloader_param;
int mtk_soc_early_init(void)
{
return 0;
}
int dram_init(void)
{
u32 i;

View File

@ -42,11 +42,6 @@ int mtk_pll_early_init(void)
return 0;
}
int mtk_soc_early_init(void)
{
return 0;
}
void reset_cpu(void)
{
psci_system_reset();

View File

@ -45,11 +45,6 @@ int dram_init_banksize(void)
return 0;
}
int mtk_soc_early_init(void)
{
return 0;
}
void reset_cpu(void)
{
struct udevice *wdt;

View File

@ -26,11 +26,6 @@ int dram_init_banksize(void)
return 0;
}
int mtk_soc_early_init(void)
{
return 0;
}
void reset_cpu(void)
{
struct udevice *wdt;

View File

@ -9,7 +9,10 @@
#include <init.h>
#include <spl.h>
#include "init.h"
__weak int mtk_soc_early_init(void)
{
return 0;
}
void board_init_f(ulong dummy)
{