From 92b729071eddfad07aa5df4f05fc1d3b7fca6923 Mon Sep 17 00:00:00 2001 From: Ulrich Weigand Date: Mon, 14 Jun 2010 13:53:04 +0000 Subject: * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR. * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW. --- gdb/gdbserver/linux-s390-low.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'gdb/gdbserver/linux-s390-low.c') diff --git a/gdb/gdbserver/linux-s390-low.c b/gdb/gdbserver/linux-s390-low.c index eb865dc..943d8c5 100644 --- a/gdb/gdbserver/linux-s390-low.c +++ b/gdb/gdbserver/linux-s390-low.c @@ -270,8 +270,11 @@ s390_arch_setup (void) #ifdef __s390x__ { unsigned int pswm; - struct regcache *regcache = get_thread_regcache (current_inferior, 1); + struct regcache *regcache = new_register_cache (); + fetch_inferior_registers (regcache, find_regno ("pswm")); collect_register_by_name (regcache, "pswm", &pswm); + free_register_cache (regcache); + if (pswm & 1) init_registers_s390x_linux64 (); -- cgit v1.1