net_dev_xmit_extended probe : cleanup unused data
[lttng-modules.git] / probes / net-extended-trace.c
index 15fc8109dba704f92c33264a6e41a62eb30111e3..d7bb4f80286aea3e0a8636e4daf38a6b6b38ad85 100644 (file)
@@ -42,6 +42,9 @@ notrace void probe_net_dev_xmit_extended(void *_data, struct sk_buff *skb)
        struct serialize_l214421224411111 data;
        struct iphdr *iph = ip_hdr(skb);
        struct tcphdr *th = tcp_hdr(skb);
+       struct udphdr *uh = udp_hdr(skb);
+
+       memset(&data, 0, sizeof(struct serialize_l214421224411111));
 
        data.f1 = (unsigned long)skb;
        data.f2 = skb->protocol;
@@ -63,6 +66,9 @@ notrace void probe_net_dev_xmit_extended(void *_data, struct sk_buff *skb)
                        data.f14 = th->rst;
                        data.f15 = th->syn;
                        data.f16 = th->fin;
+               } else if (data.f3 == IPPROTO_UDP) {
+                       data.f8 = uh->source;
+                       data.f9 = uh->dest;
                }
        }
 
This page took 0.023953 seconds and 4 git commands to generate.