[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 05/23] ppc: Enforce setting MSR:EE, IR and DR when MS
From: |
David Gibson |
Subject: |
[Qemu-devel] [PULL 05/23] ppc: Enforce setting MSR:EE, IR and DR when MSR:PR is set |
Date: |
Fri, 1 Jul 2016 16:41:41 +1000 |
From: Benjamin Herrenschmidt <address@hidden>
The architecture specifies that any instruction that sets MSR:PR will also
set MSR:EE, IR and DR.
Signed-off-by: Benjamin Herrenschmidt <address@hidden>
Signed-off-by: Cédric Le Goater <address@hidden>
Signed-off-by: David Gibson <address@hidden>
---
target-ppc/helper_regs.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/target-ppc/helper_regs.h b/target-ppc/helper_regs.h
index 8fc0934..8fdfa5c 100644
--- a/target-ppc/helper_regs.h
+++ b/target-ppc/helper_regs.h
@@ -136,6 +136,10 @@ static inline int hreg_store_msr(CPUPPCState *env,
target_ulong value,
/* Change the exception prefix on PowerPC 601 */
env->excp_prefix = ((value >> MSR_EP) & 1) * 0xFFF00000;
}
+ /* If PR=1 then EE, IR and DR must be 1 */
+ if ((value >> MSR_PR) & 1) {
+ value |= (1 << MSR_EE) | (1 << MSR_DR) | (1 << MSR_IR);
+ }
#endif
env->msr = value;
hreg_compute_hflags(env);
--
2.7.4
- [Qemu-devel] [PULL 00/23] ppc-for-2.7 queue 20160701, David Gibson, 2016/07/01
- [Qemu-devel] [PULL 02/23] ppc: Update LPCR definitions, David Gibson, 2016/07/01
- [Qemu-devel] [PULL 10/23] spapr: fix write-past-end-of-array error in cpu core device init code, David Gibson, 2016/07/01
- [Qemu-devel] [PULL 05/23] ppc: Enforce setting MSR:EE, IR and DR when MSR:PR is set,
David Gibson <=
- Re: [Qemu-devel] [Qemu-ppc] [PULL 05/23] ppc: Enforce setting MSR:EE, IR and DR when MSR:PR is set, Mark Cave-Ayland, 2016/07/08
- Re: [Qemu-devel] [Qemu-ppc] [PULL 05/23] ppc: Enforce setting MSR:EE, IR and DR when MSR:PR is set, Benjamin Herrenschmidt, 2016/07/08
- Re: [Qemu-devel] [Qemu-ppc] [PULL 05/23] ppc: Enforce setting MSR:EE, IR and DR when MSR:PR is set, Benjamin Herrenschmidt, 2016/07/08
- Re: [Qemu-devel] [Qemu-ppc] [PULL 05/23] ppc: Enforce setting MSR:EE, IR and DR when MSR:PR is set, Benjamin Herrenschmidt, 2016/07/08
- Re: [Qemu-devel] [Qemu-ppc] [PULL 05/23] ppc: Enforce setting MSR:EE, IR and DR when MSR:PR is set, Benjamin Herrenschmidt, 2016/07/08
- [Qemu-devel] [PATCH] ppc: Fix support for odd MSR combinations, Benjamin Herrenschmidt, 2016/07/08
- Re: [Qemu-devel] [PATCH] ppc: Fix support for odd MSR combinations, Benjamin Herrenschmidt, 2016/07/08
- [Qemu-devel] [PATCH v2] ppc: Fix support for odd MSR combinations, Benjamin Herrenschmidt, 2016/07/08
- Re: [Qemu-devel] [PATCH v2] ppc: Fix support for odd MSR combinations, Benjamin Herrenschmidt, 2016/07/08
- Re: [Qemu-devel] [PATCH v2] ppc: Fix support for odd MSR combinations, Mark Cave-Ayland, 2016/07/09