]> sourceware.org Git - systemtap.git/commitdiff
Correctly return task pointers by making them unsigned longs.
authorTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Fri, 9 May 2014 14:35:26 +0000 (09:35 -0500)
committerDavid Smith <dsmith@redhat.com>
Fri, 9 May 2014 14:35:26 +0000 (09:35 -0500)
* tapset/linux/task.stp (task_current): Return task strucct pointer as an
  unsigned long.
  (pid2task): Ditto.

tapset/linux/task.stp

index 1782b92f38b1f9c0ad072144c92ff083f4b40ae3..8090b2e97e28d4f476011d9f392da7c911e00fbf 100644 (file)
@@ -29,7 +29,7 @@
  * more task-specific data.
  */
 function task_current:long () %{ /* pure */
-    STAP_RETVALUE = (long)current;
+    STAP_RETVALUE = (unsigned long)current;
 %}
 
 function _task_rlimit_cur:long (task:long, nd_limit:long)
@@ -238,7 +238,7 @@ function pid2task:long (pid:long) %{ /* pure */
 #endif /* 2.6.24 */
 #endif /* 2.6.31 */
     rcu_read_unlock();
-    STAP_RETVALUE = (long)t;
+    STAP_RETVALUE = (unsigned long)t;
 %}
 
 /**
This page took 0.103901 seconds and 5 git commands to generate.