Commit fefb9baf11 for qemu.org

commit fefb9baf11959cfa8120507c06dc3670fe59f048
Author: Peter Maydell <peter.maydell@linaro.org>
Date:   Wed Feb 18 20:01:38 2026 -0800

    target/arm: Don't require helper prototypes in helper.c

    In arm_cpu_do_interrupt_aarch64() we call the TCG helper function
    helper_rebuild_hflags_a64(), which requires helper.c to include the
    TCG helper function prototypes even when this file is being compiled
    with TCG disabled.

    We don't actually need to do this -- because we have already written
    the new EL into pstate and updated env->aarch64, we can call
    aarch64_rebuild_hflags() to achieve the same effect. This is the
    function we use everywhere else in this file to update hflags.

    Switch to aarch64_rebuild_hflags() and drop the include of the
    TCG helper headers.

    Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
    Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
    Message-id: 20260219040150.2098396-3-pierrick.bouvier@linaro.org
    Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

diff --git a/target/arm/helper.c b/target/arm/helper.c
index e12b2455d3..6bfab90981 100644
--- a/target/arm/helper.c
+++ b/target/arm/helper.c
@@ -36,9 +36,6 @@
 #include "target/arm/gtimer.h"
 #include "qemu/plugin.h"

-#define HELPER_H "tcg/helper.h"
-#include "exec/helper-proto.h.inc"
-
 static void switch_mode(CPUARMState *env, int mode);

 int compare_u64(const void *a, const void *b)
@@ -9479,7 +9476,7 @@ static void arm_cpu_do_interrupt_aarch64(CPUState *cs)
     aarch64_restore_sp(env, new_el);

     if (tcg_enabled()) {
-        helper_rebuild_hflags_a64(env, new_el);
+        arm_rebuild_hflags(env);
     }

     env->pc = addr;