compat-wireless: Fix USHRT_MAX undefine before 2.6.35
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 14 lines · Youquan Song
Since 2.6.35,
USHORT_MAXchange toUSHRT_MAX, which also need be updated in compat-wirelessSigned-off-by Youquan Song <[email protected]>Signed-off-by Hui Xiao <[email protected]>---
net/mac80211/sta_info.c +0
-0@@ -258,7 +258,11 @@ struct sta_info *sta_info_alloc(struct ieee80211_sub_if_data *sdata,skb_queue_head_init (&sta->tx_filtered);
net/mac80211/sta_info.c struct sta_info *sta_info_alloc(struct ieee80211_sub_if_data *sdata, · line 268
Quoted 10 lines
net/mac80211/sta_info.c +4
-0for (i =0 ; i <NUM_RX_DATA_QUEUES ; i++) +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2.6.35)) sta->last_seq_ctrl[i] =cpu_to_le16 (USHRT_MAX ); +#else + sta->last_seq_ctrl[i] =cpu_to_le16 (USHORT_MAX ); +#endif #ifdef CONFIG_MAC80211_VERBOSE_DEBUG wiphy_debug (local->hw.wiphy,"Allocated STA %pM\n" , sta->sta.addr);
Can you just #define USHRT_MAX USHORT_MAX for older kernels through compat.git ?
git://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/compat.git
Luis