diff options
author | Michael Straube <straube.linux@gmail.com> | 2021-12-29 21:50:47 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-12-30 12:02:25 +0100 |
commit | 85dbc7e3abdc24160fea1ba93bacc36e2f3c499c (patch) | |
tree | b957dedcf0ec40b3816ea50d966b16bb0132bb5f | |
parent | fec9f472fb1eefc1bfdf194cf0182963764194e7 (diff) |
staging: r8188eu: remove ODM_CompareMemory()
ODM_CompareMemory() is just a wrapper around memcmp().
Remove ODM_CompareMemory() and call memcmp() directly.
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-12-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/r8188eu/hal/HalPhyRf_8188e.c | 4 | ||||
-rw-r--r-- | drivers/staging/r8188eu/hal/odm_interface.c | 5 | ||||
-rw-r--r-- | drivers/staging/r8188eu/include/odm_interface.h | 4 |
3 files changed, 2 insertions, 11 deletions
diff --git a/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c b/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c index 5db8ea92046e..04e24beb0488 100644 --- a/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c +++ b/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c @@ -171,13 +171,13 @@ odm_TXPowerTrackingCallback_ThermalMeter_8188E( for (i = 0; i < CCK_TABLE_SIZE; i++) { if (dm_odm->RFCalibrateInfo.bCCKinCH14) { - if (ODM_CompareMemory(dm_odm, (void *)&TempCCk, (void *)&CCKSwingTable_Ch14[i][2], 4) == 0) { + if (memcmp((void *)&TempCCk, (void *)&CCKSwingTable_Ch14[i][2], 4)) { CCK_index_old = (u8)i; dm_odm->BbSwingIdxCckBase = (u8)i; break; } } else { - if (ODM_CompareMemory(dm_odm, (void *)&TempCCk, (void *)&CCKSwingTable_Ch1_Ch13[i][2], 4) == 0) { + if (memcmp((void *)&TempCCk, (void *)&CCKSwingTable_Ch1_Ch13[i][2], 4)) { CCK_index_old = (u8)i; dm_odm->BbSwingIdxCckBase = (u8)i; break; diff --git a/drivers/staging/r8188eu/hal/odm_interface.c b/drivers/staging/r8188eu/hal/odm_interface.c index 03a149069126..a70fda30a24f 100644 --- a/drivers/staging/r8188eu/hal/odm_interface.c +++ b/drivers/staging/r8188eu/hal/odm_interface.c @@ -4,8 +4,3 @@ #include "../include/odm_precomp.h" /* ODM IO Relative API. */ -/* ODM Memory relative API. */ -s32 ODM_CompareMemory(struct odm_dm_struct *pDM_Odm, void *pBuf1, void *pBuf2, u32 length) -{ - return !memcmp(pBuf1, pBuf2, length); -} diff --git a/drivers/staging/r8188eu/include/odm_interface.h b/drivers/staging/r8188eu/include/odm_interface.h index d5a75dfe0f8e..ef96d577cfa5 100644 --- a/drivers/staging/r8188eu/include/odm_interface.h +++ b/drivers/staging/r8188eu/include/odm_interface.h @@ -12,8 +12,4 @@ typedef void (*RT_WORKITEM_CALL_BACK)(void *pContext); /* =========== EXtern Function Prototype */ -/* Memory Relative Function. */ -s32 ODM_CompareMemory(struct odm_dm_struct *pDM_Odm, void *pBuf1, void *pBuf2, - u32 length); - #endif /* __ODM_INTERFACE_H__ */ |