summaryrefslogtreecommitdiffstats
path: root/tapset/linuxmib.stp
diff options
context:
space:
mode:
authorWenji Huang <wenji.huang@oracle.com>2009-12-02 17:45:20 +0800
committerWenji Huang <wenji.huang@oracle.com>2009-12-02 17:45:20 +0800
commit379c58568dbb247ed6583434ff4658c0794b977d (patch)
treef873d8e31103b635f8dec236ce328e4f51fd8333 /tapset/linuxmib.stp
parentae3d9351dec2533ffa4c55b3d7543d5b270efec7 (diff)
downloadsystemtap-steved-379c58568dbb247ed6583434ff4658c0794b977d.tar.gz
systemtap-steved-379c58568dbb247ed6583434ff4658c0794b977d.tar.xz
systemtap-steved-379c58568dbb247ed6583434ff4658c0794b977d.zip
Make tapset and tests compatible with old kernel
* tapset/ioscheduler.stp : Make probe optional. * tapset/irq.stp : Ditto. * tapset/scheduler.stp : Ditto. * tapset/tcpmib.stp : Ditto. * tapset/linuxmib.stp : Switch variable by version. * tapset/tty.stp : Ditto. * testsuite/buildok/irq.stp : Make probe test optional. * testsuite/buildok/tty.stp : Ditto. * testsuite/systemtap.examples/network/netdev.stp : Ditto. * testsuite/buildok/tcpmib-all-probes.stp : Add embedded functions.
Diffstat (limited to 'tapset/linuxmib.stp')
-rw-r--r--tapset/linuxmib.stp4
1 files changed, 4 insertions, 0 deletions
diff --git a/tapset/linuxmib.stp b/tapset/linuxmib.stp
index e19755a9..90145b62 100644
--- a/tapset/linuxmib.stp
+++ b/tapset/linuxmib.stp
@@ -94,7 +94,11 @@ probe linuxmib.ListenDrops=kernel.function("tcp_v4_syn_recv_sock").return
*/
probe linuxmib.TCPMemoryPressures=kernel.function("tcp_enter_memory_pressure")
{
+%( kernel_v >= "2.6.27" %?
sk = $sk
+%:
+ sk = 0;
+%)
op = 1;
if ( $tcp_memory_pressure ) next
key = linuxmib_filter_key(sk,op);