summaryrefslogtreecommitdiffstats
path: root/target-s390x/arch_dump.c
diff options
context:
space:
mode:
authorEric Farman <farman@linux.vnet.ibm.com>2015-05-07 14:35:44 -0400
committerCornelia Huck <cornelia.huck@de.ibm.com>2015-05-27 17:52:03 +0200
commitc498d8e36e2998fb67de21a34ece633d356a4834 (patch)
tree5b767101eb99af8c7adefdec65cbae2f737325f0 /target-s390x/arch_dump.c
parent0915aed5842bd4dbe396b92d4f3b846ae29ad663 (diff)
downloadhqemu-c498d8e36e2998fb67de21a34ece633d356a4834.zip
hqemu-c498d8e36e2998fb67de21a34ece633d356a4834.tar.gz
s390x: Common access to floating point registers
Provide a routine to access the correct floating point register, to simplify future expansion. Suggested-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Eric Farman <farman@linux.vnet.ibm.com> Reviewed-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Diffstat (limited to 'target-s390x/arch_dump.c')
-rw-r--r--target-s390x/arch_dump.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/target-s390x/arch_dump.c b/target-s390x/arch_dump.c
index a1554f5..36e8407 100644
--- a/target-s390x/arch_dump.c
+++ b/target-s390x/arch_dump.c
@@ -78,11 +78,12 @@ static void s390x_write_elf64_prstatus(Note *note, S390CPU *cpu)
static void s390x_write_elf64_fpregset(Note *note, S390CPU *cpu)
{
int i;
+ CPUS390XState *cs = &cpu->env;
note->hdr.n_type = cpu_to_be32(NT_FPREGSET);
note->contents.fpregset.fpc = cpu_to_be32(cpu->env.fpc);
for (i = 0; i <= 15; i++) {
- note->contents.fpregset.fprs[i] = cpu_to_be64(cpu->env.fregs[i].ll);
+ note->contents.fpregset.fprs[i] = cpu_to_be64(get_freg(cs, i)->ll);
}
}
OpenPOWER on IntegriCloud