2013-10-06 18:47:27 +00:00
|
|
|
From f8028b0aa2318fc10df39c8dec1353b91e1597be Mon Sep 17 00:00:00 2001
|
|
|
|
From: Anton Blanchard <anton@samba.org>
|
|
|
|
Date: Wed, 1 May 2013 00:44:51 +0000
|
|
|
|
Subject: [PATCH] target-ppc: Add read and write of PPR SPR
|
|
|
|
|
|
|
|
Recent Linux kernels save and restore the PPR across exceptions
|
|
|
|
so we need to handle it.
|
|
|
|
|
|
|
|
Signed-off-by: Anton Blanchard <anton@au1.ibm.com>
|
|
|
|
Signed-off-by: Alexander Graf <agraf@suse.de>
|
|
|
|
(cherry picked from commit 04559d5210860ea5853db09c75ea8ff2f8843e16)
|
|
|
|
---
|
|
|
|
target-ppc/translate_init.c | 4 ++++
|
|
|
|
1 file changed, 4 insertions(+)
|
|
|
|
|
|
|
|
diff --git a/target-ppc/translate_init.c b/target-ppc/translate_init.c
|
|
|
|
index 88d9dfa..7e46fdc 100644
|
|
|
|
--- a/target-ppc/translate_init.c
|
|
|
|
+++ b/target-ppc/translate_init.c
|
|
|
|
@@ -6738,6 +6738,10 @@ static void init_proc_POWER7 (CPUPPCState *env)
|
2013-09-05 08:55:31 +00:00
|
|
|
&spr_read_generic, &spr_write_generic,
|
|
|
|
&spr_read_generic, &spr_write_generic,
|
|
|
|
0x00000000);
|
|
|
|
+ spr_register(env, SPR_PPR, "PPR",
|
|
|
|
+ &spr_read_generic, &spr_write_generic,
|
|
|
|
+ &spr_read_generic, &spr_write_generic,
|
|
|
|
+ 0x00000000);
|
|
|
|
#if !defined(CONFIG_USER_ONLY)
|
|
|
|
env->slb_nr = 32;
|
|
|
|
#endif
|