diff options
author | Larry Finger <Larry.Finger@lwfinger.net> | 2014-02-09 15:15:54 -0600 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-11 12:41:13 -0800 |
commit | f42f52aaf922e5bae7775dd2c3b3954719ee5f08 (patch) | |
tree | be4a7581d0c0e78c0615f940cd919a2ee61f52e0 /drivers/staging/rtl8188eu/hal | |
parent | 510fa4085277379436752d9cb20b2eb4135c34a0 (diff) |
staging: r8188eu: Replace wrapper around _rtw_memcmp()
This wrapper is replaced with a simple memcmp(). As the wrapper inverts the
logic of memcmp(), care needed to be taken.
This patch also adds one include of vmalloc.h that was missed in a previous
patch.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/rtl8188eu/hal')
-rw-r--r-- | drivers/staging/rtl8188eu/hal/HalPhyRf_8188e.c | 4 | ||||
-rw-r--r-- | drivers/staging/rtl8188eu/hal/odm.c | 4 | ||||
-rw-r--r-- | drivers/staging/rtl8188eu/hal/odm_interface.c | 33 | ||||
-rw-r--r-- | drivers/staging/rtl8188eu/hal/rtl8188e_hal_init.c | 1 | ||||
-rw-r--r-- | drivers/staging/rtl8188eu/hal/rtl8188e_mp.c | 4 | ||||
-rw-r--r-- | drivers/staging/rtl8188eu/hal/rtl8188e_rxdesc.c | 4 |
6 files changed, 9 insertions, 41 deletions
diff --git a/drivers/staging/rtl8188eu/hal/HalPhyRf_8188e.c b/drivers/staging/rtl8188eu/hal/HalPhyRf_8188e.c index 4b5caa1f397a..056052ddd82e 100644 --- a/drivers/staging/rtl8188eu/hal/HalPhyRf_8188e.c +++ b/drivers/staging/rtl8188eu/hal/HalPhyRf_8188e.c @@ -217,7 +217,7 @@ odm_TXPowerTrackingCallback_ThermalMeter_8188E( for (i = 0; i < CCK_TABLE_SIZE; i++) { if (dm_odm->RFCalibrateInfo.bCCKinCH14) { - if (_rtw_memcmp((void *)&TempCCk, (void *)&CCKSwingTable_Ch14[i][2], 4) == 0) { + if (memcmp(&TempCCk, &CCKSwingTable_Ch14[i][2], 4)) { CCK_index_old = (u8)i; dm_odm->BbSwingIdxCckBase = (u8)i; ODM_RT_TRACE(dm_odm, ODM_COMP_CALIBRATION, ODM_DBG_LOUD, @@ -229,7 +229,7 @@ odm_TXPowerTrackingCallback_ThermalMeter_8188E( ODM_RT_TRACE(dm_odm, ODM_COMP_CALIBRATION, ODM_DBG_LOUD, ("RegA24: 0x%X, CCKSwingTable_Ch1_Ch13[%d][2]: CCKSwingTable_Ch1_Ch13[i][2]: 0x%X\n", TempCCk, i, CCKSwingTable_Ch1_Ch13[i][2])); - if (_rtw_memcmp((void *)&TempCCk, (void *)&CCKSwingTable_Ch1_Ch13[i][2], 4) == 0) { + if (memcmp(&TempCCk, &CCKSwingTable_Ch1_Ch13[i][2], 4)) { CCK_index_old = (u8)i; dm_odm->BbSwingIdxCckBase = (u8)i; ODM_RT_TRACE(dm_odm, ODM_COMP_CALIBRATION, ODM_DBG_LOUD, diff --git a/drivers/staging/rtl8188eu/hal/odm.c b/drivers/staging/rtl8188eu/hal/odm.c index fc05e482be77..89a26e3e217f 100644 --- a/drivers/staging/rtl8188eu/hal/odm.c +++ b/drivers/staging/rtl8188eu/hal/odm.c @@ -1302,8 +1302,8 @@ void odm_RSSIMonitorCheckCE(struct odm_dm_struct *pDM_Odm) psta = pDM_Odm->pODM_StaInfo[i]; if (IS_STA_VALID(psta) && (psta->state & WIFI_ASOC_STATE) && - !_rtw_memcmp(psta->hwaddr, bcast_addr, ETH_ALEN) && - !_rtw_memcmp(psta->hwaddr, myid(&Adapter->eeprompriv), ETH_ALEN)) { + memcmp(psta->hwaddr, bcast_addr, ETH_ALEN) && + memcmp(psta->hwaddr, myid(&Adapter->eeprompriv), ETH_ALEN)) { if (psta->rssi_stat.UndecoratedSmoothedPWDB < tmpEntryMinPWDB) tmpEntryMinPWDB = psta->rssi_stat.UndecoratedSmoothedPWDB; diff --git a/drivers/staging/rtl8188eu/hal/odm_interface.c b/drivers/staging/rtl8188eu/hal/odm_interface.c index 710f8e1620db..8b137891791f 100644 --- a/drivers/staging/rtl8188eu/hal/odm_interface.c +++ b/drivers/staging/rtl8188eu/hal/odm_interface.c @@ -1,34 +1 @@ -/****************************************************************************** - * - * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved. - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of version 2 of the GNU General Public License as - * published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License along with - * this program; if not, write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA - * - * - ******************************************************************************/ -#include "odm_precomp.h" - -void ODM_CancelTimer(struct odm_dm_struct *pDM_Odm, struct timer_list *pTimer) -{ - _cancel_timer_ex(pTimer); -} - -/* ODM FW relative API. */ -u32 ODM_FillH2CCmd(u8 *pH2CBuffer, u32 H2CBufferLen, u32 CmdNum, - u32 *pElementID, u32 *pCmdLen, - u8 **pCmbBuffer, u8 *CmdStartSeq) -{ - return true; -} diff --git a/drivers/staging/rtl8188eu/hal/rtl8188e_hal_init.c b/drivers/staging/rtl8188eu/hal/rtl8188e_hal_init.c index f29c0038c612..524899510355 100644 --- a/drivers/staging/rtl8188eu/hal/rtl8188e_hal_init.c +++ b/drivers/staging/rtl8188eu/hal/rtl8188e_hal_init.c @@ -20,6 +20,7 @@ #define _HAL_INIT_C_ #include <linux/firmware.h> +#include <linux/vmalloc.h> #include <drv_types.h> #include <rtw_efuse.h> diff --git a/drivers/staging/rtl8188eu/hal/rtl8188e_mp.c b/drivers/staging/rtl8188eu/hal/rtl8188e_mp.c index 3d0e6c9e0310..cd2027b01df4 100644 --- a/drivers/staging/rtl8188eu/hal/rtl8188e_mp.c +++ b/drivers/staging/rtl8188eu/hal/rtl8188e_mp.c @@ -184,12 +184,12 @@ void Hal_MPT_CCKTxPowerAdjustbyIndex(struct adapter *pAdapter, bool beven) TempCCk = read_bbreg(pAdapter, rCCK0_TxFilter2, bMaskDWord) & bMaskCCK; for (i = 0; i < CCK_TABLE_SIZE; i++) { if (pDM_Odm->RFCalibrateInfo.bCCKinCH14) { - if (_rtw_memcmp((void *)&TempCCk, (void *)&CCKSwingTable_Ch14[i][2], 4)) { + if (!memcmp((void *)&TempCCk, (void *)&CCKSwingTable_Ch14[i][2], 4)) { CCK_index_old = (u8)i; break; } } else { - if (_rtw_memcmp((void *)&TempCCk, (void *)&CCKSwingTable_Ch1_Ch13[i][2], 4)) { + if (!memcmp((void *)&TempCCk, (void *)&CCKSwingTable_Ch1_Ch13[i][2], 4)) { CCK_index_old = (u8)i; break; } diff --git a/drivers/staging/rtl8188eu/hal/rtl8188e_rxdesc.c b/drivers/staging/rtl8188eu/hal/rtl8188e_rxdesc.c index 511f61cbb9e0..4e3630646bd1 100644 --- a/drivers/staging/rtl8188eu/hal/rtl8188e_rxdesc.c +++ b/drivers/staging/rtl8188eu/hal/rtl8188e_rxdesc.c @@ -158,11 +158,11 @@ void update_recvframe_phyinfo_88e(union recv_frame *precvframe, struct phy_stat pkt_info.bPacketMatchBSSID = ((!IsFrameTypeCtrl(wlanhdr)) && !pattrib->icv_err && !pattrib->crc_err && - _rtw_memcmp(get_hdr_bssid(wlanhdr), + !memcmp(get_hdr_bssid(wlanhdr), get_bssid(&padapter->mlmepriv), ETH_ALEN)); pkt_info.bPacketToSelf = pkt_info.bPacketMatchBSSID && - (_rtw_memcmp(get_da(wlanhdr), + (!memcmp(get_da(wlanhdr), myid(&padapter->eeprompriv), ETH_ALEN)); pkt_info.bPacketBeacon = pkt_info.bPacketMatchBSSID && |