diff mbox series

[RFC,04/40] target/arm: Remove aarch64_cpu_finalizefn

Message ID 20230103181646.55711-5-richard.henderson@linaro.org
State New
Headers show
Series Toward class init of cpu features | expand

Commit Message

Richard Henderson Jan. 3, 2023, 6:16 p.m. UTC
If the instance_finalize hook is NULL, the hook is not called.
There is no need to install an empty function.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
 target/arm/cpu64.c | 5 -----
 1 file changed, 5 deletions(-)

Comments

Philippe Mathieu-Daudé Jan. 5, 2023, 9:51 p.m. UTC | #1
On 3/1/23 19:16, Richard Henderson wrote:
> If the instance_finalize hook is NULL, the hook is not called.
> There is no need to install an empty function.
> 
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
> ---
>   target/arm/cpu64.c | 5 -----
>   1 file changed, 5 deletions(-)

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
diff mbox series

Patch

diff --git a/target/arm/cpu64.c b/target/arm/cpu64.c
index 2cf2ca4ce5..611b233d23 100644
--- a/target/arm/cpu64.c
+++ b/target/arm/cpu64.c
@@ -1351,10 +1351,6 @@  static void aarch64_cpu_set_aarch64(Object *obj, bool value, Error **errp)
     }
 }
 
-static void aarch64_cpu_finalizefn(Object *obj)
-{
-}
-
 static gchar *aarch64_gdb_arch_name(CPUState *cs)
 {
     return g_strdup("aarch64");
@@ -1412,7 +1408,6 @@  static const TypeInfo aarch64_cpu_type_info = {
     .name = TYPE_AARCH64_CPU,
     .parent = TYPE_ARM_CPU,
     .instance_size = sizeof(ARMCPU),
-    .instance_finalize = aarch64_cpu_finalizefn,
     .abstract = true,
     .class_size = sizeof(AArch64CPUClass),
     .class_init = aarch64_cpu_class_init,