target/arm: Add missing break statement for Hypervisor Trap Exception
authorPhilippe Mathieu-Daudé <philmd@redhat.com>
Mon, 22 Jul 2019 13:07:38 +0000 (14:07 +0100)
committerPeter Maydell <peter.maydell@linaro.org>
Mon, 22 Jul 2019 13:07:38 +0000 (14:07 +0100)
Reported by GCC9 when building with  -Wimplicit-fallthrough=2:

  target/arm/helper.c: In function ‘arm_cpu_do_interrupt_aarch32_hyp’:
  target/arm/helper.c:7958:14: error: this statement may fall through [-Werror=implicit-fallthrough=]
   7958 |         addr = 0x14;
        |         ~~~~~^~~~~~
  target/arm/helper.c:7959:5: note: here
   7959 |     default:
        |     ^~~~~~~
  cc1: all warnings being treated as errors

Fixes: b9bc21ff9f9
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reported-by: Stefan Weil <sw@weilnetz.de>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Message-id: 20190719111451.12406-1-philmd@redhat.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
target/arm/helper.c

index 20f8728be115bc6531bba406a02a752ac8d4f8c2..b74c23a9bc08cf772fd4a4ee4b8e9d3ae34870cc 100644 (file)
@@ -7956,6 +7956,7 @@ static void arm_cpu_do_interrupt_aarch32_hyp(CPUState *cs)
         break;
     case EXCP_HYP_TRAP:
         addr = 0x14;
+        break;
     default:
         cpu_abort(cs, "Unhandled exception 0x%x\n", cs->exception_index);
     }