summaryrefslogtreecommitdiffstats
path: root/runtime
diff options
context:
space:
mode:
authortpnguyen <tpnguyen>2006-10-27 23:55:12 +0000
committertpnguyen <tpnguyen>2006-10-27 23:55:12 +0000
commit19510e5e18ac14bd9dc59eddb1a794ced7238301 (patch)
tree9fa14b34d4165a39ee989345606cbf1aa90952e3 /runtime
parent29aec74d4af5df8f1d5caa699ca4d35659f51a29 (diff)
downloadsystemtap-steved-19510e5e18ac14bd9dc59eddb1a794ced7238301.tar.gz
systemtap-steved-19510e5e18ac14bd9dc59eddb1a794ced7238301.tar.xz
systemtap-steved-19510e5e18ac14bd9dc59eddb1a794ced7238301.zip
2006-10-27 Thang Nguyen <thang.p.nguyen@intel.com>
* runtime/regs.c: patch from Bibo Mao for fixing the return value on IA64 (bz #3404).
Diffstat (limited to 'runtime')
-rw-r--r--runtime/ChangeLog5
-rw-r--r--runtime/regs.c14
2 files changed, 16 insertions, 3 deletions
diff --git a/runtime/ChangeLog b/runtime/ChangeLog
index 5872fc44..079b02ee 100644
--- a/runtime/ChangeLog
+++ b/runtime/ChangeLog
@@ -1,3 +1,8 @@
+2006-10-27 Thang Nguyen <thang.p.nguyen@intel.com>
+
+ * runtime/regs.c: patch from Bibo Mao for fixing the return
+ value on IA64 (bz #3404).
+
2006-10-24 Li Guanglei <guanglei@cn.ibm.com>
* runtime/lket/b2a/lket_b2a.[ch]: be sync with LKET hookid
diff --git a/runtime/regs.c b/runtime/regs.c
index 3684ad3d..6a879966 100644
--- a/runtime/regs.c
+++ b/runtime/regs.c
@@ -39,7 +39,9 @@ static long ia64_fetch_register(int regno, struct pt_regs *pt_regs)
{
struct ia64_stap_get_arbsp_param pa;
- if (regno < 32 || regno > 127)
+ if (regno >= 8 && regno <= 11)
+ return *(unsigned long *)(&pt_regs->r8 + regno - 8);
+ else if (regno < 32 || regno > 127)
return 0;
pa.ip = pt_regs->cr_iip;
@@ -56,8 +58,14 @@ static void ia64_store_register(int regno,
{
struct ia64_stap_get_arbsp_param pa;
unsigned long rsc_save = 0;
-
- if (regno < 32 || regno > 127)
+ unsigned long *addr;
+
+ if (regno >= 8 && regno <= 11) {
+ addr =&pt_regs->r8;
+ addr += regno - 8;
+ *(addr) = value;
+ }
+ else if (regno < 32 || regno > 127)
return;
pa.ip = pt_regs->cr_iip;