[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 105/107] target/ppc/mmu_hash64: Fix incorrect shift v
From: |
David Gibson |
Subject: |
[Qemu-devel] [PULL 105/107] target/ppc/mmu_hash64: Fix incorrect shift value in amr calculation |
Date: |
Thu, 2 Feb 2017 16:14:43 +1100 |
From: Suraj Jitindar Singh <address@hidden>
We are calculating the authority mask register key value wrong.
The pte entry contains the key value with the two upper bits and the three
lower bits stored separately. We should use these two portions to get a 5
bit value, not or them together which will only give us a 3 bit value.
Fix this.
Signed-off-by: Suraj Jitindar Singh <address@hidden>
Signed-off-by: David Gibson <address@hidden>
---
target/ppc/mmu-hash64.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/ppc/mmu-hash64.h b/target/ppc/mmu-hash64.h
index ab5d347..7a0b7fc 100644
--- a/target/ppc/mmu-hash64.h
+++ b/target/ppc/mmu-hash64.h
@@ -85,7 +85,7 @@ void ppc_hash64_update_rmls(CPUPPCState *env);
#define HPTE64_R_C 0x0000000000000080ULL
#define HPTE64_R_R 0x0000000000000100ULL
#define HPTE64_R_KEY_LO 0x0000000000000e00ULL
-#define HPTE64_R_KEY(x) ((((x) & HPTE64_R_KEY_HI) >> 60) | \
+#define HPTE64_R_KEY(x) ((((x) & HPTE64_R_KEY_HI) >> 57) | \
(((x) & HPTE64_R_KEY_LO) >> 9))
#define HPTE64_V_1TB_SEG 0x4000000000000000ULL
--
2.9.3
- [Qemu-devel] [PULL 098/107] ppc: switch to constants within BUILD_BUG_ON, (continued)
- [Qemu-devel] [PULL 098/107] ppc: switch to constants within BUILD_BUG_ON, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 085/107] ppc: Implement bcdtrunc. instruction, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 086/107] ppc: Implement bcdutrunc. instruction, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 089/107] target-ppc: Add xsdivqp instruction, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 101/107] target-ppc: Add xststdc[sp, dp, qp] instructions, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 084/107] ppc/prep: update MAINTAINERS file, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 088/107] target-ppc: Add xscvsdqp and xscvudqp instructions, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 102/107] target/ppc/debug: Print LPCR register value if register exists, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 091/107] target-ppc: Add xvcv[hpsp, sphp] instructions, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 083/107] target-ppc: Add xscvqps[d, w]z instructions, David Gibson, 2017/02/02
- [Qemu-devel] [PULL 105/107] target/ppc/mmu_hash64: Fix incorrect shift value in amr calculation,
David Gibson <=
- [Qemu-devel] [PULL 095/107] spapr: clock should count only if vm is running, David Gibson, 2017/02/02
- Re: [Qemu-devel] [PULL 095/107] spapr: clock should count only if vm is running, Mark Cave-Ayland, 2017/02/02
- Re: [Qemu-devel] [PULL 095/107] spapr: clock should count only if vm is running, Laurent Vivier, 2017/02/02
- Re: [Qemu-devel] [PULL 095/107] spapr: clock should count only if vm is running, Mark Cave-Ayland, 2017/02/02
- Re: [Qemu-devel] [PULL 095/107] spapr: clock should count only if vm is running, Laurent Vivier, 2017/02/02
- Re: [Qemu-devel] [PULL 095/107] spapr: clock should count only if vm is running, Mark Cave-Ayland, 2017/02/02
- Re: [Qemu-devel] [PULL 095/107] spapr: clock should count only if vm is running, Laurent Vivier, 2017/02/07
- Re: [Qemu-devel] [PULL 095/107] spapr: clock should count only if vm is running, Mark Cave-Ayland, 2017/02/09
- Re: [Qemu-devel] [PULL 095/107] spapr: clock should count only if vm is running, Laurent Vivier, 2017/02/09
- [Qemu-devel] [PULL 107/107] hw/ppc/pnv: Use error_report instead of hw_error if a ROM file can't be found, David Gibson, 2017/02/02