-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25)
-#define IPTUNNEL_XMIT() do { \
- int err; \
- int pkt_len = skb->len - skb_transport_offset(skb); \
- \
- skb->ip_summed = CHECKSUM_NONE; \
- iph->tot_len = htons(skb->len); \
- ip_select_ident(iph, &rt->u.dst, NULL); \
- ip_send_check(iph); \
- \
- err = NF_HOOK(PF_INET, NF_IP_LOCAL_OUT, skb, NULL, rt->u.dst.dev, dst_output);\
- if (err == NET_XMIT_SUCCESS || err == NET_XMIT_CN) { \
- stats->tx_bytes += pkt_len; \
- stats->tx_packets++; \
- } else { \
- stats->tx_errors++; \
- stats->tx_aborted_errors++; \
- } \
-} while (0)
+#ifdef HAVE_NETDEV_QUEUE_STATS
+#define UPDATE_TX_STATS() \
+ txq->tx_bytes += pkt_len; \
+ txq->tx_packets++;