summaryrefslogtreecommitdiff
path: root/drivers/staging
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-07-20 15:59:12 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-07-20 15:59:12 -0700
commit55a27055b9ea5aabf8206ed6b7777c79f4e840c3 (patch)
tree29867609589a69e8a86e6e76b0885f0dbf4ce78f /drivers/staging
parent4becf12de1a4efefd28e057750e35f4ceb32dd1d (diff)
staging: csr: remove CsrPmemFree()
It's just a wrapper around kfree() so call that instead. Cc: Mikko Virkkilä <mikko.virkkila@bluegiga.com> Cc: Lauri Hintsala <Lauri.Hintsala@bluegiga.com> Cc: Riku Mettälä <riku.mettala@bluegiga.com> Cc: Veli-Pekka Peltola <veli-pekka.peltola@bluegiga.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r--drivers/staging/csr/csr_msgconv.c5
-rw-r--r--drivers/staging/csr/csr_pmem.c11
-rw-r--r--drivers/staging/csr/csr_pmem.h15
-rw-r--r--drivers/staging/csr/csr_sched.h2
-rw-r--r--drivers/staging/csr/csr_utf16.c5
-rw-r--r--drivers/staging/csr/csr_wifi_nme_ap_free_downstream_contents.c10
-rw-r--r--drivers/staging/csr/csr_wifi_nme_ap_serialize.c15
-rw-r--r--drivers/staging/csr/csr_wifi_router_ctrl_free_downstream_contents.c24
-rw-r--r--drivers/staging/csr/csr_wifi_router_ctrl_free_upstream_contents.c18
-rw-r--r--drivers/staging/csr/csr_wifi_router_ctrl_serialize.c67
-rw-r--r--drivers/staging/csr/csr_wifi_router_free_downstream_contents.c4
-rw-r--r--drivers/staging/csr/csr_wifi_router_free_upstream_contents.c4
-rw-r--r--drivers/staging/csr/csr_wifi_router_serialize.c12
-rw-r--r--drivers/staging/csr/csr_wifi_router_transport.c4
-rw-r--r--drivers/staging/csr/csr_wifi_sme_free_downstream_contents.c46
-rw-r--r--drivers/staging/csr/csr_wifi_sme_free_upstream_contents.c90
-rw-r--r--drivers/staging/csr/csr_wifi_sme_serialize.c211
-rw-r--r--drivers/staging/csr/drv.c10
-rw-r--r--drivers/staging/csr/putest.c4
-rw-r--r--drivers/staging/csr/sme_blocking.c4
-rw-r--r--drivers/staging/csr/sme_userspace.c2
-rw-r--r--drivers/staging/csr/ul_int.c10
-rw-r--r--drivers/staging/csr/unifi_sme.c12
23 files changed, 282 insertions, 303 deletions
diff --git a/drivers/staging/csr/csr_msgconv.c b/drivers/staging/csr/csr_msgconv.c
index 04ce4ae49ccd..42e0a4aef0a7 100644
--- a/drivers/staging/csr/csr_msgconv.c
+++ b/drivers/staging/csr/csr_msgconv.c
@@ -10,6 +10,7 @@
#include <linux/module.h>
#include <linux/types.h>
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_panic.h"
#include "csr_sched.h"
@@ -312,11 +313,11 @@ void CsrMsgConvDeinit(void)
{
CsrMsgConvPrimEntry *s_next;
s_next = s->next;
- CsrPmemFree(s);
+ kfree(s);
s = s_next;
}
- CsrPmemFree(converter);
+ kfree(converter);
converter = NULL;
}
EXPORT_SYMBOL_GPL(CsrMsgConvDeinit);
diff --git a/drivers/staging/csr/csr_pmem.c b/drivers/staging/csr/csr_pmem.c
index aeb924289099..a2779256005c 100644
--- a/drivers/staging/csr/csr_pmem.c
+++ b/drivers/staging/csr/csr_pmem.c
@@ -38,14 +38,3 @@ void *CsrPmemAlloc(size_t size)
return ret;
}
EXPORT_SYMBOL_GPL(CsrPmemAlloc);
-
-void CsrPmemFree(void *ptr)
-{
- if (ptr == NULL)
- {
- return;
- }
-
- kfree(ptr);
-}
-EXPORT_SYMBOL_GPL(CsrPmemFree);
diff --git a/drivers/staging/csr/csr_pmem.h b/drivers/staging/csr/csr_pmem.h
index 5e8b6a08c63e..283aff09d867 100644
--- a/drivers/staging/csr/csr_pmem.h
+++ b/drivers/staging/csr/csr_pmem.h
@@ -45,20 +45,6 @@ void *CsrPmemAllocDebug(size_t size,
void *CsrPmemAlloc(size_t size);
#endif
-
-/*****************************************************************************
-
- NAME
- CsrPmemFree
-
- DESCRIPTION
- This function will deallocate a previously allocated block of memory.
-
- PARAMETERS
- ptr - Pointer to allocated memory.
-
-*****************************************************************************/
-void CsrPmemFree(void *ptr);
#endif
/*****************************************************************************
@@ -131,7 +117,6 @@ void *CsrPmemDebugAlloc(size_t size, CsrPmemDebugAllocType type, const char* fil
#define CsrPmemAlloc(size) CsrPmemDebugAlloc(size, CSR_PMEM_DEBUG_TYPE_PMEM_ALLOC, __FILE__, __LINE__)
void CsrPmemDebugFree(void *ptr, CsrPmemDebugAllocType type, const char* file, u32 line);
-#define CsrPmemFree(ptr) CsrPmemDebugFree(ptr, CSR_PMEM_DEBUG_TYPE_PMEM_ALLOC, __FILE__, __LINE__)
#endif
diff --git a/drivers/staging/csr/csr_sched.h b/drivers/staging/csr/csr_sched.h
index e42fca9a859f..7ae1ea5b3229 100644
--- a/drivers/staging/csr/csr_sched.h
+++ b/drivers/staging/csr/csr_sched.h
@@ -125,7 +125,7 @@ void CsrSchedBgintSet(CsrSchedBgint bgint);
* obey the convention that when a message built with CsrPmemAlloc()ed memory
* is given to CsrSchedMessagePut() then ownership of the memory is ceded to the
* scheduler - and eventually to the recipient task. I.e., the receiver of
- * the message will be expected to CsrPmemFree() the message storage.
+ * the message will be expected to kfree() the message storage.
*
* RETURNS
* void.
diff --git a/drivers/staging/csr/csr_utf16.c b/drivers/staging/csr/csr_utf16.c
index be48097cd0db..f827342b1487 100644
--- a/drivers/staging/csr/csr_utf16.c
+++ b/drivers/staging/csr/csr_utf16.c
@@ -8,6 +8,7 @@
*****************************************************************************/
#include <linux/module.h>
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_unicode.h"
#include "csr_macro.h"
@@ -881,7 +882,7 @@ u16 *CsrUtf16String2XML(u16 *str)
*outputString++ = 0;
- CsrPmemFree(str);
+ kfree(str);
}
}
@@ -1008,7 +1009,7 @@ u16 *CsrXML2Utf16String(u16 *str)
*outputString++ = 0;
- CsrPmemFree(str);
+ kfree(str);
}
}
diff --git a/drivers/staging/csr/csr_wifi_nme_ap_free_downstream_contents.c b/drivers/staging/csr/csr_wifi_nme_ap_free_downstream_contents.c
index 68123968ae93..bfc511ed49d1 100644
--- a/drivers/staging/csr/csr_wifi_nme_ap_free_downstream_contents.c
+++ b/drivers/staging/csr/csr_wifi_nme_ap_free_downstream_contents.c
@@ -9,7 +9,7 @@
*****************************************************************************/
/* Note: this is an auto-generated file. */
-
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_wifi_nme_ap_prim.h"
#include "csr_wifi_nme_ap_lib.h"
@@ -41,7 +41,7 @@ void CsrWifiNmeApFreeDownstreamMessageContents(u16 eventClass, void *message)
case CSR_WIFI_NME_AP_CONFIG_SET_REQ:
{
CsrWifiNmeApConfigSetReq *p = (CsrWifiNmeApConfigSetReq *)message;
- CsrPmemFree(p->apMacConfig.macAddressList);
+ kfree(p->apMacConfig.macAddressList);
p->apMacConfig.macAddressList = NULL;
break;
}
@@ -54,7 +54,7 @@ void CsrWifiNmeApFreeDownstreamMessageContents(u16 eventClass, void *message)
switch (p->apCredentials.nmeAuthType.authTypePersonal.pskOrPassphrase)
{
case CSR_WIFI_NME_AP_CREDENTIAL_TYPE_PASSPHRASE:
- CsrPmemFree(p->apCredentials.nmeAuthType.authTypePersonal.authPers_credentials.passphrase.passphrase);
+ kfree(p->apCredentials.nmeAuthType.authTypePersonal.authPers_credentials.passphrase.passphrase);
p->apCredentials.nmeAuthType.authTypePersonal.authPers_credentials.passphrase.passphrase = NULL;
break;
default:
@@ -68,11 +68,11 @@ void CsrWifiNmeApFreeDownstreamMessageContents(u16 eventClass, void *message)
u16 i3;
for (i3 = 0; i3 < p->p2pGoParam.operatingChanList.channelEntryListCount; i3++)
{
- CsrPmemFree(p->p2pGoParam.operatingChanList.channelEntryList[i3].operatingChannel);
+ kfree(p->p2pGoParam.operatingChanList.channelEntryList[i3].operatingChannel);
p->p2pGoParam.operatingChanList.channelEntryList[i3].operatingChannel = NULL;
}
}
- CsrPmemFree(p->p2pGoParam.operatingChanList.channelEntryList);
+ kfree(p->p2pGoParam.operatingChanList.channelEntryList);
p->p2pGoParam.operatingChanList.channelEntryList = NULL;
break;
}
diff --git a/drivers/staging/csr/csr_wifi_nme_ap_serialize.c b/drivers/staging/csr/csr_wifi_nme_ap_serialize.c
index b673c1ca421b..dcdcc32b597c 100644
--- a/drivers/staging/csr/csr_wifi_nme_ap_serialize.c
+++ b/drivers/staging/csr/csr_wifi_nme_ap_serialize.c
@@ -10,6 +10,7 @@
/* Note: this is an auto-generated file. */
#include <linux/string.h>
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_msgconv.h"
#include "csr_unicode.h"
@@ -22,7 +23,7 @@
void CsrWifiNmeApPfree(void *ptr)
{
- CsrPmemFree(ptr);
+ kfree(ptr);
}
@@ -221,8 +222,8 @@ void* CsrWifiNmeApConfigSetReqDes(u8 *buffer, size_t length)
void CsrWifiNmeApConfigSetReqSerFree(void *voidPrimitivePointer)
{
CsrWifiNmeApConfigSetReq *primitive = (CsrWifiNmeApConfigSetReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->apMacConfig.macAddressList);
- CsrPmemFree(primitive);
+ kfree(primitive->apMacConfig.macAddressList);
+ kfree(primitive);
}
@@ -555,7 +556,7 @@ void CsrWifiNmeApStartReqSerFree(void *voidPrimitivePointer)
switch (primitive->apCredentials.nmeAuthType.authTypePersonal.pskOrPassphrase)
{
case CSR_WIFI_NME_AP_CREDENTIAL_TYPE_PASSPHRASE:
- CsrPmemFree(primitive->apCredentials.nmeAuthType.authTypePersonal.authPers_credentials.passphrase.passphrase);
+ kfree(primitive->apCredentials.nmeAuthType.authTypePersonal.authPers_credentials.passphrase.passphrase);
break;
default:
break;
@@ -568,11 +569,11 @@ void CsrWifiNmeApStartReqSerFree(void *voidPrimitivePointer)
u16 i3;
for (i3 = 0; i3 < primitive->p2pGoParam.operatingChanList.channelEntryListCount; i3++)
{
- CsrPmemFree(primitive->p2pGoParam.operatingChanList.channelEntryList[i3].operatingChannel);
+ kfree(primitive->p2pGoParam.operatingChanList.channelEntryList[i3].operatingChannel);
}
}
- CsrPmemFree(primitive->p2pGoParam.operatingChanList.channelEntryList);
- CsrPmemFree(primitive);
+ kfree(primitive->p2pGoParam.operatingChanList.channelEntryList);
+ kfree(primitive);
}
diff --git a/drivers/staging/csr/csr_wifi_router_ctrl_free_downstream_contents.c b/drivers/staging/csr/csr_wifi_router_ctrl_free_downstream_contents.c
index 2329dc3af8a9..b4b724356c1e 100644
--- a/drivers/staging/csr/csr_wifi_router_ctrl_free_downstream_contents.c
+++ b/drivers/staging/csr/csr_wifi_router_ctrl_free_downstream_contents.c
@@ -9,7 +9,7 @@
*****************************************************************************/
/* Note: this is an auto-generated file. */
-
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_wifi_router_ctrl_prim.h"
#include "csr_wifi_router_ctrl_lib.h"
@@ -41,62 +41,62 @@ void CsrWifiRouterCtrlFreeDownstreamMessageContents(u16 eventClass, void *messag
case CSR_WIFI_ROUTER_CTRL_HIP_REQ:
{
CsrWifiRouterCtrlHipReq *p = (CsrWifiRouterCtrlHipReq *)message;
- CsrPmemFree(p->mlmeCommand);
+ kfree(p->mlmeCommand);
p->mlmeCommand = NULL;
- CsrPmemFree(p->dataRef1);
+ kfree(p->dataRef1);
p->dataRef1 = NULL;
- CsrPmemFree(p->dataRef2);
+ kfree(p->dataRef2);
p->dataRef2 = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_MULTICAST_ADDRESS_RES:
{
CsrWifiRouterCtrlMulticastAddressRes *p = (CsrWifiRouterCtrlMulticastAddressRes *)message;
- CsrPmemFree(p->getAddresses);
+ kfree(p->getAddresses);
p->getAddresses = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_TCLAS_ADD_REQ:
{
CsrWifiRouterCtrlTclasAddReq *p = (CsrWifiRouterCtrlTclasAddReq *)message;
- CsrPmemFree(p->tclas);
+ kfree(p->tclas);
p->tclas = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_TCLAS_DEL_REQ:
{
CsrWifiRouterCtrlTclasDelReq *p = (CsrWifiRouterCtrlTclasDelReq *)message;
- CsrPmemFree(p->tclas);
+ kfree(p->tclas);
p->tclas = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_WIFI_ON_REQ:
{
CsrWifiRouterCtrlWifiOnReq *p = (CsrWifiRouterCtrlWifiOnReq *)message;
- CsrPmemFree(p->data);
+ kfree(p->data);
p->data = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_WIFI_ON_RES:
{
CsrWifiRouterCtrlWifiOnRes *p = (CsrWifiRouterCtrlWifiOnRes *)message;
- CsrPmemFree(p->smeVersions.smeBuild);
+ kfree(p->smeVersions.smeBuild);
p->smeVersions.smeBuild = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_WAPI_RX_PKT_REQ:
{
CsrWifiRouterCtrlWapiRxPktReq *p = (CsrWifiRouterCtrlWapiRxPktReq *)message;
- CsrPmemFree(p->signal);
+ kfree(p->signal);
p->signal = NULL;
- CsrPmemFree(p->data);
+ kfree(p->data);
p->data = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_WAPI_UNICAST_TX_PKT_REQ:
{
CsrWifiRouterCtrlWapiUnicastTxPktReq *p = (CsrWifiRouterCtrlWapiUnicastTxPktReq *)message;
- CsrPmemFree(p->data);
+ kfree(p->data);
p->data = NULL;
break;
}
diff --git a/drivers/staging/csr/csr_wifi_router_ctrl_free_upstream_contents.c b/drivers/staging/csr/csr_wifi_router_ctrl_free_upstream_contents.c
index 8f1ce3d93e8f..4605c535b3b9 100644
--- a/drivers/staging/csr/csr_wifi_router_ctrl_free_upstream_contents.c
+++ b/drivers/staging/csr/csr_wifi_router_ctrl_free_upstream_contents.c
@@ -9,7 +9,7 @@
*****************************************************************************/
/* Note: this is an auto-generated file. */
-
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_wifi_router_ctrl_prim.h"
#include "csr_wifi_router_ctrl_lib.h"
@@ -41,41 +41,41 @@ void CsrWifiRouterCtrlFreeUpstreamMessageContents(u16 eventClass, void *message)
case CSR_WIFI_ROUTER_CTRL_HIP_IND:
{
CsrWifiRouterCtrlHipInd *p = (CsrWifiRouterCtrlHipInd *)message;
- CsrPmemFree(p->mlmeCommand);
+ kfree(p->mlmeCommand);
p->mlmeCommand = NULL;
- CsrPmemFree(p->dataRef1);
+ kfree(p->dataRef1);
p->dataRef1 = NULL;
- CsrPmemFree(p->dataRef2);
+ kfree(p->dataRef2);
p->dataRef2 = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_MULTICAST_ADDRESS_IND:
{
CsrWifiRouterCtrlMulticastAddressInd *p = (CsrWifiRouterCtrlMulticastAddressInd *)message;
- CsrPmemFree(p->setAddresses);
+ kfree(p->setAddresses);
p->setAddresses = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_WIFI_ON_IND:
{
CsrWifiRouterCtrlWifiOnInd *p = (CsrWifiRouterCtrlWifiOnInd *)message;
- CsrPmemFree(p->versions.routerBuild);
+ kfree(p->versions.routerBuild);
p->versions.routerBuild = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_WAPI_RX_MIC_CHECK_IND:
{
CsrWifiRouterCtrlWapiRxMicCheckInd *p = (CsrWifiRouterCtrlWapiRxMicCheckInd *)message;
- CsrPmemFree(p->signal);
+ kfree(p->signal);
p->signal = NULL;
- CsrPmemFree(p->data);
+ kfree(p->data);
p->data = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_WAPI_UNICAST_TX_ENCRYPT_IND:
{
CsrWifiRouterCtrlWapiUnicastTxEncryptInd *p = (CsrWifiRouterCtrlWapiUnicastTxEncryptInd *)message;
- CsrPmemFree(p->data);
+ kfree(p->data);
p->data = NULL;
break;
}
diff --git a/drivers/staging/csr/csr_wifi_router_ctrl_serialize.c b/drivers/staging/csr/csr_wifi_router_ctrl_serialize.c
index 330eb9523904..7340f58b6599 100644
--- a/drivers/staging/csr/csr_wifi_router_ctrl_serialize.c
+++ b/drivers/staging/csr/csr_wifi_router_ctrl_serialize.c
@@ -10,6 +10,7 @@
/* Note: this is an auto-generated file. */
#include <linux/string.h>
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_msgconv.h"
#include "csr_unicode.h"
@@ -20,7 +21,7 @@
void CsrWifiRouterCtrlPfree(void *ptr)
{
- CsrPmemFree(ptr);
+ kfree(ptr);
}
@@ -148,10 +149,10 @@ void* CsrWifiRouterCtrlHipReqDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlHipReqSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlHipReq *primitive = (CsrWifiRouterCtrlHipReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->mlmeCommand);
- CsrPmemFree(primitive->dataRef1);
- CsrPmemFree(primitive->dataRef2);
- CsrPmemFree(primitive);
+ kfree(primitive->mlmeCommand);
+ kfree(primitive->dataRef1);
+ kfree(primitive->dataRef2);
+ kfree(primitive);
}
@@ -269,8 +270,8 @@ void* CsrWifiRouterCtrlMulticastAddressResDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlMulticastAddressResSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlMulticastAddressRes *primitive = (CsrWifiRouterCtrlMulticastAddressRes *) voidPrimitivePointer;
- CsrPmemFree(primitive->getAddresses);
- CsrPmemFree(primitive);
+ kfree(primitive->getAddresses);
+ kfree(primitive);
}
@@ -457,8 +458,8 @@ void* CsrWifiRouterCtrlTclasAddReqDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlTclasAddReqSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlTclasAddReq *primitive = (CsrWifiRouterCtrlTclasAddReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->tclas);
- CsrPmemFree(primitive);
+ kfree(primitive->tclas);
+ kfree(primitive);
}
@@ -555,8 +556,8 @@ void* CsrWifiRouterCtrlTclasDelReqDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlTclasDelReqSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlTclasDelReq *primitive = (CsrWifiRouterCtrlTclasDelReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->tclas);
- CsrPmemFree(primitive);
+ kfree(primitive->tclas);
+ kfree(primitive);
}
@@ -710,8 +711,8 @@ void* CsrWifiRouterCtrlWifiOnReqDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlWifiOnReqSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlWifiOnReq *primitive = (CsrWifiRouterCtrlWifiOnReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->data);
- CsrPmemFree(primitive);
+ kfree(primitive->data);
+ kfree(primitive);
}
@@ -791,8 +792,8 @@ void* CsrWifiRouterCtrlWifiOnResDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlWifiOnResSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlWifiOnRes *primitive = (CsrWifiRouterCtrlWifiOnRes *) voidPrimitivePointer;
- CsrPmemFree(primitive->smeVersions.smeBuild);
- CsrPmemFree(primitive);
+ kfree(primitive->smeVersions.smeBuild);
+ kfree(primitive);
}
@@ -1185,9 +1186,9 @@ void* CsrWifiRouterCtrlWapiRxPktReqDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlWapiRxPktReqSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlWapiRxPktReq *primitive = (CsrWifiRouterCtrlWapiRxPktReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->signal);
- CsrPmemFree(primitive->data);
- CsrPmemFree(primitive);
+ kfree(primitive->signal);
+ kfree(primitive->data);
+ kfree(primitive);
}
@@ -1245,8 +1246,8 @@ void* CsrWifiRouterCtrlWapiUnicastTxPktReqDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlWapiUnicastTxPktReqSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlWapiUnicastTxPktReq *primitive = (CsrWifiRouterCtrlWapiUnicastTxPktReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->data);
- CsrPmemFree(primitive);
+ kfree(primitive->data);
+ kfree(primitive);
}
@@ -1335,10 +1336,10 @@ void* CsrWifiRouterCtrlHipIndDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlHipIndSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlHipInd *primitive = (CsrWifiRouterCtrlHipInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->mlmeCommand);
- CsrPmemFree(primitive->dataRef1);
- CsrPmemFree(primitive->dataRef2);
- CsrPmemFree(primitive);
+ kfree(primitive->mlmeCommand);
+ kfree(primitive->dataRef1);
+ kfree(primitive->dataRef2);
+ kfree(primitive);
}
@@ -1414,8 +1415,8 @@ void* CsrWifiRouterCtrlMulticastAddressIndDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlMulticastAddressIndSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlMulticastAddressInd *primitive = (CsrWifiRouterCtrlMulticastAddressInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->setAddresses);
- CsrPmemFree(primitive);
+ kfree(primitive->setAddresses);
+ kfree(primitive);
}
@@ -1839,8 +1840,8 @@ void* CsrWifiRouterCtrlWifiOnIndDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlWifiOnIndSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlWifiOnInd *primitive = (CsrWifiRouterCtrlWifiOnInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->versions.routerBuild);
- CsrPmemFree(primitive);
+ kfree(primitive->versions.routerBuild);
+ kfree(primitive);
}
@@ -2482,9 +2483,9 @@ void* CsrWifiRouterCtrlWapiRxMicCheckIndDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlWapiRxMicCheckIndSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlWapiRxMicCheckInd *primitive = (CsrWifiRouterCtrlWapiRxMicCheckInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->signal);
- CsrPmemFree(primitive->data);
- CsrPmemFree(primitive);
+ kfree(primitive->signal);
+ kfree(primitive->data);
+ kfree(primitive);
}
@@ -2587,8 +2588,8 @@ void* CsrWifiRouterCtrlWapiUnicastTxEncryptIndDes(u8 *buffer, size_t length)
void CsrWifiRouterCtrlWapiUnicastTxEncryptIndSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterCtrlWapiUnicastTxEncryptInd *primitive = (CsrWifiRouterCtrlWapiUnicastTxEncryptInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->data);
- CsrPmemFree(primitive);
+ kfree(primitive->data);
+ kfree(primitive);
}
diff --git a/drivers/staging/csr/csr_wifi_router_free_downstream_contents.c b/drivers/staging/csr/csr_wifi_router_free_downstream_contents.c
index 24d4ae209908..fbd5b35551c2 100644
--- a/drivers/staging/csr/csr_wifi_router_free_downstream_contents.c
+++ b/drivers/staging/csr/csr_wifi_router_free_downstream_contents.c
@@ -9,7 +9,7 @@
*****************************************************************************/
/* Note: this is an auto-generated file. */
-
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_wifi_router_prim.h"
#include "csr_wifi_router_lib.h"
@@ -41,7 +41,7 @@ void CsrWifiRouterFreeDownstreamMessageContents(u16 eventClass, void *message)
case CSR_WIFI_ROUTER_MA_PACKET_REQ:
{
CsrWifiRouterMaPacketReq *p = (CsrWifiRouterMaPacketReq *)message;
- CsrPmemFree(p->frame);
+ kfree(p->frame);
p->frame = NULL;
break;
}
diff --git a/drivers/staging/csr/csr_wifi_router_free_upstream_contents.c b/drivers/staging/csr/csr_wifi_router_free_upstream_contents.c
index 2faaaace9dab..60f6ecd4472e 100644
--- a/drivers/staging/csr/csr_wifi_router_free_upstream_contents.c
+++ b/drivers/staging/csr/csr_wifi_router_free_upstream_contents.c
@@ -9,7 +9,7 @@
*****************************************************************************/
/* Note: this is an auto-generated file. */
-
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_wifi_router_prim.h"
#include "csr_wifi_router_lib.h"
@@ -41,7 +41,7 @@ void CsrWifiRouterFreeUpstreamMessageContents(u16 eventClass, void *message)
case CSR_WIFI_ROUTER_MA_PACKET_IND:
{
CsrWifiRouterMaPacketInd *p = (CsrWifiRouterMaPacketInd *)message;
- CsrPmemFree(p->frame);
+ kfree(p->frame);
p->frame = NULL;
break;
}
diff --git a/drivers/staging/csr/csr_wifi_router_serialize.c b/drivers/staging/csr/csr_wifi_router_serialize.c
index f8447c8e231f..dd2c2cee5de1 100644
--- a/drivers/staging/csr/csr_wifi_router_serialize.c
+++ b/drivers/staging/csr/csr_wifi_router_serialize.c
@@ -9,7 +9,7 @@
*****************************************************************************/
/* Note: this is an auto-generated file. */
-
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_msgconv.h"
#include "csr_unicode.h"
@@ -20,7 +20,7 @@
void CsrWifiRouterPfree(void *ptr)
{
- CsrPmemFree(ptr);
+ kfree(ptr);
}
@@ -136,8 +136,8 @@ void* CsrWifiRouterMaPacketReqDes(u8 *buffer, size_t length)
void CsrWifiRouterMaPacketReqSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterMaPacketReq *primitive = (CsrWifiRouterMaPacketReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->frame);
- CsrPmemFree(primitive);
+ kfree(primitive->frame);
+ kfree(primitive);
}
@@ -415,8 +415,8 @@ void* CsrWifiRouterMaPacketIndDes(u8 *buffer, size_t length)
void CsrWifiRouterMaPacketIndSerFree(void *voidPrimitivePointer)
{
CsrWifiRouterMaPacketInd *primitive = (CsrWifiRouterMaPacketInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->frame);
- CsrPmemFree(primitive);
+ kfree(primitive->frame);
+ kfree(primitive);
}
diff --git a/drivers/staging/csr/csr_wifi_router_transport.c b/drivers/staging/csr/csr_wifi_router_transport.c
index f340780a27af..5d86aa88a40d 100644
--- a/drivers/staging/csr/csr_wifi_router_transport.c
+++ b/drivers/staging/csr/csr_wifi_router_transport.c
@@ -155,7 +155,7 @@ void CsrWifiRouterTransportRecv(unifi_priv_t *priv, u8* buffer, size_t bufferLen
unifi_error(priv, "CsrWifiRouterTransportDeserialiseAndSend unhandled prim type 0x%.4X\n", primType);
break;
}
- CsrPmemFree(msg);
+ kfree(msg);
}
static void CsrWifiRouterTransportSerialiseAndSend(u16 primType, void* msg)
@@ -193,7 +193,7 @@ static void CsrWifiRouterTransportSerialiseAndSend(u16 primType, void* msg)
uf_sme_queue_message(drvpriv, encodeBuffer, encodeBufferLen);
/* Do not use msgEntry->freeFunc because the memory is owned by the driver */
- CsrPmemFree(msg);
+ kfree(msg);
}
#if defined(CSR_LOG_ENABLE) && defined(CSR_LOG_INCLUDE_FILE_NAME_AND_LINE_NUMBER)
diff --git a/drivers/staging/csr/csr_wifi_sme_free_downstream_contents.c b/drivers/staging/csr/csr_wifi_sme_free_downstream_contents.c
index 826ef3a9b828..ae3fec896aaf 100644
--- a/drivers/staging/csr/csr_wifi_sme_free_downstream_contents.c
+++ b/drivers/staging/csr/csr_wifi_sme_free_downstream_contents.c
@@ -9,7 +9,7 @@
*****************************************************************************/
/* Note: this is an auto-generated file. */
-
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_wifi_sme_prim.h"
#include "csr_wifi_sme_lib.h"
@@ -41,90 +41,90 @@ void CsrWifiSmeFreeDownstreamMessageContents(u16 eventClass, void *message)
case CSR_WIFI_SME_BLACKLIST_REQ:
{
CsrWifiSmeBlacklistReq *p = (CsrWifiSmeBlacklistReq *)message;
- CsrPmemFree(p->setAddresses);
+ kfree(p->setAddresses);
p->setAddresses = NULL;
break;
}
case CSR_WIFI_SME_CALIBRATION_DATA_SET_REQ:
{
CsrWifiSmeCalibrationDataSetReq *p = (CsrWifiSmeCalibrationDataSetReq *)message;
- CsrPmemFree(p->calibrationData);
+ kfree(p->calibrationData);
p->calibrationData = NULL;
break;
}
case CSR_WIFI_SME_CONNECT_REQ:
{
CsrWifiSmeConnectReq *p = (CsrWifiSmeConnectReq *)message;
- CsrPmemFree(p->connectionConfig.mlmeAssociateReqInformationElements);
+ kfree(p->connectionConfig.mlmeAssociateReqInformationElements);
p->connectionConfig.mlmeAssociateReqInformationElements = NULL;
break;
}
case CSR_WIFI_SME_MIB_GET_NEXT_REQ:
{
CsrWifiSmeMibGetNextReq *p = (CsrWifiSmeMibGetNextReq *)message;
- CsrPmemFree(p->mibAttribute);
+ kfree(p->mibAttribute);
p->mibAttribute = NULL;
break;
}
case CSR_WIFI_SME_MIB_GET_REQ:
{
CsrWifiSmeMibGetReq *p = (CsrWifiSmeMibGetReq *)message;
- CsrPmemFree(p->mibAttribute);
+ kfree(p->mibAttribute);
p->mibAttribute = NULL;
break;
}
case CSR_WIFI_SME_MIB_SET_REQ:
{
CsrWifiSmeMibSetReq *p = (CsrWifiSmeMibSetReq *)message;
- CsrPmemFree(p->mibAttribute);
+ kfree(p->mibAttribute);
p->mibAttribute = NULL;
break;
}
case CSR_WIFI_SME_MULTICAST_ADDRESS_REQ:
{
CsrWifiSmeMulticastAddressReq *p = (CsrWifiSmeMulticastAddressReq *)message;
- CsrPmemFree(p->setAddresses);
+ kfree(p->setAddresses);
p->setAddresses = NULL;
break;
}
case CSR_WIFI_SME_PACKET_FILTER_SET_REQ:
{
CsrWifiSmePacketFilterSetReq *p = (CsrWifiSmePacketFilterSetReq *)message;
- CsrPmemFree(p->filter);
+ kfree(p->filter);
p->filter = NULL;
break;
}
case CSR_WIFI_SME_PMKID_REQ:
{
CsrWifiSmePmkidReq *p = (CsrWifiSmePmkidReq *)message;
- CsrPmemFree(p->setPmkids);
+ kfree(p->setPmkids);
p->setPmkids = NULL;
break;
}
case CSR_WIFI_SME_SCAN_CONFIG_SET_REQ:
{
CsrWifiSmeScanConfigSetReq *p = (CsrWifiSmeScanConfigSetReq *)message;
- CsrPmemFree(p->scanConfig.passiveChannelList);
+ kfree(p->scanConfig.passiveChannelList);
p->scanConfig.passiveChannelList = NULL;
break;
}
case CSR_WIFI_SME_SCAN_FULL_REQ:
{
CsrWifiSmeScanFullReq *p = (CsrWifiSmeScanFullReq *)message;
- CsrPmemFree(p->ssid);
+ kfree(p->ssid);
p->ssid = NULL;
- CsrPmemFree(p->channelList);
+ kfree(p->channelList);
p->channelList = NULL;
- CsrPmemFree(p->probeIe);
+ kfree(p->probeIe);
p->probeIe = NULL;
break;
}
case CSR_WIFI_SME_TSPEC_REQ:
{
CsrWifiSmeTspecReq *p = (CsrWifiSmeTspecReq *)message;
- CsrPmemFree(p->tspec);
+ kfree(p->tspec);
p->tspec = NULL;
- CsrPmemFree(p->tclas);
+ kfree(p->tclas);
p->tclas = NULL;
break;
}
@@ -135,11 +135,11 @@ void CsrWifiSmeFreeDownstreamMessageContents(u16 eventClass, void *message)
u16 i1;
for (i1 = 0; i1 < p->mibFilesCount; i1++)
{
- CsrPmemFree(p->mibFiles[i1].data);
+ kfree(p->mibFiles[i1].data);
p->mibFiles[i1].data = NULL;
}
}
- CsrPmemFree(p->mibFiles);
+ kfree(p->mibFiles);
p->mibFiles = NULL;
break;
}
@@ -150,32 +150,32 @@ void CsrWifiSmeFreeDownstreamMessageContents(u16 eventClass, void *message)
u16 i1;
for (i1 = 0; i1 < p->mibFilesCount; i1++)
{
- CsrPmemFree(p->mibFiles[i1].data);
+ kfree(p->mibFiles[i1].data);
p->mibFiles[i1].data = NULL;
}
}
- CsrPmemFree(p->mibFiles);
+ kfree(p->mibFiles);
p->mibFiles = NULL;
break;
}
case CSR_WIFI_SME_CLOAKED_SSIDS_SET_REQ:
{
CsrWifiSmeCloakedSsidsSetReq *p = (CsrWifiSmeCloakedSsidsSetReq *)message;
- CsrPmemFree(p->cloakedSsids.cloakedSsids);
+ kfree(p->cloakedSsids.cloakedSsids);
p->cloakedSsids.cloakedSsids = NULL;
break;
}
case CSR_WIFI_SME_WPS_CONFIGURATION_REQ:
{
CsrWifiSmeWpsConfigurationReq *p = (CsrWifiSmeWpsConfigurationReq *)message;
- CsrPmemFree(p->wpsConfig.secondaryDeviceType);
+ kfree(p->wpsConfig.secondaryDeviceType);
p->wpsConfig.secondaryDeviceType = NULL;
break;
}
case CSR_WIFI_SME_SET_REQ:
{
CsrWifiSmeSetReq *p = (CsrWifiSmeSetReq *)message;
- CsrPmemFree(p->data);
+ kfree(p->data);
p->data = NULL;
break;
}
diff --git a/drivers/staging/csr/csr_wifi_sme_free_upstream_contents.c b/drivers/staging/csr/csr_wifi_sme_free_upstream_contents.c
index c34b57e960dd..1977747a51d1 100644
--- a/drivers/staging/csr/csr_wifi_sme_free_upstream_contents.c
+++ b/drivers/staging/csr/csr_wifi_sme_free_upstream_contents.c
@@ -9,7 +9,7 @@
*****************************************************************************/
/* Note: this is an auto-generated file. */
-
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_wifi_sme_prim.h"
#include "csr_wifi_sme_lib.h"
@@ -41,121 +41,121 @@ void CsrWifiSmeFreeUpstreamMessageContents(u16 eventClass, void *message)
case CSR_WIFI_SME_ASSOCIATION_COMPLETE_IND:
{
CsrWifiSmeAssociationCompleteInd *p = (CsrWifiSmeAssociationCompleteInd *)message;
- CsrPmemFree(p->connectionInfo.beaconFrame);
+ kfree(p->connectionInfo.beaconFrame);
p->connectionInfo.beaconFrame = NULL;
- CsrPmemFree(p->connectionInfo.associationReqFrame);
+ kfree(p->connectionInfo.associationReqFrame);
p->connectionInfo.associationReqFrame = NULL;
- CsrPmemFree(p->connectionInfo.associationRspFrame);
+ kfree(p->connectionInfo.associationRspFrame);
p->connectionInfo.associationRspFrame = NULL;
- CsrPmemFree(p->connectionInfo.assocScanInfoElements);
+ kfree(p->connectionInfo.assocScanInfoElements);
p->connectionInfo.assocScanInfoElements = NULL;
- CsrPmemFree(p->connectionInfo.assocReqInfoElements);
+ kfree(p->connectionInfo.assocReqInfoElements);
p->connectionInfo.assocReqInfoElements = NULL;
- CsrPmemFree(p->connectionInfo.assocRspInfoElements);
+ kfree(p->connectionInfo.assocRspInfoElements);
p->connectionInfo.assocRspInfoElements = NULL;
break;
}
case CSR_WIFI_SME_BLACKLIST_CFM:
{
CsrWifiSmeBlacklistCfm *p = (CsrWifiSmeBlacklistCfm *)message;
- CsrPmemFree(p->getAddresses);
+ kfree(p->getAddresses);
p->getAddresses = NULL;
break;
}
case CSR_WIFI_SME_CALIBRATION_DATA_GET_CFM:
{
CsrWifiSmeCalibrationDataGetCfm *p = (CsrWifiSmeCalibrationDataGetCfm *)message;
- CsrPmemFree(p->calibrationData);
+ kfree(p->calibrationData);
p->calibrationData = NULL;
break;
}
case CSR_WIFI_SME_CONNECTION_CONFIG_GET_CFM:
{
CsrWifiSmeConnectionConfigGetCfm *p = (CsrWifiSmeConnectionConfigGetCfm *)message;
- CsrPmemFree(p->connectionConfig.mlmeAssociateReqInformationElements);
+ kfree(p->connectionConfig.mlmeAssociateReqInformationElements);
p->connectionConfig.mlmeAssociateReqInformationElements = NULL;
break;
}
case CSR_WIFI_SME_CONNECTION_INFO_GET_CFM:
{
CsrWifiSmeConnectionInfoGetCfm *p = (CsrWifiSmeConnectionInfoGetCfm *)message;
- CsrPmemFree(p->connectionInfo.beaconFrame);
+ kfree(p->connectionInfo.beaconFrame);
p->connectionInfo.beaconFrame = NULL;
- CsrPmemFree(p->connectionInfo.associationReqFrame);
+ kfree(p->connectionInfo.associationReqFrame);
p->connectionInfo.associationReqFrame = NULL;
- CsrPmemFree(p->connectionInfo.associationRspFrame);
+ kfree(p->connectionInfo.associationRspFrame);
p->connectionInfo.associationRspFrame = NULL;
- CsrPmemFree(p->connectionInfo.assocScanInfoElements);
+ kfree(p->connectionInfo.assocScanInfoElements);
p->connectionInfo.assocScanInfoElements = NULL;
- CsrPmemFree(p->connectionInfo.assocReqInfoElements);
+ kfree(p->connectionInfo.assocReqInfoElements);
p->connectionInfo.assocReqInfoElements = NULL;
- CsrPmemFree(p->connectionInfo.assocRspInfoElements);
+ kfree(p->connectionInfo.assocRspInfoElements);
p->connectionInfo.assocRspInfoElements = NULL;
break;
}
case CSR_WIFI_SME_MEDIA_STATUS_IND:
{
CsrWifiSmeMediaStatusInd *p = (CsrWifiSmeMediaStatusInd *)message;
- CsrPmemFree(p->connectionInfo.beaconFrame);
+ kfree(p->connectionInfo.beaconFrame);
p->connectionInfo.beaconFrame = NULL;
- CsrPmemFree(p->connectionInfo.associationReqFrame);
+ kfree(p->connectionInfo.associationReqFrame);
p->connectionInfo.associationReqFrame = NULL;
- CsrPmemFree(p->connectionInfo.associationRspFrame);
+ kfree(p->connectionInfo.associationRspFrame);
p->connectionInfo.associationRspFrame = NULL;
- CsrPmemFree(p->connectionInfo.assocScanInfoElements);
+ kfree(p->connectionInfo.assocScanInfoElements);
p->connectionInfo.assocScanInfoElements = NULL;
- CsrPmemFree(p->connectionInfo.assocReqInfoElements);
+ kfree(p->connectionInfo.assocReqInfoElements);
p->connectionInfo.assocReqInfoElements = NULL;
- CsrPmemFree(p->connectionInfo.assocRspInfoElements);
+ kfree(p->connectionInfo.assocRspInfoElements);
p->connectionInfo.assocRspInfoElements = NULL;
break;
}
case CSR_WIFI_SME_MIB_GET_CFM:
{
CsrWifiSmeMibGetCfm *p = (CsrWifiSmeMibGetCfm *)message;
- CsrPmemFree(p->mibAttribute);
+ kfree(p->mibAttribute);
p->mibAttribute = NULL;
break;
}
case CSR_WIFI_SME_MIB_GET_NEXT_CFM:
{
CsrWifiSmeMibGetNextCfm *p = (CsrWifiSmeMibGetNextCfm *)message;
- CsrPmemFree(p->mibAttribute);
+ kfree(p->mibAttribute);
p->mibAttribute = NULL;
break;
}
case CSR_WIFI_SME_MULTICAST_ADDRESS_CFM:
{
CsrWifiSmeMulticastAddressCfm *p = (CsrWifiSmeMulticastAddressCfm *)message;
- CsrPmemFree(p->getAddresses);
+ kfree(p->getAddresses);
p->getAddresses = NULL;
break;
}
case CSR_WIFI_SME_PMKID_CANDIDATE_LIST_IND:
{
CsrWifiSmePmkidCandidateListInd *p = (CsrWifiSmePmkidCandidateListInd *)message;
- CsrPmemFree(p->pmkidCandidates);
+ kfree(p->pmkidCandidates);
p->pmkidCandidates = NULL;
break;
}
case CSR_WIFI_SME_PMKID_CFM:
{
CsrWifiSmePmkidCfm *p = (CsrWifiSmePmkidCfm *)message;
- CsrPmemFree(p->getPmkids);
+ kfree(p->getPmkids);
p->getPmkids = NULL;
break;
}
case CSR_WIFI_SME_SCAN_CONFIG_GET_CFM:
{
CsrWifiSmeScanConfigGetCfm *p = (CsrWifiSmeScanConfigGetCfm *)message;
- CsrPmemFree(p->scanConfig.passiveChannelList);
+ kfree(p->scanConfig.passiveChannelList);
p->scanConfig.passiveChannelList = NULL;
break;
}
case CSR_WIFI_SME_SCAN_RESULT_IND:
{
CsrWifiSmeScanResultInd *p = (CsrWifiSmeScanResultInd *)message;
- CsrPmemFree(p->result.informationElements);
+ kfree(p->result.informationElements);
p->result.informationElements = NULL;
switch (p->result.p2pDeviceRole)
{
@@ -164,15 +164,15 @@ void CsrWifiSmeFreeUpstreamMessageContents(u16 eventClass, void *message)
u16 i4;
for (i4 = 0; i4 < p->result.deviceInfo.groupInfo.p2pClientInfoCount; i4++)
{
- CsrPmemFree(p->result.deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType);
+ kfree(p->result.deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType);
p->result.deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType = NULL;
}
}
- CsrPmemFree(p->result.deviceInfo.groupInfo.p2PClientInfo);
+ kfree(p->result.deviceInfo.groupInfo.p2PClientInfo);
p->result.deviceInfo.groupInfo.p2PClientInfo = NULL;
break;
case CSR_WIFI_SME_P2P_ROLE_STANDALONE:
- CsrPmemFree(p->result.deviceInfo.standalonedevInfo.secDeviceType);
+ kfree(p->result.deviceInfo.standalonedevInfo.secDeviceType);
p->result.deviceInfo.standalonedevInfo.secDeviceType = NULL;
break;
default:
@@ -187,7 +187,7 @@ void CsrWifiSmeFreeUpstreamMessageContents(u16 eventClass, void *message)
u16 i1;
for (i1 = 0; i1 < p->scanResultsCount; i1++)
{
- CsrPmemFree(p->scanResults[i1].informationElements);
+ kfree(p->scanResults[i1].informationElements);
p->scanResults[i1].informationElements = NULL;
switch (p->scanResults[i1].p2pDeviceRole)
{
@@ -196,15 +196,15 @@ void CsrWifiSmeFreeUpstreamMessageContents(u16 eventClass, void *message)
u16 i4;
for (i4 = 0; i4 < p->scanResults[i1].deviceInfo.groupInfo.p2pClientInfoCount; i4++)
{
- CsrPmemFree(p->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType);
+ kfree(p->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType);
p->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType = NULL;
}
}
- CsrPmemFree(p->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo);
+ kfree(p->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo);
p->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo = NULL;
break;
case CSR_WIFI_SME_P2P_ROLE_STANDALONE:
- CsrPmemFree(p->scanResults[i1].deviceInfo.standalonedevInfo.secDeviceType);
+ kfree(p->scanResults[i1].deviceInfo.standalonedevInfo.secDeviceType);
p->scanResults[i1].deviceInfo.standalonedevInfo.secDeviceType = NULL;
break;
default:
@@ -212,58 +212,58 @@ void CsrWifiSmeFreeUpstreamMessageContents(u16 eventClass, void *message)
}
}
}
- CsrPmemFree(p->scanResults);
+ kfree(p->scanResults);
p->scanResults = NULL;
break;
}
case CSR_WIFI_SME_TSPEC_IND:
{
CsrWifiSmeTspecInd *p = (CsrWifiSmeTspecInd *)message;
- CsrPmemFree(p->tspec);
+ kfree(p->tspec);
p->tspec = NULL;
break;
}
case CSR_WIFI_SME_TSPEC_CFM:
{
CsrWifiSmeTspecCfm *p = (CsrWifiSmeTspecCfm *)message;
- CsrPmemFree(p->tspec);
+ kfree(p->tspec);
p->tspec = NULL;
break;
}
case CSR_WIFI_SME_VERSIONS_GET_CFM:
{
CsrWifiSmeVersionsGetCfm *p = (CsrWifiSmeVersionsGetCfm *)message;
- CsrPmemFree(p->versions.routerBuild);
+ kfree(p->versions.routerBuild);
p->versions.routerBuild = NULL;
- CsrPmemFree(p->versions.smeBuild);
+ kfree(p->versions.smeBuild);
p->versions.smeBuild = NULL;
break;
}
case CSR_WIFI_SME_CLOAKED_SSIDS_GET_CFM:
{
CsrWifiSmeCloakedSsidsGetCfm *p = (CsrWifiSmeCloakedSsidsGetCfm *)message;
- CsrPmemFree(p->cloakedSsids.cloakedSsids);
+ kfree(p->cloakedSsids.cloakedSsids);
p->cloakedSsids.cloakedSsids = NULL;
break;
}
case CSR_WIFI_SME_ERROR_IND:
{
CsrWifiSmeErrorInd *p = (CsrWifiSmeErrorInd *)message;
- CsrPmemFree(p->errorMessage);
+ kfree(p->errorMessage);
p->errorMessage = NULL;
break;
}
case CSR_WIFI_SME_INFO_IND:
{
CsrWifiSmeInfoInd *p = (CsrWifiSmeInfoInd *)message;
- CsrPmemFree(p->infoMessage);
+ kfree(p->infoMessage);
p->infoMessage = NULL;
break;
}
case CSR_WIFI_SME_CORE_DUMP_IND:
{
CsrWifiSmeCoreDumpInd *p = (CsrWifiSmeCoreDumpInd *)message;
- CsrPmemFree(p->data);
+ kfree(p->data);
p->data = NULL;
break;
}
diff --git a/drivers/staging/csr/csr_wifi_sme_serialize.c b/drivers/staging/csr/csr_wifi_sme_serialize.c
index 27e969caf1dd..57b4cf060f70 100644
--- a/drivers/staging/csr/csr_wifi_sme_serialize.c
+++ b/drivers/staging/csr/csr_wifi_sme_serialize.c
@@ -10,6 +10,7 @@
/* Note: this is an auto-generated file. */
#include <linux/string.h>
+#include <linux/slab.h>
#include "csr_pmem.h"
#include "csr_msgconv.h"
#include "csr_unicode.h"
@@ -20,7 +21,7 @@
void CsrWifiSmePfree(void *ptr)
{
- CsrPmemFree(ptr);
+ kfree(ptr);
}
@@ -135,8 +136,8 @@ void* CsrWifiSmeBlacklistReqDes(u8 *buffer, size_t length)
void CsrWifiSmeBlacklistReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeBlacklistReq *primitive = (CsrWifiSmeBlacklistReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->setAddresses);
- CsrPmemFree(primitive);
+ kfree(primitive->setAddresses);
+ kfree(primitive);
}
@@ -191,8 +192,8 @@ void* CsrWifiSmeCalibrationDataSetReqDes(u8 *buffer, size_t length)
void CsrWifiSmeCalibrationDataSetReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeCalibrationDataSetReq *primitive = (CsrWifiSmeCalibrationDataSetReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->calibrationData);
- CsrPmemFree(primitive);
+ kfree(primitive->calibrationData);
+ kfree(primitive);
}
@@ -400,8 +401,8 @@ void* CsrWifiSmeConnectReqDes(u8 *buffer, size_t length)
void CsrWifiSmeConnectReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeConnectReq *primitive = (CsrWifiSmeConnectReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->connectionConfig.mlmeAssociateReqInformationElements);
- CsrPmemFree(primitive);
+ kfree(primitive->connectionConfig.mlmeAssociateReqInformationElements);
+ kfree(primitive);
}
@@ -618,8 +619,8 @@ void* CsrWifiSmeMibGetNextReqDes(u8 *buffer, size_t length)
void CsrWifiSmeMibGetNextReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeMibGetNextReq *primitive = (CsrWifiSmeMibGetNextReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->mibAttribute);
- CsrPmemFree(primitive);
+ kfree(primitive->mibAttribute);
+ kfree(primitive);
}
@@ -674,8 +675,8 @@ void* CsrWifiSmeMibGetReqDes(u8 *buffer, size_t length)
void CsrWifiSmeMibGetReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeMibGetReq *primitive = (CsrWifiSmeMibGetReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->mibAttribute);
- CsrPmemFree(primitive);
+ kfree(primitive->mibAttribute);
+ kfree(primitive);
}
@@ -730,8 +731,8 @@ void* CsrWifiSmeMibSetReqDes(u8 *buffer, size_t length)
void CsrWifiSmeMibSetReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeMibSetReq *primitive = (CsrWifiSmeMibSetReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->mibAttribute);
- CsrPmemFree(primitive);
+ kfree(primitive->mibAttribute);
+ kfree(primitive);
}
@@ -804,8 +805,8 @@ void* CsrWifiSmeMulticastAddressReqDes(u8 *buffer, size_t length)
void CsrWifiSmeMulticastAddressReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeMulticastAddressReq *primitive = (CsrWifiSmeMulticastAddressReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->setAddresses);
- CsrPmemFree(primitive);
+ kfree(primitive->setAddresses);
+ kfree(primitive);
}
@@ -869,8 +870,8 @@ void* CsrWifiSmePacketFilterSetReqDes(u8 *buffer, size_t length)
void CsrWifiSmePacketFilterSetReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmePacketFilterSetReq *primitive = (CsrWifiSmePacketFilterSetReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->filter);
- CsrPmemFree(primitive);
+ kfree(primitive->filter);
+ kfree(primitive);
}
@@ -946,8 +947,8 @@ void* CsrWifiSmePmkidReqDes(u8 *buffer, size_t length)
void CsrWifiSmePmkidReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmePmkidReq *primitive = (CsrWifiSmePmkidReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->setPmkids);
- CsrPmemFree(primitive);
+ kfree(primitive->setPmkids);
+ kfree(primitive);
}
@@ -1224,8 +1225,8 @@ void* CsrWifiSmeScanConfigSetReqDes(u8 *buffer, size_t length)
void CsrWifiSmeScanConfigSetReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeScanConfigSetReq *primitive = (CsrWifiSmeScanConfigSetReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->scanConfig.passiveChannelList);
- CsrPmemFree(primitive);
+ kfree(primitive->scanConfig.passiveChannelList);
+ kfree(primitive);
}
@@ -1341,10 +1342,10 @@ void* CsrWifiSmeScanFullReqDes(u8 *buffer, size_t length)
void CsrWifiSmeScanFullReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeScanFullReq *primitive = (CsrWifiSmeScanFullReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->ssid);
- CsrPmemFree(primitive->channelList);
- CsrPmemFree(primitive->probeIe);
- CsrPmemFree(primitive);
+ kfree(primitive->ssid);
+ kfree(primitive->channelList);
+ kfree(primitive->probeIe);
+ kfree(primitive);
}
@@ -1482,9 +1483,9 @@ void* CsrWifiSmeTspecReqDes(u8 *buffer, size_t length)
void CsrWifiSmeTspecReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeTspecReq *primitive = (CsrWifiSmeTspecReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->tspec);
- CsrPmemFree(primitive->tclas);
- CsrPmemFree(primitive);
+ kfree(primitive->tspec);
+ kfree(primitive->tclas);
+ kfree(primitive);
}
@@ -1572,11 +1573,11 @@ void CsrWifiSmeWifiFlightmodeReqSerFree(void *voidPrimitivePointer)
u16 i1;
for (i1 = 0; i1 < primitive->mibFilesCount; i1++)
{
- CsrPmemFree(primitive->mibFiles[i1].data);
+ kfree(primitive->mibFiles[i1].data);
}
}
- CsrPmemFree(primitive->mibFiles);
- CsrPmemFree(primitive);
+ kfree(primitive->mibFiles);
+ kfree(primitive);
}
@@ -1664,11 +1665,11 @@ void CsrWifiSmeWifiOnReqSerFree(void *voidPrimitivePointer)
u16 i1;
for (i1 = 0; i1 < primitive->mibFilesCount; i1++)
{
- CsrPmemFree(primitive->mibFiles[i1].data);
+ kfree(primitive->mibFiles[i1].data);
}
}
- CsrPmemFree(primitive->mibFiles);
- CsrPmemFree(primitive);
+ kfree(primitive->mibFiles);
+ kfree(primitive);
}
@@ -1738,8 +1739,8 @@ void* CsrWifiSmeCloakedSsidsSetReqDes(u8 *buffer, size_t length)
void CsrWifiSmeCloakedSsidsSetReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeCloakedSsidsSetReq *primitive = (CsrWifiSmeCloakedSsidsSetReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->cloakedSsids.cloakedSsids);
- CsrPmemFree(primitive);
+ kfree(primitive->cloakedSsids.cloakedSsids);
+ kfree(primitive);
}
@@ -1893,8 +1894,8 @@ void* CsrWifiSmeWpsConfigurationReqDes(u8 *buffer, size_t length)
void CsrWifiSmeWpsConfigurationReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeWpsConfigurationReq *primitive = (CsrWifiSmeWpsConfigurationReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->wpsConfig.secondaryDeviceType);
- CsrPmemFree(primitive);
+ kfree(primitive->wpsConfig.secondaryDeviceType);
+ kfree(primitive);
}
@@ -1949,8 +1950,8 @@ void* CsrWifiSmeSetReqDes(u8 *buffer, size_t length)
void CsrWifiSmeSetReqSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeSetReq *primitive = (CsrWifiSmeSetReq *) voidPrimitivePointer;
- CsrPmemFree(primitive->data);
- CsrPmemFree(primitive);
+ kfree(primitive->data);
+ kfree(primitive);
}
@@ -2201,13 +2202,13 @@ void* CsrWifiSmeAssociationCompleteIndDes(u8 *buffer, size_t length)
void CsrWifiSmeAssociationCompleteIndSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeAssociationCompleteInd *primitive = (CsrWifiSmeAssociationCompleteInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->connectionInfo.beaconFrame);
- CsrPmemFree(primitive->connectionInfo.associationReqFrame);
- CsrPmemFree(primitive->connectionInfo.associationRspFrame);
- CsrPmemFree(primitive->connectionInfo.assocScanInfoElements);
- CsrPmemFree(primitive->connectionInfo.assocReqInfoElements);
- CsrPmemFree(primitive->connectionInfo.assocRspInfoElements);
- CsrPmemFree(primitive);
+ kfree(primitive->connectionInfo.beaconFrame);
+ kfree(primitive->connectionInfo.associationReqFrame);
+ kfree(primitive->connectionInfo.associationRspFrame);
+ kfree(primitive->connectionInfo.assocScanInfoElements);
+ kfree(primitive->connectionInfo.assocReqInfoElements);
+ kfree(primitive->connectionInfo.assocRspInfoElements);
+ kfree(primitive);
}
@@ -2325,8 +2326,8 @@ void* CsrWifiSmeBlacklistCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeBlacklistCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeBlacklistCfm *primitive = (CsrWifiSmeBlacklistCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->getAddresses);
- CsrPmemFree(primitive);
+ kfree(primitive->getAddresses);
+ kfree(primitive);
}
@@ -2384,8 +2385,8 @@ void* CsrWifiSmeCalibrationDataGetCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeCalibrationDataGetCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeCalibrationDataGetCfm *primitive = (CsrWifiSmeCalibrationDataGetCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->calibrationData);
- CsrPmemFree(primitive);
+ kfree(primitive->calibrationData);
+ kfree(primitive);
}
@@ -2737,8 +2738,8 @@ void* CsrWifiSmeConnectionConfigGetCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeConnectionConfigGetCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeConnectionConfigGetCfm *primitive = (CsrWifiSmeConnectionConfigGetCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->connectionConfig.mlmeAssociateReqInformationElements);
- CsrPmemFree(primitive);
+ kfree(primitive->connectionConfig.mlmeAssociateReqInformationElements);
+ kfree(primitive);
}
@@ -2941,13 +2942,13 @@ void* CsrWifiSmeConnectionInfoGetCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeConnectionInfoGetCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeConnectionInfoGetCfm *primitive = (CsrWifiSmeConnectionInfoGetCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->connectionInfo.beaconFrame);
- CsrPmemFree(primitive->connectionInfo.associationReqFrame);
- CsrPmemFree(primitive->connectionInfo.associationRspFrame);
- CsrPmemFree(primitive->connectionInfo.assocScanInfoElements);
- CsrPmemFree(primitive->connectionInfo.assocReqInfoElements);
- CsrPmemFree(primitive->connectionInfo.assocRspInfoElements);
- CsrPmemFree(primitive);
+ kfree(primitive->connectionInfo.beaconFrame);
+ kfree(primitive->connectionInfo.associationReqFrame);
+ kfree(primitive->connectionInfo.associationRspFrame);
+ kfree(primitive->connectionInfo.assocScanInfoElements);
+ kfree(primitive->connectionInfo.assocReqInfoElements);
+ kfree(primitive->connectionInfo.assocRspInfoElements);
+ kfree(primitive);
}
@@ -3543,13 +3544,13 @@ void* CsrWifiSmeMediaStatusIndDes(u8 *buffer, size_t length)
void CsrWifiSmeMediaStatusIndSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeMediaStatusInd *primitive = (CsrWifiSmeMediaStatusInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->connectionInfo.beaconFrame);
- CsrPmemFree(primitive->connectionInfo.associationReqFrame);
- CsrPmemFree(primitive->connectionInfo.associationRspFrame);
- CsrPmemFree(primitive->connectionInfo.assocScanInfoElements);
- CsrPmemFree(primitive->connectionInfo.assocReqInfoElements);
- CsrPmemFree(primitive->connectionInfo.assocRspInfoElements);
- CsrPmemFree(primitive);
+ kfree(primitive->connectionInfo.beaconFrame);
+ kfree(primitive->connectionInfo.associationReqFrame);
+ kfree(primitive->connectionInfo.associationRspFrame);
+ kfree(primitive->connectionInfo.assocScanInfoElements);
+ kfree(primitive->connectionInfo.assocReqInfoElements);
+ kfree(primitive->connectionInfo.assocRspInfoElements);
+ kfree(primitive);
}
@@ -3655,8 +3656,8 @@ void* CsrWifiSmeMibGetCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeMibGetCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeMibGetCfm *primitive = (CsrWifiSmeMibGetCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->mibAttribute);
- CsrPmemFree(primitive);
+ kfree(primitive->mibAttribute);
+ kfree(primitive);
}
@@ -3714,8 +3715,8 @@ void* CsrWifiSmeMibGetNextCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeMibGetNextCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeMibGetNextCfm *primitive = (CsrWifiSmeMibGetNextCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->mibAttribute);
- CsrPmemFree(primitive);
+ kfree(primitive->mibAttribute);
+ kfree(primitive);
}
@@ -3836,8 +3837,8 @@ void* CsrWifiSmeMulticastAddressCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeMulticastAddressCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeMulticastAddressCfm *primitive = (CsrWifiSmeMulticastAddressCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->getAddresses);
- CsrPmemFree(primitive);
+ kfree(primitive->getAddresses);
+ kfree(primitive);
}
@@ -3982,8 +3983,8 @@ void* CsrWifiSmePmkidCandidateListIndDes(u8 *buffer, size_t length)
void CsrWifiSmePmkidCandidateListIndSerFree(void *voidPrimitivePointer)
{
CsrWifiSmePmkidCandidateListInd *primitive = (CsrWifiSmePmkidCandidateListInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->pmkidCandidates);
- CsrPmemFree(primitive);
+ kfree(primitive->pmkidCandidates);
+ kfree(primitive);
}
@@ -4062,8 +4063,8 @@ void* CsrWifiSmePmkidCfmDes(u8 *buffer, size_t length)
void CsrWifiSmePmkidCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmePmkidCfm *primitive = (CsrWifiSmePmkidCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->getPmkids);
- CsrPmemFree(primitive);
+ kfree(primitive->getPmkids);
+ kfree(primitive);
}
@@ -4505,8 +4506,8 @@ void* CsrWifiSmeScanConfigGetCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeScanConfigGetCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeScanConfigGetCfm *primitive = (CsrWifiSmeScanConfigGetCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->scanConfig.passiveChannelList);
- CsrPmemFree(primitive);
+ kfree(primitive->scanConfig.passiveChannelList);
+ kfree(primitive);
}
@@ -4780,7 +4781,7 @@ void* CsrWifiSmeScanResultIndDes(u8 *buffer, size_t length)
void CsrWifiSmeScanResultIndSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeScanResultInd *primitive = (CsrWifiSmeScanResultInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->result.informationElements);
+ kfree(primitive->result.informationElements);
switch (primitive->result.p2pDeviceRole)
{
case CSR_WIFI_SME_P2P_ROLE_GO:
@@ -4788,18 +4789,18 @@ void CsrWifiSmeScanResultIndSerFree(void *voidPrimitivePointer)
u16 i4;
for (i4 = 0; i4 < primitive->result.deviceInfo.groupInfo.p2pClientInfoCount; i4++)
{
- CsrPmemFree(primitive->result.deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType);
+ kfree(primitive->result.deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType);
}
}
- CsrPmemFree(primitive->result.deviceInfo.groupInfo.p2PClientInfo);
+ kfree(primitive->result.deviceInfo.groupInfo.p2PClientInfo);
break;
case CSR_WIFI_SME_P2P_ROLE_STANDALONE:
- CsrPmemFree(primitive->result.deviceInfo.standalonedevInfo.secDeviceType);
+ kfree(primitive->result.deviceInfo.standalonedevInfo.secDeviceType);
break;
default:
break;
}
- CsrPmemFree(primitive);
+ kfree(primitive);
}
@@ -5106,7 +5107,7 @@ void CsrWifiSmeScanResultsGetCfmSerFree(void *voidPrimitivePointer)
u16 i1;
for (i1 = 0; i1 < primitive->scanResultsCount; i1++)
{
- CsrPmemFree(primitive->scanResults[i1].informationElements);
+ kfree(primitive->scanResults[i1].informationElements);
switch (primitive->scanResults[i1].p2pDeviceRole)
{
case CSR_WIFI_SME_P2P_ROLE_GO:
@@ -5114,21 +5115,21 @@ void CsrWifiSmeScanResultsGetCfmSerFree(void *voidPrimitivePointer)
u16 i4;
for (i4 = 0; i4 < primitive->scanResults[i1].deviceInfo.groupInfo.p2pClientInfoCount; i4++)
{
- CsrPmemFree(primitive->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType);
+ kfree(primitive->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo[i4].clientDeviceInfo.secDeviceType);
}
}
- CsrPmemFree(primitive->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo);
+ kfree(primitive->scanResults[i1].deviceInfo.groupInfo.p2PClientInfo);
break;
case CSR_WIFI_SME_P2P_ROLE_STANDALONE:
- CsrPmemFree(primitive->scanResults[i1].deviceInfo.standalonedevInfo.secDeviceType);
+ kfree(primitive->scanResults[i1].deviceInfo.standalonedevInfo.secDeviceType);
break;
default:
break;
}
}
}
- CsrPmemFree(primitive->scanResults);
- CsrPmemFree(primitive);
+ kfree(primitive->scanResults);
+ kfree(primitive);
}
@@ -5336,8 +5337,8 @@ void* CsrWifiSmeTspecIndDes(u8 *buffer, size_t length)
void CsrWifiSmeTspecIndSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeTspecInd *primitive = (CsrWifiSmeTspecInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->tspec);
- CsrPmemFree(primitive);
+ kfree(primitive->tspec);
+ kfree(primitive);
}
@@ -5404,8 +5405,8 @@ void* CsrWifiSmeTspecCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeTspecCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeTspecCfm *primitive = (CsrWifiSmeTspecCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->tspec);
- CsrPmemFree(primitive);
+ kfree(primitive->tspec);
+ kfree(primitive);
}
@@ -5473,9 +5474,9 @@ void* CsrWifiSmeVersionsGetCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeVersionsGetCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeVersionsGetCfm *primitive = (CsrWifiSmeVersionsGetCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->versions.routerBuild);
- CsrPmemFree(primitive->versions.smeBuild);
- CsrPmemFree(primitive);
+ kfree(primitive->versions.routerBuild);
+ kfree(primitive->versions.smeBuild);
+ kfree(primitive);
}
@@ -5548,8 +5549,8 @@ void* CsrWifiSmeCloakedSsidsGetCfmDes(u8 *buffer, size_t length)
void CsrWifiSmeCloakedSsidsGetCfmSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeCloakedSsidsGetCfm *primitive = (CsrWifiSmeCloakedSsidsGetCfm *) voidPrimitivePointer;
- CsrPmemFree(primitive->cloakedSsids.cloakedSsids);
- CsrPmemFree(primitive);
+ kfree(primitive->cloakedSsids.cloakedSsids);
+ kfree(primitive);
}
@@ -5707,8 +5708,8 @@ void* CsrWifiSmeErrorIndDes(u8 *buffer, size_t length)
void CsrWifiSmeErrorIndSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeErrorInd *primitive = (CsrWifiSmeErrorInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->errorMessage);
- CsrPmemFree(primitive);
+ kfree(primitive->errorMessage);
+ kfree(primitive);
}
@@ -5749,8 +5750,8 @@ void* CsrWifiSmeInfoIndDes(u8 *buffer, size_t length)
void CsrWifiSmeInfoIndSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeInfoInd *primitive = (CsrWifiSmeInfoInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->infoMessage);
- CsrPmemFree(primitive);
+ kfree(primitive->infoMessage);
+ kfree(primitive);
}
@@ -5805,8 +5806,8 @@ void* CsrWifiSmeCoreDumpIndDes(u8 *buffer, size_t length)
void CsrWifiSmeCoreDumpIndSerFree(void *voidPrimitivePointer)
{
CsrWifiSmeCoreDumpInd *primitive = (CsrWifiSmeCoreDumpInd *) voidPrimitivePointer;
- CsrPmemFree(primitive->data);
- CsrPmemFree(primitive);
+ kfree(primitive->data);
+ kfree(primitive);
}
diff --git a/drivers/staging/csr/drv.c b/drivers/staging/csr/drv.c
index 36d9d539f9f0..6f5b3dd7ce1f 100644
--- a/drivers/staging/csr/drv.c
+++ b/drivers/staging/csr/drv.c
@@ -1476,7 +1476,7 @@ unifi_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
if (pcli->snap_filter.count) {
pcli->snap_filter.count = 0;
- CsrPmemFree(pcli->snap_filter.protocols);
+ kfree(pcli->snap_filter.protocols);
}
if (snap_filter.count == 0) {
@@ -1492,7 +1492,7 @@ unifi_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
(void*)snap_filter.protocols,
snap_filter.count * sizeof(u16)))
{
- CsrPmemFree(pcli->snap_filter.protocols);
+ kfree(pcli->snap_filter.protocols);
r = -EFAULT;
goto out;
}
@@ -1938,7 +1938,7 @@ uf_sme_queue_message(unifi_priv_t *priv, u8 *buffer, int length)
if (logptr == NULL) {
unifi_error(priv, "Failed to allocate %d bytes for an SME message\n",
sizeof(udi_log_t) + length);
- CsrPmemFree(buffer);
+ kfree(buffer);
return -ENOMEM;
}
@@ -1956,7 +1956,7 @@ uf_sme_queue_message(unifi_priv_t *priv, u8 *buffer, int length)
down(&udi_mutex);
if (priv->sme_cli == NULL) {
kfree(logptr);
- CsrPmemFree(buffer);
+ kfree(buffer);
up(&udi_mutex);
unifi_info(priv, "Message for the SME dropped, SME has gone away\n");
return 0;
@@ -1971,7 +1971,7 @@ uf_sme_queue_message(unifi_priv_t *priv, u8 *buffer, int length)
up(&udi_mutex);
/* It is our responsibility to free the buffer allocated in build_packed_*() */
- CsrPmemFree(buffer);
+ kfree(buffer);
func_exit();
diff --git a/drivers/staging/csr/putest.c b/drivers/staging/csr/putest.c
index 96597ac5330d..f2cb11e1b210 100644
--- a/drivers/staging/csr/putest.c
+++ b/drivers/staging/csr/putest.c
@@ -499,7 +499,7 @@ int unifi_putest_dl_fw_buff(unifi_priv_t *priv, unsigned char *arg)
fw_user_ptr = ((unsigned char*)arg) + sizeof(unifi_putest_command_t) + sizeof(unsigned int);
if (copy_from_user(fw_buf, (void*)fw_user_ptr, fw_length)) {
unifi_error(priv, "unifi_putest_dl_fw_buff: Failed to get the buffer\n");
- CsrPmemFree(fw_buf);
+ kfree(fw_buf);
return -EFAULT;
}
@@ -537,7 +537,7 @@ int unifi_putest_dl_fw_buff(unifi_priv_t *priv, unsigned char *arg)
free_fw:
/* Finished with the putest f/w, so restore the station f/w */
priv->fw_sta = temp_fw_sta;
- CsrPmemFree(fw_buf);
+ kfree(fw_buf);
return CsrHipResultToStatus(csrResult);
}
diff --git a/drivers/staging/csr/sme_blocking.c b/drivers/staging/csr/sme_blocking.c
index 3f0d70d56a26..acf0f0fe3b37 100644
--- a/drivers/staging/csr/sme_blocking.c
+++ b/drivers/staging/csr/sme_blocking.c
@@ -415,7 +415,7 @@ int sme_mgt_scan_results_get_async(unifi_priv_t *priv,
scan_result, i+1);
if (r < 0) {
- CsrPmemFree(scan_result_list);
+ kfree(scan_result_list);
priv->sme_reply.reply_scan_results_count = 0;
priv->sme_reply.reply_scan_results = NULL;
return r;
@@ -429,7 +429,7 @@ int sme_mgt_scan_results_get_async(unifi_priv_t *priv,
* and invalidate the reply_scan_results to avoid re-using
* the freed pointers.
*/
- CsrPmemFree(scan_result_list);
+ kfree(scan_result_list);
priv->sme_reply.reply_scan_results_count = 0;
priv->sme_reply.reply_scan_results = NULL;
diff --git a/drivers/staging/csr/sme_userspace.c b/drivers/staging/csr/sme_userspace.c
index 5dc7a2e376ee..abcb446fb8c0 100644
--- a/drivers/staging/csr/sme_userspace.c
+++ b/drivers/staging/csr/sme_userspace.c
@@ -128,7 +128,7 @@ uf_sme_deinit(unifi_priv_t *priv)
/* Free any TCLASs previously allocated */
if (priv->packet_filters.tclas_ies_length) {
priv->packet_filters.tclas_ies_length = 0;
- CsrPmemFree(priv->filter_tclas_ies);
+ kfree(priv->filter_tclas_ies);
priv->filter_tclas_ies = NULL;
}
diff --git a/drivers/staging/csr/ul_int.c b/drivers/staging/csr/ul_int.c
index d71bb05239e7..d8a728b1a1b2 100644
--- a/drivers/staging/csr/ul_int.c
+++ b/drivers/staging/csr/ul_int.c
@@ -117,9 +117,9 @@ ul_register_client(unifi_priv_t *priv, unsigned int configuration,
/* If allocation fails, free allocated memory. */
if (ul_clients[id].reply_bulkdata[ref] == NULL) {
for (; ref > 0; ref --) {
- CsrPmemFree(ul_clients[id].reply_bulkdata[ref - 1]);
+ kfree(ul_clients[id].reply_bulkdata[ref - 1]);
}
- CsrPmemFree(ul_clients[id].reply_signal);
+ kfree(ul_clients[id].reply_signal);
unifi_error(priv, "Failed to allocate bulk data buffers for client.\n");
return NULL;
}
@@ -164,14 +164,14 @@ ul_deregister_client(ul_client_t *ul_client)
unifi_trace(priv, UDBG5, "UDI (0x%x) deregistered.\n", ul_client);
/* Free memory allocated for the reply signal and its bulk data. */
- CsrPmemFree(ul_client->reply_signal);
+ kfree(ul_client->reply_signal);
for (ref = 0; ref < UNIFI_MAX_DATA_REFERENCES; ref ++) {
- CsrPmemFree(ul_client->reply_bulkdata[ref]);
+ kfree(ul_client->reply_bulkdata[ref]);
}
if (ul_client->snap_filter.count) {
ul_client->snap_filter.count = 0;
- CsrPmemFree(ul_client->snap_filter.protocols);
+ kfree(ul_client->snap_filter.protocols);
}
/* Free anything pending on the udi_log list */
diff --git a/drivers/staging/csr/unifi_sme.c b/drivers/staging/csr/unifi_sme.c
index 51d679234a52..0cb7b0145eda 100644
--- a/drivers/staging/csr/unifi_sme.c
+++ b/drivers/staging/csr/unifi_sme.c
@@ -423,7 +423,7 @@ uf_multicast_list_wq(struct work_struct *work)
}
if (priv->smepriv == NULL) {
- CsrPmemFree(multicast_address_list);
+ kfree(multicast_address_list);
return;
}
@@ -433,7 +433,7 @@ uf_multicast_list_wq(struct work_struct *work)
mc_count, multicast_address_list);
/* The SME will take a copy of the addreses*/
- CsrPmemFree(multicast_address_list);
+ kfree(multicast_address_list);
}
@@ -572,7 +572,7 @@ int unifi_cfg_packet_filters(unifi_priv_t *priv, unsigned char *arg)
/* Free any TCLASs previously allocated */
if (priv->packet_filters.tclas_ies_length) {
- CsrPmemFree(priv->filter_tclas_ies);
+ kfree(priv->filter_tclas_ies);
priv->filter_tclas_ies = NULL;
}
@@ -683,7 +683,7 @@ int unifi_cfg_wmm_addts(unifi_priv_t *priv, unsigned char *arg)
rc = copy_from_user(addts_ie, addts_params, addts_ie_length);
if (rc) {
unifi_error(priv, "unifi_cfg_wmm_addts: Failed to get the addts buffer\n");
- CsrPmemFree(addts_ie);
+ kfree(addts_ie);
return -EFAULT;
}
@@ -695,7 +695,7 @@ int unifi_cfg_wmm_addts(unifi_priv_t *priv, unsigned char *arg)
rc = sme_mgt_tspec(priv, CSR_WIFI_SME_LIST_ACTION_ADD, addts_tid,
&tspec, &tclas);
- CsrPmemFree(addts_ie);
+ kfree(addts_ie);
return rc;
}
@@ -1229,7 +1229,7 @@ void uf_send_pkt_to_encrypt(struct work_struct *work)
CsrWifiRouterCtrlWapiUnicastTxEncryptIndSend(priv->CSR_WIFI_SME_IFACEQUEUE, 0, interfaceTag, pktBulkDataLength, pktBulkData);
unifi_trace(priv, UDBG1, "WapiUnicastTxEncryptInd sent to SME\n");
- CsrPmemFree(pktBulkData); /* Would have been copied over by the SME Handler */
+ kfree(pktBulkData); /* Would have been copied over by the SME Handler */
func_exit();
} else {