[patch] Only include fdtable.h for kernels > 2.6.25

Mark Wielaard mwielaard@redhat.com
Tue May 27 09:23:00 GMT 2008


Hi,

The following commit made task.stp and signal.stp work better on 2.6.26
kernels, but broke things on kernels before that.

commit f09ac52b8a4a35e46c694b96ccfbf28c08f0c527
Author: wenji <wjhuang@dhcp-beijing-cdc-10-182-120-233.cn.oracle.com>
Date:   Mon May 26 04:23:12 2008 -0400

    Include fdtable.h in task.stp for 2.6.26 and format signal.stp

I added the following patch to fix that:

2008-05-26  Mark Wielaard  <mwielaard@redhat.com>

    * task.stp : Only include fdtable.h for kernel versions > 2.6.25.

Cheers,

Mark

diff --git a/tapset/task.stp b/tapset/task.stp
index 1f361b5..d89729e 100644
--- a/tapset/task.stp
+++ b/tapset/task.stp
@@ -9,7 +9,9 @@
 %{
 #include <linux/version.h>
 #include <linux/file.h>
+#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,25)
 #include <linux/fdtable.h>
+#endif
 %}
 
 // Return the task_struct representing the current process




More information about the Systemtap mailing list