[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [RFC PATCH V1 13/14] microblaze: Add an MSR_PVR constant an
From: |
Peter A. G. Crosthwaite |
Subject: |
[Qemu-devel] [RFC PATCH V1 13/14] microblaze: Add an MSR_PVR constant and use it. |
Date: |
Thu, 25 Aug 2011 16:41:19 +1000 |
From: Edgar E. Iglesias <address@hidden>
Signed-off-by: Edgar E. Iglesias <address@hidden>
---
target-microblaze/cpu.h | 1 +
target-microblaze/translate.c | 4 ++--
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/target-microblaze/cpu.h b/target-microblaze/cpu.h
index a81da62..3530286 100644
--- a/target-microblaze/cpu.h
+++ b/target-microblaze/cpu.h
@@ -65,6 +65,7 @@ struct CPUMBState;
#define MSR_DCE (1<<7) /* 0x080 */
#define MSR_EE (1<<8) /* 0x100 */
#define MSR_EIP (1<<9) /* 0x200 */
+#define MSR_PVR (1<<10) /* 0x400 */
#define MSR_CC (1<<31)
/* Machine State Register (MSR) Fields */
diff --git a/target-microblaze/translate.c b/target-microblaze/translate.c
index 15f1fe5..366fd3e 100644
--- a/target-microblaze/translate.c
+++ b/target-microblaze/translate.c
@@ -429,8 +429,8 @@ static inline void msr_write(DisasContext *dc, TCGv v)
t = tcg_temp_new();
dc->cpustate_changed = 1;
/* PVR bit is not writable. */
- tcg_gen_andi_tl(t, v, ~(1 << 10));
- tcg_gen_andi_tl(cpu_SR[SR_MSR], cpu_SR[SR_MSR], (1 << 10));
+ tcg_gen_andi_tl(t, v, ~MSR_PVR);
+ tcg_gen_andi_tl(cpu_SR[SR_MSR], cpu_SR[SR_MSR], MSR_PVR);
tcg_gen_or_tl(cpu_SR[SR_MSR], cpu_SR[SR_MSR], v);
tcg_temp_free(t);
}
--
1.7.3.2
- [Qemu-devel] [RFC PATCH V1 00/14] Dynamic machine model creation from device trees, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 01/14] qemu-coroutine: Add simple work queue support, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 02/14] device_tree: Extended interface for fdt_generic, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 03/14] fdt_generic: First revision, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 04/14] xilinx_uartlite: Added fdt gen. platform support, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 05/14] pflash_cfi01: Added fdt generic platform support, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 06/14] qdev: Added fn for querying device property types, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 07/14] fdt_generic_qdev: first revision, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 13/14] microblaze: Add an MSR_PVR constant and use it.,
Peter A. G. Crosthwaite <=
- [Qemu-devel] [RFC PATCH V1 14/14] microblaze_generic_fdt: first revision, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 12/14] microblaze: Make the MSR PVR bit non writable, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 09/14] xilinx_intc: Added fdt generic platform support, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 10/14] xilinx_ethlite: Added fdt generic platform support, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 08/14] xilinx_timer: Added fdt_generic platform support, Peter A. G. Crosthwaite, 2011/08/25
- [Qemu-devel] [RFC PATCH V1 11/14] vl.c: Added hw_dtb/kern_dtb command line opts, Peter A. G. Crosthwaite, 2011/08/25