-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsk_err.bt
80 lines (71 loc) · 2.54 KB
/
sk_err.bt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
#include <net/sock.h>
#include <net/inet_sock.h>
#include <net/inet_connection_sock.h>
#include <net/tcp.h>
#include <linux/netdevice.h>
kprobe:sk_error_report {
$sock = (struct sock *)arg0;
$isock = (struct inet_sock *)arg0;
$tsock = (struct tcp_sock *)arg0;
printf ("%s - SK_ERR(%d) saddr=%p:%hu -snd_wnd %u\n%s\n",
strftime("%H:%M:%S:%f", nsecs),
$sock->sk_err,
$isock->inet_saddr,
$isock->inet_sport,
$tsock->snd_wnd,
kstack());
}
kprobe:tcp_send_probe0 {
$sock = (struct sock *)arg0;
$isock = (struct inet_sock *)arg0;
$icsock = (struct inet_connection_sock *)arg0;
$tsock = (struct tcp_sock *)arg0;
printf ("%s - send_probe0 - saddr=%p:%hu - snd_wnd %u, icsk_probes_out = %u+1\n",
strftime("%H:%M:%S:%f", nsecs), $isock->inet_saddr,
$isock->inet_sport, $tsock->snd_wnd, $icsock->icsk_probes_out);
}
kprobe:tcp_write_timer_handler {
$sock = (struct sock *)arg0;
$isock = (struct inet_sock *)arg0;
$icsock = (struct inet_connection_sock *)arg0;
$tsock = (struct tcp_sock *)arg0;
if ($icsock->icsk_pending == ICSK_TIME_PROBE0 || $icsock->icsk_pending == ICSK_TIME_RETRANS) {
printf ("%s - write_timer - saddr=%p:%hu - snd_wnd %u, event %u\n",
strftime("%H:%M:%S:%f", nsecs), $isock->inet_saddr,
$isock->inet_sport, $tsock->snd_wnd, $icsock->icsk_pending);
}
}
kprobe:netif_carrier_off {
$dev = (struct net_device *)arg0;
printf ("%s - netif_carrier_off %s\n",
strftime("%H:%M:%S:%f", nsecs), $dev->name);
}
kprobe:dev_deactivate {
$dev = (struct net_device *)arg0;
printf ("%s - dev_deactivate %s\n",
strftime("%H:%M:%S:%f", nsecs), $dev->name);
}
kprobe: linkwatch_fire_event {
$dev = (struct net_device *)arg0;
printf ("%s - linkwatch_fire_event (sched) %s - state %d\n%s\n",
strftime("%H:%M:%S:%f", nsecs), $dev->name, $dev->state, kstack());
}
kprobe:linkwatch_do_dev {
$dev = (struct net_device *)arg0;
printf ("%s - linkwatch_do_dev %s - state %d\n",
strftime("%H:%M:%S:%f", nsecs), $dev->name, $dev->state);
}
kretprobe:__dev_direct_xmit {
if (!retval) {
return;
}
printf ("%s - direct_xmit rc = %d\n",
strftime("%H:%M:%S:%f", nsecs), retval);
}
kretprobe:dev_queue_xmit {
if (!retval) {
return;
}
printf ("%s - dev_queue_xmit rc = %d\n",
strftime("%H:%M:%S:%f", nsecs), retval);
}