Archived
14
0
Fork 0
This repository has been archived on 2022-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
linux-2.6/drivers/staging/csr/csr_wifi_router_ctrl_free_downstream_contents.c
Greg Kroah-Hartman 635d2b00e5 Staging: add CSR wifi module
This consists of two modules, the driver, and a "helper" module that is
just a wrapper around common kernel functions.  The wrapper module will
be removed soon, but for now it's needed.

These files were based on the csr-linux-wifi-5.0.3-oss.tar.gz package
provided by CSR and Blue Giga, and is covered under the license
specified in the LICENSE.txt file (basically dual BSD and GPLv2).  The
files were flattened out of the deep directory mess they were originally
in, and a few EXPORT_SYMBOL_GPL() were added in order for everything to
link properly with the helper module setup.

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>
2012-06-19 16:37:01 -07:00

96 lines
2.9 KiB
C

/*****************************************************************************
(c) Cambridge Silicon Radio Limited 2011
All rights reserved and confidential information of CSR
Refer to LICENSE.txt included with this source for details
on the license terms.
*****************************************************************************/
/* Note: this is an auto-generated file. */
#include "csr_pmem.h"
#include "csr_wifi_router_ctrl_prim.h"
#include "csr_wifi_router_ctrl_lib.h"
/*----------------------------------------------------------------------------*
* NAME
* CsrWifiRouterCtrlFreeDownstreamMessageContents
*
* DESCRIPTION
*
*
* PARAMETERS
* eventClass: only the value CSR_WIFI_ROUTER_CTRL_PRIM will be handled
* message: the message to free
*----------------------------------------------------------------------------*/
void CsrWifiRouterCtrlFreeDownstreamMessageContents(CsrUint16 eventClass, void *message)
{
if (eventClass != CSR_WIFI_ROUTER_CTRL_PRIM)
{
return;
}
if (NULL == message)
{
return;
}
switch (*((CsrWifiRouterCtrlPrim *) message))
{
case CSR_WIFI_ROUTER_CTRL_HIP_REQ:
{
CsrWifiRouterCtrlHipReq *p = (CsrWifiRouterCtrlHipReq *)message;
CsrPmemFree(p->mlmeCommand);
p->mlmeCommand = NULL;
CsrPmemFree(p->dataRef1);
p->dataRef1 = NULL;
CsrPmemFree(p->dataRef2);
p->dataRef2 = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_MULTICAST_ADDRESS_RES:
{
CsrWifiRouterCtrlMulticastAddressRes *p = (CsrWifiRouterCtrlMulticastAddressRes *)message;
CsrPmemFree(p->getAddresses);
p->getAddresses = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_TCLAS_ADD_REQ:
{
CsrWifiRouterCtrlTclasAddReq *p = (CsrWifiRouterCtrlTclasAddReq *)message;
CsrPmemFree(p->tclas);
p->tclas = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_TCLAS_DEL_REQ:
{
CsrWifiRouterCtrlTclasDelReq *p = (CsrWifiRouterCtrlTclasDelReq *)message;
CsrPmemFree(p->tclas);
p->tclas = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_WIFI_ON_RES:
{
CsrWifiRouterCtrlWifiOnRes *p = (CsrWifiRouterCtrlWifiOnRes *)message;
CsrPmemFree(p->smeVersions.smeBuild);
p->smeVersions.smeBuild = NULL;
break;
}
case CSR_WIFI_ROUTER_CTRL_WAPI_MULTICAST_REQ:
{
CsrWifiRouterCtrlWapiMulticastReq *p = (CsrWifiRouterCtrlWapiMulticastReq *)message;
CsrPmemFree(p->signal);
p->signal = NULL;
CsrPmemFree(p->data);
p->data = NULL;
break;
}
default:
break;
}
}