Commit a4f5c5b7 authored by Nick Reilly's avatar Nick Reilly Committed by Peter Maydell
Browse files

Add missing fp_access_check() to aarch64 crypto instructions



The aarch64 crypto instructions for AES and SHA are missing the
check for if the FPU is enabled.

Signed-off-by: default avatarNick Reilly <nreilly@blackberry.com>
Reviewed-by: default avatarPeter Maydell <peter.maydell@linaro.org>
Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
parent dbb74759
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -10933,6 +10933,10 @@ static void disas_crypto_aes(DisasContext *s, uint32_t insn)
        return;
    }

    if (!fp_access_check(s)) {
        return;
    }

    /* Note that we convert the Vx register indexes into the
     * index within the vfp.regs[] array, so we can share the
     * helper with the AArch32 instructions.
@@ -10997,6 +11001,10 @@ static void disas_crypto_three_reg_sha(DisasContext *s, uint32_t insn)
        return;
    }

    if (!fp_access_check(s)) {
        return;
    }

    tcg_rd_regno = tcg_const_i32(rd << 1);
    tcg_rn_regno = tcg_const_i32(rn << 1);
    tcg_rm_regno = tcg_const_i32(rm << 1);
@@ -11060,6 +11068,10 @@ static void disas_crypto_two_reg_sha(DisasContext *s, uint32_t insn)
        return;
    }

    if (!fp_access_check(s)) {
        return;
    }

    tcg_rd_regno = tcg_const_i32(rd << 1);
    tcg_rn_regno = tcg_const_i32(rn << 1);