[PATCH] Remove unused parameters

Removes unused function arguments from the riscv_cpu_setup function
Signed-off-by: Shenlin Liang liangshenlin@eswincomputing.com --- arch/riscv/cpu/cpu.c | 2 +- arch/riscv/include/asm/system.h | 2 +- arch/riscv/lib/spl.c | 2 +- board/starfive/visionfive2/spl.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/arch/riscv/cpu/cpu.c b/arch/riscv/cpu/cpu.c index ecfb1fb08c..728cdfe9c9 100644 --- a/arch/riscv/cpu/cpu.c +++ b/arch/riscv/cpu/cpu.c @@ -91,7 +91,7 @@ static void dummy_pending_ipi_clear(ulong hart, ulong arg0, ulong arg1) } #endif
-int riscv_cpu_setup(void *ctx, struct event *event) +int riscv_cpu_setup(void) { int ret;
diff --git a/arch/riscv/include/asm/system.h b/arch/riscv/include/asm/system.h index ffa7649f3f..87a804bfd5 100644 --- a/arch/riscv/include/asm/system.h +++ b/arch/riscv/include/asm/system.h @@ -26,6 +26,6 @@ struct event; } while (0)
/* Hook to set up the CPU (called from SPL too) */ -int riscv_cpu_setup(void *ctx, struct event *event); +int riscv_cpu_setup(void);
#endif /* __ASM_RISCV_SYSTEM_H */ diff --git a/arch/riscv/lib/spl.c b/arch/riscv/lib/spl.c index f4d3b67e5d..9b242ed821 100644 --- a/arch/riscv/lib/spl.c +++ b/arch/riscv/lib/spl.c @@ -28,7 +28,7 @@ __weak void board_init_f(ulong dummy) if (ret) panic("spl_early_init() failed: %d\n", ret);
- riscv_cpu_setup(NULL, NULL); + riscv_cpu_setup();
preloader_console_init();
diff --git a/board/starfive/visionfive2/spl.c b/board/starfive/visionfive2/spl.c index 7acd3995aa..ad5f71a201 100644 --- a/board/starfive/visionfive2/spl.c +++ b/board/starfive/visionfive2/spl.c @@ -218,7 +218,7 @@ void board_init_f(ulong dummy) if (ret) panic("spl_early_init() failed: %d\n", ret);
- riscv_cpu_setup(NULL, NULL); + riscv_cpu_setup(); preloader_console_init();
/* Set the parent clock of cpu_root clock to pll0,

Hi,
On Fri, 28 Jul 2023 at 06:19, Shenlin Liang liangshenlin@eswincomputing.com wrote:
Removes unused function arguments from the riscv_cpu_setup function
Signed-off-by: Shenlin Liang liangshenlin@eswincomputing.com
arch/riscv/cpu/cpu.c | 2 +- arch/riscv/include/asm/system.h | 2 +- arch/riscv/lib/spl.c | 2 +- board/starfive/visionfive2/spl.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/arch/riscv/cpu/cpu.c b/arch/riscv/cpu/cpu.c index ecfb1fb08c..728cdfe9c9 100644 --- a/arch/riscv/cpu/cpu.c +++ b/arch/riscv/cpu/cpu.c @@ -91,7 +91,7 @@ static void dummy_pending_ipi_clear(ulong hart, ulong arg0, ulong arg1) } #endif
-int riscv_cpu_setup(void *ctx, struct event *event)
These params are needed since there is an EVENT_SPY() declaration just below it. It needs those params.
Or perhaps you have another patch to remove it?
+int riscv_cpu_setup(void) { int ret;
diff --git a/arch/riscv/include/asm/system.h b/arch/riscv/include/asm/system.h index ffa7649f3f..87a804bfd5 100644 --- a/arch/riscv/include/asm/system.h +++ b/arch/riscv/include/asm/system.h @@ -26,6 +26,6 @@ struct event; } while (0)
/* Hook to set up the CPU (called from SPL too) */ -int riscv_cpu_setup(void *ctx, struct event *event); +int riscv_cpu_setup(void);
#endif /* __ASM_RISCV_SYSTEM_H */ diff --git a/arch/riscv/lib/spl.c b/arch/riscv/lib/spl.c index f4d3b67e5d..9b242ed821 100644 --- a/arch/riscv/lib/spl.c +++ b/arch/riscv/lib/spl.c @@ -28,7 +28,7 @@ __weak void board_init_f(ulong dummy) if (ret) panic("spl_early_init() failed: %d\n", ret);
riscv_cpu_setup(NULL, NULL);
riscv_cpu_setup(); preloader_console_init();
diff --git a/board/starfive/visionfive2/spl.c b/board/starfive/visionfive2/spl.c index 7acd3995aa..ad5f71a201 100644 --- a/board/starfive/visionfive2/spl.c +++ b/board/starfive/visionfive2/spl.c @@ -218,7 +218,7 @@ void board_init_f(ulong dummy) if (ret) panic("spl_early_init() failed: %d\n", ret);
riscv_cpu_setup(NULL, NULL);
riscv_cpu_setup(); preloader_console_init(); /* Set the parent clock of cpu_root clock to pll0,
-- 2.31.1.windows.1
Regards, Simon
participants (2)
-
Shenlin Liang
-
Simon Glass