]> git.pld-linux.org Git - packages/rtl8812au.git/blob - linux-4.0.patch
- rel 16
[packages/rtl8812au.git] / linux-4.0.patch
1 --- rtl8812au_linux-master/os_dep/linux/ioctl_cfg80211.c.orig   2015-04-18 20:34:59.846186483 +0200
2 +++ rtl8812au_linux-master/os_dep/linux/ioctl_cfg80211.c        2015-04-18 20:36:51.399524482 +0200
3 @@ -1736,16 +1736,32 @@
4                         goto exit;
5                 }
6  
7 +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0))
8 +               sinfo->filled |= BIT(NL80211_STA_INFO_SIGNAL);
9 +#else
10                 sinfo->filled |= STATION_INFO_SIGNAL;
11 +#endif
12                 sinfo->signal = translate_percentage_to_dbm(padapter->recvpriv.signal_strength);
13  
14 +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0))
15 +               sinfo->filled |= BIT(NL80211_STA_INFO_TX_BITRATE);
16 +#else
17                 sinfo->filled |= STATION_INFO_TX_BITRATE;
18 +#endif
19                 sinfo->txrate.legacy = rtw_get_cur_max_rate(padapter);
20  
21 +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0))
22 +               sinfo->filled |= BIT(NL80211_STA_INFO_RX_PACKETS);
23 +#else
24                 sinfo->filled |= STATION_INFO_RX_PACKETS;
25 +#endif
26                 sinfo->rx_packets = sta_rx_data_pkts(psta);
27  
28 +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0))
29 +               sinfo->filled |= BIT(NL80211_STA_INFO_TX_PACKETS);
30 +#else
31                 sinfo->filled |= STATION_INFO_TX_PACKETS;
32 +#endif
33                 sinfo->tx_packets = psta->sta_stats.tx_pkts;
34  
35         }
36 @@ -3425,7 +3425,9 @@
37                         ie_offset = _REASOCREQ_IE_OFFSET_;
38         
39                 sinfo.filled = 0;
40 +#if (LINUX_VERSION_CODE < KERNEL_VERSION(4,0,0))
41                 sinfo.filled = STATION_INFO_ASSOC_REQ_IES;
42 +#endif
43                 sinfo.assoc_req_ies = pmgmt_frame + WLAN_HDR_A3_LEN + ie_offset;
44                 sinfo.assoc_req_ies_len = frame_len - WLAN_HDR_A3_LEN - ie_offset;
45                 cfg80211_new_sta(ndev, GetAddr2Ptr(pmgmt_frame), &sinfo, GFP_ATOMIC);
46 --- rtl8812au_linux-master/os_dep/linux/rtw_android.c~  2014-07-21 15:06:45.000000000 +0200
47 +++ rtl8812au_linux-master/os_dep/linux/rtw_android.c   2015-04-18 20:42:32.736205424 +0200
48 @@ -342,7 +342,11 @@
49  {
50         int cmd_num;
51         for(cmd_num=0 ; cmd_num<ANDROID_WIFI_CMD_MAX; cmd_num++)
52 +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0))
53 +               if(0 == strncasecmp(cmdstr , android_wifi_cmd_str[cmd_num], strlen(android_wifi_cmd_str[cmd_num])) )
54 +#else
55                 if(0 == strnicmp(cmdstr , android_wifi_cmd_str[cmd_num], strlen(android_wifi_cmd_str[cmd_num])) )
56 +#endif
57                         break;
58  
59         return cmd_num;
This page took 0.024841 seconds and 3 git commands to generate.