From 782f893c0349e40e14a27c9d829506c3c3008ed1 Mon Sep 17 00:00:00 2001 From: Cyril Bur Date: Wed, 22 Nov 2017 11:56:17 +1100 Subject: libpdbg: Fix incorrect restore of r1 in ram_instructions() Signed-off-by: Cyril Bur --- libpdbg/chip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libpdbg/chip.c b/libpdbg/chip.c index 539438a..0dd2363 100644 --- a/libpdbg/chip.c +++ b/libpdbg/chip.c @@ -158,7 +158,7 @@ static int ram_instructions(struct thread *thread, uint64_t *opcodes, } else if (i == len + 1) { /* Restore r1 */ scratch = r1; - opcode = mfspr(0, 277); + opcode = mfspr(1, 277); } CHECK_ERR(thread->ram_instruction(thread, opcode, &scratch)); -- cgit v1.2.1