1 #ifndef LINUX_3_3_COMPAT_H
2 #define LINUX_3_3_COMPAT_H
4 #include <linux/version.h>
6 #if (LINUX_VERSION_CODE < KERNEL_VERSION(3,3,0))
8 /* include to override NL80211_FEATURE_SK_TX_STATUS */
9 #include <linux/nl80211.h>
12 * This is not part of The 2.6.37 kernel yet but we
13 * we use it to optimize the backport code we
14 * need to implement. Instead of using ifdefs
15 * to check what version of the check we use
16 * we just replace all checks on current code
17 * with this. I'll submit this upstream too, that
18 * way all we'd have to do is to implement this
19 * for older kernels, then we would not have to
20 * edit the upstrema code for backport efforts.
22 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36))
23 #define br_port_exists(dev) (dev->priv_flags & IFF_BRIDGE_PORT)
25 #define br_port_exists(dev) (dev->br_port)
28 static inline void skb_complete_wifi_ack(struct sk_buff *skb, bool acked)
32 #define NL80211_FEATURE_SK_TX_STATUS 0
34 typedef u32 netdev_features_t;
36 #endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(3,3,0)) */
38 #endif /* LINUX_3_3_COMPAT_H */