diff options
Diffstat (limited to 'gdb/sol-thread.c')
-rw-r--r-- | gdb/sol-thread.c | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/gdb/sol-thread.c b/gdb/sol-thread.c index bb8d20b..722e253 100644 --- a/gdb/sol-thread.c +++ b/gdb/sol-thread.c @@ -478,7 +478,7 @@ sol_thread_wait (ptid_t ptid, struct target_waitstatus *ourstatus) } static void -sol_thread_fetch_registers (int regnum) +sol_thread_fetch_registers (struct regcache *regcache, int regnum) { thread_t thread; td_thrhandle_t thandle; @@ -494,9 +494,9 @@ sol_thread_fetch_registers (int regnum) { /* It's an LWP; pass the request on to procfs. */ if (target_has_execution) - procfs_ops.to_fetch_registers (regnum); + procfs_ops.to_fetch_registers (regcache, regnum); else - orig_core_ops.to_fetch_registers (regnum); + orig_core_ops.to_fetch_registers (regcache, regnum); return; } @@ -531,8 +531,8 @@ sol_thread_fetch_registers (int regnum) calling the td routines because the td routines call ps_lget* which affect the values stored in the registers array. */ - supply_gregset (current_regcache, (const gdb_gregset_t *) &gregset); - supply_fpregset (current_regcache, (const gdb_fpregset_t *) &fpregset); + supply_gregset (regcache, (const gdb_gregset_t *) &gregset); + supply_fpregset (regcache, (const gdb_fpregset_t *) &fpregset); #if 0 /* FIXME: libthread_db doesn't seem to handle this right. */ @@ -553,7 +553,7 @@ sol_thread_fetch_registers (int regnum) } static void -sol_thread_store_registers (int regnum) +sol_thread_store_registers (struct regcache *regcache, int regnum) { thread_t thread; td_thrhandle_t thandle; @@ -568,7 +568,7 @@ sol_thread_store_registers (int regnum) if (!is_thread (inferior_ptid)) { /* It's an LWP; pass the request on to procfs.c. */ - procfs_ops.to_store_registers (regnum); + procfs_ops.to_store_registers (regcache, regnum); return; } @@ -586,7 +586,7 @@ sol_thread_store_registers (int regnum) char old_value[MAX_REGISTER_SIZE]; /* Save new register value. */ - regcache_raw_collect (current_regcache, regnum, old_value); + regcache_raw_collect (regcache, regnum, old_value); val = p_td_thr_getgregs (&thandle, gregset); if (val != TD_OK) @@ -598,7 +598,7 @@ sol_thread_store_registers (int regnum) td_err_string (val)); /* Restore new register value. */ - regcache_raw_supply (current_regcache, regnum, old_value); + regcache_raw_supply (regcache, regnum, old_value); #if 0 /* FIXME: libthread_db doesn't seem to handle this right. */ @@ -618,8 +618,8 @@ sol_thread_store_registers (int regnum) #endif } - fill_gregset (current_regcache, (gdb_gregset_t *) &gregset, regnum); - fill_fpregset (current_regcache, (gdb_fpregset_t *) &fpregset, regnum); + fill_gregset (regcache, (gdb_gregset_t *) &gregset, regnum); + fill_fpregset (regcache, (gdb_fpregset_t *) &fpregset, regnum); val = p_td_thr_setgregs (&thandle, gregset); if (val != TD_OK) @@ -1104,9 +1104,9 @@ ps_lgetregs (gdb_ps_prochandle_t ph, lwpid_t lwpid, prgregset_t gregset) inferior_ptid = BUILD_LWP (lwpid, PIDGET (inferior_ptid)); if (target_has_execution) - procfs_ops.to_fetch_registers (-1); + procfs_ops.to_fetch_registers (current_regcache, -1); else - orig_core_ops.to_fetch_registers (-1); + orig_core_ops.to_fetch_registers (current_regcache, -1); fill_gregset (current_regcache, (gdb_gregset_t *) gregset, -1); do_cleanups (old_chain); @@ -1128,9 +1128,9 @@ ps_lsetregs (gdb_ps_prochandle_t ph, lwpid_t lwpid, supply_gregset (current_regcache, (const gdb_gregset_t *) gregset); if (target_has_execution) - procfs_ops.to_store_registers (-1); + procfs_ops.to_store_registers (current_regcache, -1); else - orig_core_ops.to_store_registers (-1); + orig_core_ops.to_store_registers (current_regcache, -1); do_cleanups (old_chain); @@ -1236,9 +1236,9 @@ ps_lgetfpregs (gdb_ps_prochandle_t ph, lwpid_t lwpid, inferior_ptid = BUILD_LWP (lwpid, PIDGET (inferior_ptid)); if (target_has_execution) - procfs_ops.to_fetch_registers (-1); + procfs_ops.to_fetch_registers (current_regcache, -1); else - orig_core_ops.to_fetch_registers (-1); + orig_core_ops.to_fetch_registers (current_regcache, -1); fill_fpregset (current_regcache, (gdb_fpregset_t *) fpregset, -1); do_cleanups (old_chain); @@ -1260,9 +1260,9 @@ ps_lsetfpregs (gdb_ps_prochandle_t ph, lwpid_t lwpid, supply_fpregset (current_regcache, (const gdb_fpregset_t *) fpregset); if (target_has_execution) - procfs_ops.to_store_registers (-1); + procfs_ops.to_store_registers (current_regcache, -1); else - orig_core_ops.to_store_registers (-1); + orig_core_ops.to_store_registers (current_regcache, -1); do_cleanups (old_chain); |