Home | History | Annotate | Download | only in inc
      1 /*
      2  * cu_common.h
      3  *
      4  * Copyright 2001-2010 Texas Instruments, Inc. - http://www.ti.com/
      5  *
      6  * Licensed under the Apache License, Version 2.0 (the "License");
      7  * you may not use this file except in compliance with the License.
      8  * You may obtain a copy of the License at
      9  *
     10  *     http://www.apache.org/licenses/LICENSE-2.0
     11  *
     12  * Unless required by applicable law or agreed to in writing, software
     13  * distributed under the License is distributed on an "AS IS" BASIS,
     14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     15  * See the License for the specific language governing permissions and
     16  * limitations under the License.
     17  */
     18 
     19 /****************************************************************************/
     20 /*                                                                          */
     21 /*    MODULE:   CuCommon.h                                                  */
     22 /*    PURPOSE:                                                              */
     23 /*                                                                          */
     24 /****************************************************************************/
     25 #ifndef _CU_COMMON_H_
     26 #define _CU_COMMON_H_
     27 
     28 /* defines */
     29 /***********/
     30 
     31 /* types */
     32 /*********/
     33 typedef struct
     34 {
     35     U32 temp; /* the place of the IE's id and length */
     36     U32 unmatchedPacketsCount;                  /* number of packets didn't match any filter (when the feature was enabled). */
     37     U32 matchedPacketsCount[MAX_DATA_FILTERS];  /* number of packets matching each of the filters */
     38 } TCuCommon_RxDataFilteringStatistics;
     39 
     40 typedef struct
     41 {
     42     U32 temp; /* the place of the IE's id and length */
     43     U32 MissedBeacons;
     44     U8 snr;       /* The current average SNR in db - For Data Packets*/
     45     U8 snrBeacon;     /* The current average SNR in db - For Beacon Packets*/
     46     S8 rssi;      /* The current average RSSI  - For Data Packets*/
     47     S8 rssiBeacon;
     48 } TCuCommon_RoamingStatisticsTable;
     49 
     50 /* functions */
     51 /*************/
     52 THandle CuCommon_Create(THandle *pIpcSta, const PS8 device_name);
     53 VOID CuCommon_Destroy(THandle hCuCommon);
     54 
     55 S32 CuCommon_SetU32(THandle hCuCommon, U32 PrivateIoctlId, U32 Data);
     56 S32 CuCommon_GetU32(THandle hCuCommon, U32 PrivateIoctlId, PU32 pData);
     57 S32 CuCommon_SetU16(THandle hCuCommon, U32 PrivateIoctlId, U16 Data);
     58 S32 CuCommon_SetU8(THandle hCuCommon, U32 PrivateIoctlId, U8 Data);
     59 S32 CuCommon_GetU8(THandle hCuCommon, U32 PrivateIoctlId, PU8 pData);
     60 S32 CuCommon_SetBuffer(THandle hCuCommon, U32 PrivateIoctlId, PVOID pBuffer, U32 len);
     61 S32 CuCommon_GetBuffer(THandle hCuCommon, U32 PrivateIoctlId, PVOID pBuffer, U32 len);
     62 S32 CuCommon_GetSetBuffer(THandle hCuCommon, U32 PrivateIoctlId, PVOID pBuffer, U32 len);
     63 
     64 S32 CuCommon_Start_Scan(THandle hCuCommon, PVOID scanParams, U32 sizeOfScanParams);
     65 S32 CuCommon_Get_BssidList_Size(THandle hCuCommon, PU32 pSizeOfBssiList);
     66 S32 CuCommon_GetRssi(THandle hCuCommon, PS8 pdRssi, PS8 pbRssi);
     67 S32 CuCommon_GetSnr(THandle hCuCommon, PU32 pdSnr, PU32 pbSnr);
     68 S32 CuCommon_GetdesiredPreambleType(THandle hCuCommon, PU32 pDesiredPreambleType);
     69 S32 CuCommon_GetTxStatistics(THandle hCuCommon, TIWLN_TX_STATISTICS* pTxCounters, U32 doReset);
     70 
     71 S32 CuCommon_Radio_Test(THandle hCuCommon,TTestCmd* data);
     72 
     73 S32 CuCommon_AddKey(THandle hCuCommon, OS_802_11_WEP* pKey);
     74 S32 CuCommon_RemoveKey(THandle hCuCommon, U32 KeyIndex);
     75 S32 CuCommon_GetDfsChannels(THandle hCuCommon, PU16 pMinDfsChannel, PU16 pMaxDfsChannel);
     76 S32 CuCommon_SetDfsChannels(THandle hCuCommon, U16 MinDfsChannel, U16 MaxDfsChannel);
     77 
     78 S32 CuCommon_PrintDriverDebug(THandle hCuCommon, PVOID pParams, U32 param_size);
     79 S32 CuCommon_PrintDriverDebugBuffer(THandle hCuCommon, U32 func_id, U32 opt_param);
     80 
     81 S32 CuCommon_GetRxDataFiltersStatistics(THandle hCuCommon, PU32 pUnmatchedPacketsCount, PU32 pMatchedPacketsCount);
     82 S32 CuCommon_GetPowerConsumptionStat(THandle hCuCommon, ACXPowerConsumptionTimeStat_t *pPowerstat);
     83 
     84 
     85 #endif  /* _CU_COMMON_H_ */
     86 
     87