]>
Commit | Line | Data |
---|---|---|
00e5a55c BS |
1 | Subject: Don't emulate mr. instructions |
2 | From: Ananth N Mavinakayanahalli <ananth@in.ibm.com> | |
3 | References: 459387 - LTC49903 | |
4 | ||
5 | Currently emulate_step() emulates mr. instructions without updating cr0 | |
6 | and this can be disastrous. Don't emulate mr. | |
7 | ||
8 | Signed-off-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com> | |
9 | Signed-off-by: Olaf Hering <olh@suse.de> | |
10 | ||
11 | --- | |
12 | arch/powerpc/lib/sstep.c | 2 ++ | |
13 | 1 file changed, 2 insertions(+) | |
14 | ||
15 | --- a/arch/powerpc/lib/sstep.c | |
16 | +++ b/arch/powerpc/lib/sstep.c | |
17 | @@ -172,6 +172,8 @@ int __kprobes emulate_step(struct pt_reg | |
18 | } | |
19 | break; | |
20 | case 0x378: /* orx */ | |
21 | + if (instr & 1) | |
22 | + break; | |
23 | rs = (instr >> 21) & 0x1f; | |
24 | rb = (instr >> 11) & 0x1f; | |
25 | if (rs == rb) { /* mr */ |