diff options
author | Bernhard Beschow <shentey@gmail.com> | 2023-01-30 19:49:50 +0100 |
---|---|---|
committer | Daniel Henrique Barboza <danielhb413@gmail.com> | 2023-03-03 16:50:17 -0300 |
commit | e64645ba802f7735bfffe342945a71b4fb1c5b66 (patch) | |
tree | 5beab0933b352a1d4bba0401cce69c2b16d28510 /target/ppc | |
parent | 66577e9e1caee48c6ebc1a2161b5d9857fcde8b3 (diff) |
target/ppc/translate: Add dummy implementation for dcblc instruction
The dcblc instruction is used by u-boot in mpc85xx/start.S. Without it,
an illegal istruction exception is generated very early in the boot
process where the processor is not yet able to handle exceptions. See:
https://github.com/u-boot/u-boot/blob/v2023.01/arch/powerpc/cpu/mpc85xx/start.S#L1840
Signed-off-by: Bernhard Beschow <shentey@gmail.com>
Message-Id: <20230130184950.5241-1-shentey@gmail.com>
Acked-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Diffstat (limited to 'target/ppc')
-rw-r--r-- | target/ppc/translate.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/target/ppc/translate.c b/target/ppc/translate.c index 2956021e89..37b67d5175 100644 --- a/target/ppc/translate.c +++ b/target/ppc/translate.c @@ -5253,6 +5253,14 @@ static void gen_dcbtls(DisasContext *ctx) tcg_temp_free(t0); } +/* dcblc */ +static void gen_dcblc(DisasContext *ctx) +{ + /* + * interpreted as no-op + */ +} + /* dcbz */ static void gen_dcbz(DisasContext *ctx) { @@ -6824,6 +6832,7 @@ GEN_HANDLER_E(dcbtep, 0x1F, 0x1F, 0x09, 0x00000001, PPC_NONE, PPC2_BOOKE206), GEN_HANDLER(dcbtst, 0x1F, 0x16, 0x07, 0x00000001, PPC_CACHE), GEN_HANDLER_E(dcbtstep, 0x1F, 0x1F, 0x07, 0x00000001, PPC_NONE, PPC2_BOOKE206), GEN_HANDLER_E(dcbtls, 0x1F, 0x06, 0x05, 0x02000001, PPC_BOOKE, PPC2_BOOKE206), +GEN_HANDLER_E(dcblc, 0x1F, 0x06, 0x0c, 0x02000001, PPC_BOOKE, PPC2_BOOKE206), GEN_HANDLER(dcbz, 0x1F, 0x16, 0x1F, 0x03C00001, PPC_CACHE_DCBZ), GEN_HANDLER_E(dcbzep, 0x1F, 0x1F, 0x1F, 0x03C00001, PPC_NONE, PPC2_BOOKE206), GEN_HANDLER(dst, 0x1F, 0x16, 0x0A, 0x01800001, PPC_ALTIVEC), |