mirror of
https://github.com/aircrack-ng/rtl8812au.git
synced 2024-11-26 07:04:12 +00:00
Fix FCS on 8812 and 8814
This commit is contained in:
parent
d867a451d3
commit
10bb71aafb
@ -17,13 +17,6 @@
|
|||||||
#include <drv_types.h>
|
#include <drv_types.h>
|
||||||
#include <hal_data.h>
|
#include <hal_data.h>
|
||||||
|
|
||||||
#if defined(PLATFORM_LINUX) && defined (PLATFORM_WINDOWS)
|
|
||||||
|
|
||||||
#error "Shall be Linux or Windows, but not both!\n"
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#ifdef CONFIG_NEW_SIGNAL_STAT_PROCESS
|
#ifdef CONFIG_NEW_SIGNAL_STAT_PROCESS
|
||||||
static void rtw_signal_stat_timer_hdl(void *ctx);
|
static void rtw_signal_stat_timer_hdl(void *ctx);
|
||||||
|
|
||||||
@ -4048,9 +4041,15 @@ static sint fill_radiotap_hdr(_adapter *padapter, union recv_frame *precvframe,
|
|||||||
if (pattrib->mfrag)
|
if (pattrib->mfrag)
|
||||||
hdr_buf[rt_len] |= IEEE80211_RADIOTAP_F_FRAG;
|
hdr_buf[rt_len] |= IEEE80211_RADIOTAP_F_FRAG;
|
||||||
|
|
||||||
/* always append FCS */
|
#ifdef CONFIG_RX_PACKET_APPEND_FCS
|
||||||
hdr_buf[rt_len] |= IEEE80211_RADIOTAP_F_FCS;
|
// Start by always indicating FCS is there:
|
||||||
|
hdr_buf[rt_len] |= IEEE80211_RADIOTAP_F_FCS;
|
||||||
|
|
||||||
|
// Next, test for prior conditions that will remove FCS, and update flag accordingly:
|
||||||
|
if(check_fwstate(&padapter->mlmepriv,WIFI_MONITOR_STATE) == _FALSE)
|
||||||
|
if((pattrib->pkt_rpt_type == NORMAL_RX) && (pHalData->ReceiveConfig & RCR_APPFCS))
|
||||||
|
hdr_buf[rt_len] &= ~IEEE80211_RADIOTAP_F_FCS;
|
||||||
|
#endif
|
||||||
|
|
||||||
if (0)
|
if (0)
|
||||||
hdr_buf[rt_len] |= IEEE80211_RADIOTAP_F_DATAPAD;
|
hdr_buf[rt_len] |= IEEE80211_RADIOTAP_F_DATAPAD;
|
||||||
|
@ -46,7 +46,6 @@ void interrupt_handler_8814au(_adapter *padapter, u16 pkt_len, u8 *pbuf)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#ifdef CONFIG_LPS_LCLK
|
#ifdef CONFIG_LPS_LCLK
|
||||||
if (pHalData->IntArray[0] & IMR_CPWM_88E) {
|
if (pHalData->IntArray[0] & IMR_CPWM_88E) {
|
||||||
_rtw_memcpy(&pwr_rpt.state, &(pbuf[USB_INTR_CONTENT_CPWM1_OFFSET]), 1);
|
_rtw_memcpy(&pwr_rpt.state, &(pbuf[USB_INTR_CONTENT_CPWM1_OFFSET]), 1);
|
||||||
@ -77,7 +76,6 @@ void interrupt_handler_8814au(_adapter *padapter, u16 pkt_len, u8 *pbuf)
|
|||||||
RTW_INFO("%s: HISR_TXBCNERR\n", __func__);
|
RTW_INFO("%s: HISR_TXBCNERR\n", __func__);
|
||||||
#endif /* 0 */
|
#endif /* 0 */
|
||||||
|
|
||||||
|
|
||||||
if(check_fwstate(pmlmepriv, WIFI_AP_STATE))
|
if(check_fwstate(pmlmepriv, WIFI_AP_STATE))
|
||||||
{
|
{
|
||||||
//send_beacon(padapter);
|
//send_beacon(padapter);
|
||||||
@ -184,8 +182,9 @@ int recvbuf2recvframe(PADAPTER padapter, void *ptr)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_RX_PACKET_APPEND_FCS
|
#ifdef CONFIG_RX_PACKET_APPEND_FCS
|
||||||
if(pattrib->pkt_rpt_type == NORMAL_RX)
|
if (check_fwstate(&padapter->mlmepriv, WIFI_MONITOR_STATE) == _FALSE)
|
||||||
pattrib->pkt_len -= IEEE80211_FCS_LEN;
|
if ((pattrib->pkt_rpt_type == NORMAL_RX) && (pHalData->ReceiveConfig & RCR_APPFCS))
|
||||||
|
pattrib->pkt_len -= IEEE80211_FCS_LEN;
|
||||||
#endif
|
#endif
|
||||||
if (rtw_os_alloc_recvframe(padapter, precvframe,
|
if (rtw_os_alloc_recvframe(padapter, precvframe,
|
||||||
(pbuf + pattrib->shift_sz + pattrib->drvinfo_sz + RXDESC_SIZE), pskb) == _FAIL) {
|
(pbuf + pattrib->shift_sz + pattrib->drvinfo_sz + RXDESC_SIZE), pskb) == _FAIL) {
|
||||||
@ -311,4 +310,3 @@ void rtl8814au_set_hw_type(struct dvobj_priv *pdvobj)
|
|||||||
pdvobj->HardwareType = HARDWARE_TYPE_RTL8814AU;
|
pdvobj->HardwareType = HARDWARE_TYPE_RTL8814AU;
|
||||||
RTW_INFO("CHIP TYPE: RTL8814\n");
|
RTW_INFO("CHIP TYPE: RTL8814\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user