1
0
mirror of https://github.com/aircrack-ng/rtl8812au.git synced 2024-11-10 08:07:05 +00:00

Merge pull request #285 from kimocoder/v5.3.4

Merge changes
This commit is contained in:
Christian Bremvåg 2019-02-23 03:33:38 +01:00 committed by GitHub
commit 3c48dff974
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 45 additions and 19 deletions

View File

@ -519,6 +519,8 @@ struct sta_info *rtw_alloc_stainfo(struct sta_priv *pstapriv, const u8 *hwaddr)
} else {
psta = LIST_CONTAINOR(get_next(&pfree_sta_queue->queue), struct sta_info, list);
if (!psta)
goto exit;
rtw_list_delete(&(psta->list));
/* _exit_critical_bh(&(pfree_sta_queue->lock), &irqL); */

View File

@ -33,7 +33,7 @@
#define PLATFORM_LINUX
/* #define CONFIG_IOCTL_CFG80211 1 */
#define CONFIG_IOCTL_CFG80211 1
#ifdef CONFIG_IOCTL_CFG80211
/* #define RTW_USE_CFG80211_STA_EVENT */ /* Indecate new sta asoc through cfg80211_new_sta */

View File

@ -1024,18 +1024,29 @@ int rtw_halmac_deinit_adapter(struct dvobj_priv *);
#define REG_APK rAPK
#define REG_ANTSEL_SW_JAGUAR r_ANTSEL_SW_Jaguar
#define rf_welut_jaguar RF_WeLut_Jaguar
#define rf_mode_table_addr RF_ModeTableAddr
#define rf_mode_table_data0 RF_ModeTableData0
#define rf_mode_table_data1 RF_ModeTableData1
#define RX_SMOOTH_FACTOR Rx_Smooth_Factor
#if defined(CONFIG_RESUME_IN_WORKQUEUE) || defined(CONFIG_HAS_EARLYSUSPEND)
int rtw_resume_process(_adapter *padapter);
#endif
#ifdef CONFIG_ANDROID_POWER
#if defined(CONFIG_USB_HCI) || defined(CONFIG_SDIO_HCI) || defined(CONFIG_GSPI_HCI)
int rtw_resume_process(PADAPTER padapter);
#endif
#endif
#ifdef CONFIG_AUTOSUSPEND
void autosuspend_enter(_adapter* padapter);
int autoresume_enter(_adapter* padapter);
#endif
#ifdef SUPPORT_HW_RFOFF_DETECTED
int rtw_hw_suspend(_adapter *padapter );
int rtw_hw_resume(_adapter *padapter);
#endif
#endif /* __HAL_DATA_H__ */

View File

@ -2525,9 +2525,13 @@ void rtw_cfg80211_unlink_bss(_adapter *padapter, struct wlan_network *pnetwork)
struct wireless_dev *pwdev = padapter->rtw_wdev;
struct wiphy *wiphy = pwdev->wiphy;
struct cfg80211_bss *bss = NULL;
WLAN_BSSID_EX select_network = pnetwork->network;
WLAN_BSSID_EX select_network;
bss = cfg80211_get_bss(wiphy, NULL/*notify_channel*/,
if (!pnetwork)
return;
select_network = pnetwork->network;
bss = cfg80211_get_bss(wiphy, NULL /*notify_channel*/,
select_network.MacAddress, select_network.Ssid.Ssid,
select_network.Ssid.SsidLength,
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 1, 0)
@ -2538,10 +2542,18 @@ void rtw_cfg80211_unlink_bss(_adapter *padapter, struct wlan_network *pnetwork)
select_network.InfrastructureMode == Ndis802_11Infrastructure?WLAN_CAPABILITY_ESS:WLAN_CAPABILITY_IBSS);
#endif
if (!wiphy) {
pr_info("rtl8723bu: rtw_cfg80211_unlink_bss: wiphy is NULL\n");
return;
}
if (bss) {
cfg80211_unlink_bss(wiphy, bss);
RTW_INFO("%s(): cfg80211_unlink %s!!\n", __func__, select_network.Ssid.Ssid);
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 9, 0)
if (!padapter->rtw_wdev->wiphy)
return;
cfg80211_put_bss(padapter->rtw_wdev->wiphy, bss);
#else
cfg80211_put_bss(bss);

View File

@ -1651,18 +1651,19 @@ void rtw_os_ndev_unregister(_adapter *adapter)
netdev = adapter->pnetdev;
#if defined(CONFIG_IOCTL_CFG80211)
rtw_cfg80211_ndev_res_unregister(adapter);
rtw_cfg80211_ndev_res_unregister(adapter);
#endif
if ((adapter->DriverState != DRIVER_DISAPPEAR) && netdev) {
struct dvobj_priv *dvobj = adapter_to_dvobj(adapter);
u8 rtnl_lock_needed = rtw_rtnl_lock_needed(dvobj);
if ((adapter->DriverState != DRIVER_DISAPPEAR) && netdev) {
struct dvobj_priv *dvobj = adapter_to_dvobj(adapter);
u8 rtnl_lock_needed = rtw_rtnl_lock_needed(dvobj);
if (rtnl_lock_needed)
unregister_netdev(netdev);
else
unregister_netdevice(netdev);
}
if (rtnl_lock_needed)
unregister_netdev(netdev);
else
unregister_netdevice(netdev);
}
#if defined(CONFIG_IOCTL_CFG80211) && !defined(RTW_SINGLE_WIPHY)
#ifdef CONFIG_RFKILL_POLL