3 @@ -182,6 +182,13 @@ static inline int timeval_compare(struct
4 #define DEV_ATH CTL_UNNUMBERED
7 +/* __skb_append got a third parameter in 2.6.14 */
8 +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,14)
9 +#define __skb_queue_after(_list, _old, _new) __skb_append(_old, _new)
10 +#elif LINUX_VERSION_CODE < KERNEL_VERSION(2,6,25)
11 +#define __skb_queue_after(_list, _old, _new) __skb_append(_old, _new, _list)
14 #endif /* __KERNEL__ */
16 #endif /* _ATH_COMPAT_H_ */
17 --- a/net80211/ieee80211_linux.h
18 +++ b/net80211/ieee80211_linux.h
19 @@ -345,13 +345,6 @@ typedef spinlock_t acl_lock_t;
20 #define ACL_LOCK_CHECK(_as)
23 -/* __skb_append got a third parameter in 2.6.14 */
24 -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,14)
25 -#define __skb_append(a,b,c) __skb_append(a, b)
26 -#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,25)
27 -#define __skb_append(a,b,c) __skb_queue_after(c, a, b)
31 * Per-node power-save queue definitions. Beware of control
32 * flow with IEEE80211_NODE_SAVEQ_LOCK/IEEE80211_NODE_SAVEQ_UNLOCK.
33 @@ -395,16 +388,16 @@ typedef spinlock_t acl_lock_t;
34 _skb = __skb_dequeue(&(_ni)->ni_savedq); \
35 (_qlen) = skb_queue_len(&(_ni)->ni_savedq); \
37 -#define _IEEE80211_NODE_SAVEQ_ENQUEUE(_ni, _skb, _qlen, _age) do {\
38 - struct sk_buff *tail = skb_peek_tail(&(_ni)->ni_savedq);\
39 - if (tail != NULL) { \
40 - _age -= M_AGE_GET(tail); \
41 - __skb_append(tail, _skb, &(_ni)->ni_savedq); \
43 - __skb_queue_head(&(_ni)->ni_savedq, _skb); \
45 - M_AGE_SET(_skb, _age); \
46 - (_qlen) = skb_queue_len(&(_ni)->ni_savedq); \
47 +#define _IEEE80211_NODE_SAVEQ_ENQUEUE(_ni, _skb, _qlen, _age) do { \
48 + struct sk_buff *tail = skb_peek_tail(&(_ni)->ni_savedq); \
49 + if (tail != NULL) { \
50 + _age -= M_AGE_GET(tail); \
51 + __skb_queue_after(&(_ni)->ni_savedq, tail, _skb); \
53 + __skb_queue_head(&(_ni)->ni_savedq, _skb); \
55 + M_AGE_SET(_skb, _age); \
56 + (_qlen) = skb_queue_len(&(_ni)->ni_savedq); \
60 --- a/net80211/ieee80211_power.c
61 +++ b/net80211/ieee80211_power.c
62 @@ -243,7 +243,7 @@ ieee80211_pwrsave(struct sk_buff *skb)
63 tail = skb_peek_tail(&ni->ni_savedq);
65 age -= M_AGE_GET(tail);
66 - __skb_append(tail, skb, &ni->ni_savedq);
67 + __skb_queue_after(&ni->ni_savedq, tail, skb);
69 __skb_queue_head(&ni->ni_savedq, skb);