Home | History | Annotate | Download | only in Ctrl
      1 /*
      2  * CmdBldDb.h
      3  *
      4  * Copyright(c) 1998 - 2010 Texas Instruments. All rights reserved.
      5  * All rights reserved.
      6  *
      7  * Redistribution and use in source and binary forms, with or without
      8  * modification, are permitted provided that the following conditions
      9  * are met:
     10  *
     11  *  * Redistributions of source code must retain the above copyright
     12  *    notice, this list of conditions and the following disclaimer.
     13  *  * Redistributions in binary form must reproduce the above copyright
     14  *    notice, this list of conditions and the following disclaimer in
     15  *    the documentation and/or other materials provided with the
     16  *    distribution.
     17  *  * Neither the name Texas Instruments nor the names of its
     18  *    contributors may be used to endorse or promote products derived
     19  *    from this software without specific prior written permission.
     20  *
     21  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
     22  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
     23  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
     24  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
     25  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
     26  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
     27  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
     28  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
     29  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
     30  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
     31  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     32  */
     33 
     34 
     35 /** \file  CmdBldDb.h
     36  *  \brief Command builder database
     37  *
     38  *  \see   CmdBld.h
     39  */
     40 
     41 #ifndef CMDBLDDB_H
     42 #define CMDBLDDB_H
     43 
     44 
     45 #include "TWDriverInternal.h"
     46 #include "public_infoele.h"
     47 
     48 
     49 /*
     50  * Dot11 params
     51  * ------------
     52  */
     53 typedef struct
     54 {
     55     TI_UINT16                  RtsThreshold;
     56     TI_UINT8                   CtsToSelf;
     57     TRxTimeOut                 rxTimeOut;
     58     TI_UINT16                  FragmentThreshold;
     59     TI_UINT8                   ListenInterval;
     60     TI_UINT16                  Capabilities;
     61     TI_UINT32                  MaxTxMsduLifetime;
     62     TI_UINT32                  MaxRxMsduLifetime;
     63     TI_UINT8                   calibrationChannel2_4;
     64     TI_UINT8                   calibrationChannel5_0;
     65     TI_UINT16                  Aid;
     66     TI_UINT8                   CurrAntenna;
     67     TI_UINT8                   TxAntenna;
     68     TI_UINT8                   RxAntenna;
     69     TI_UINT8                   Hw_TxAntenna;
     70     TI_UINT8                   Hw_RxAntenna;
     71     TI_UINT16                  CwMin;
     72     TI_UINT8                   RateFallback;
     73     TI_UINT32                  RxConfigOption;
     74     TI_UINT32                  RxFilterOption;
     75     TI_BOOL                    WiFiWmmPS;
     76 
     77     /* Data interrupts pacing */
     78     TI_UINT16                  TxCompletePacingThreshold;
     79     TI_UINT16                  TxCompletePacingTimeout;
     80     TI_UINT16                  RxIntrPacingThreshold;
     81     TI_UINT16                  RxIntrPacingTimeout;
     82 
     83     /* ARP IP Addr table */
     84     TI_UINT32                  arp_IP_ver;
     85     EArpFilterType             arpFilterType;
     86     TIpAddr                    arp_IP_addr;
     87 
     88     /* Mac addresses filter */
     89     TI_UINT8                   isMacAddrFilteringnabled;
     90     TI_UINT8                   numGroupAddrs;
     91     TMacAddr                   aGroupAddr[MAX_MULTICAST_GROUP_ADDRS];
     92 
     93     TI_UINT32                  FeatureOptions;
     94     TI_UINT32                  FeatureDataFlowOptions;
     95     TI_UINT8                   SlotTime;
     96     TI_UINT8                   preamble;
     97     TI_UINT8                   RadioBand;
     98     TI_UINT8                   MacClock;
     99     TI_UINT8                   ArmClock;
    100     TI_UINT8                   CurrPowerSaveState;
    101     ESoftGeminiEnableModes     SoftGeminiEnable;
    102     TSoftGeminiParams          SoftGeminiParams;
    103     TFmCoexParams              tFmCoexParams;
    104     TI_UINT8                   maxSitesFragCollect;
    105     TI_UINT8                   hwAccessMethod;
    106     TI_UINT32                  nullTemplateSize;
    107     TI_UINT32                  disconnTemplateSize;
    108     TI_UINT32                  beaconTemplateSize;
    109     TI_UINT32                  probeRequestTemplateSize;
    110     TI_UINT32                  probeResponseTemplateSize;
    111     TI_UINT32                  PsPollTemplateSize;
    112     TI_UINT32                  qosNullDataTemplateSize;
    113     TI_UINT32                  ArpRspTemplateSize;
    114     TI_BOOL                    ch14TelecCca;
    115     TI_UINT8                   PacketDetectionThreshold;
    116     TI_UINT8                   FcsErrThrsh;
    117     TI_UINT8                   UseDeviceErrorInterrupt;
    118     TI_BOOL                    RetryPreemption;
    119     /* This flag indicate if to discards all broadcast frames */
    120     TI_BOOL                    RxDisableBroadcast;
    121     /* Indicate if the station is joined */
    122     TI_BOOL                    bJoin;
    123     /* Indicate if the station is connected */
    124     TI_BOOL                    bStaConnected;
    125     TI_UINT8                   AntDiversity;
    126     /* Parameters for roaming triggers configuration */
    127     TRroamingTriggerParams     roamTriggers;
    128     /* Power control param */
    129     EPowerPolicy               minPowerLevel;
    130     TBcnBrcOptions             BcnBrcOptions;
    131     TBeaconFilterIeTable       beaconFilterIETable;
    132     TBeaconFilterInitParams    beaconFilterParams;
    133 
    134     /*Beacon Early Termination (Bet)*/
    135     TI_UINT8                   BetEnable;
    136     TI_UINT8                   MaximumConsecutiveET;
    137     TI_UINT8                   ConsecutivePsPollDeliveryFailureThreshold;
    138 
    139     /* RSSI/SNR triggers */
    140     RssiSnrTriggerCfg_t        tRssiSnrTrigger[NUM_OF_RSSI_SNR_TRIGGERS];
    141     RssiSnrAverageWeights_t    tRssiSnrWeights;
    142 
    143     TI_UINT32                  uSlicedScanTimeOut;
    144 
    145     /* HT capabilities */
    146     TTwdHtCapabilities         tTwdHtCapabilities;
    147 
    148     /* PM Config params */
    149     TI_UINT32                  uHostClkSettlingTime;
    150     TI_UINT8                   uHostFastWakeupSupport;
    151 
    152     TI_UINT8                   TxPowerDbm;
    153 
    154     /* CoexActivity Table */
    155     THalCoexActivityTable      tWlanParamsCoexActivityTable;
    156 
    157     /* DCO Itrim params */
    158     TI_BOOL                    dcoItrimEnabled;
    159     TI_UINT32                  dcoItrimModerationTimeoutUsec;
    160 
    161 } TWlanParams;
    162 
    163 
    164 /*
    165  * BssInfo params
    166  * --------------
    167  */
    168 typedef struct
    169 {
    170     TI_UINT8                   ReqBssType;
    171     TI_UINT8                   BssType;
    172     TI_UINT16                  BeaconInterval;
    173     TI_UINT8                   DtimInterval;
    174     TI_UINT8                   RadioChannel;
    175     TI_UINT8                   BssId[MAC_ADDR_LEN];
    176     TSsid                      tSsid;
    177     /* Policy for recovery */
    178     TTxRatePolicy              TxRateClassParams;
    179     TI_UINT32                  BasicRateSet;
    180     /* The ctrl field in the Join-Command (see StartJoinRequest_t) */
    181     TI_UINT8                   Ctrl;
    182     /* ATIM window of IBSS*/
    183     /* Note that when ATIM window is zero the*/
    184     /* initiated IBSS does not support powersave*/
    185     TI_UINT16                  ATimWindow;
    186     /* Specifies the PLCP preamble type used*/
    187     /* 0 for long preamble*/
    188     /* 1 for short preamble*/
    189     TI_UINT8                   DefaultPreamble;
    190 
    191     /*
    192      * HT setting
    193      */
    194     /* capabilities */
    195     TI_BOOL   bHtCap;
    196     TI_UINT32 uHtCapabilites;
    197     TMacAddr  tMacAddress;
    198     TI_UINT8  uAmpduMaxLeng;
    199     TI_UINT8  uAmpduMinSpac;
    200     /* Information */
    201     TI_BOOL   bHtInf;
    202     TI_UINT8  uRifsMode;
    203     TI_UINT8  uHtProtection;
    204     TI_UINT8  uGfProtection;
    205     TI_UINT8  uHtTxBurstLimit;
    206     TI_UINT8  uDualCtsProtection;
    207     /* BA session */
    208     TI_BOOL                               bBaInitiator[MAX_NUM_OF_802_1d_TAGS];
    209     TAxcBaSessionInitiatorResponderPolicy tBaSessionInitiatorPolicy[MAX_NUM_OF_802_1d_TAGS];
    210     TI_BOOL                               bBaResponder[MAX_NUM_OF_802_1d_TAGS];
    211     TAxcBaSessionInitiatorResponderPolicy tBaSessionResponderPolicy[MAX_NUM_OF_802_1d_TAGS];
    212 
    213 } TBssInfoParams;
    214 
    215 
    216 /*
    217  * General counters
    218  * ----------------
    219  */
    220 typedef struct
    221 {
    222     TI_UINT32                  FcsErrCnt;
    223 
    224 } TGenCounters;
    225 
    226 
    227 /*
    228  * queuesParam_T - Queue params for Quality Of Service
    229  * ------------------------------------------
    230  */
    231 typedef struct
    232 {
    233     TQueueTrafficParams        queues[MAX_NUM_OF_AC];
    234     TI_BOOL                    isQueueConfigured[MAX_NUM_OF_AC];
    235 
    236 } TQueuesParams;
    237 
    238 
    239 typedef struct
    240 {
    241     TAcQosParams               ac[MAX_NUM_OF_AC];
    242     TI_BOOL                    isAcConfigured[MAX_NUM_OF_AC];
    243 	TI_BOOL					   isBurstModeEnabled;
    244 } TAcConfParams;
    245 
    246 
    247 typedef struct
    248 {
    249     TPsRxStreaming             tid[MAX_NUM_OF_802_1d_TAGS];
    250 
    251 } TPsRxStreamingParams;
    252 
    253 
    254 /*
    255  * Templates params
    256  * ----------------
    257  */
    258 typedef struct
    259 {
    260     TTemplateParams            Beacon;
    261     TTemplateParams            ProbeReq24;
    262     TTemplateParams            ProbeReq50;
    263     TTemplateParams            ProbeResp;
    264     TTemplateParams            NullData;
    265     TTemplateParams            PsPoll;
    266     TTemplateParams            QosNullData;
    267     TTemplateParams            KeepAlive[ KLV_MAX_TMPL_NUM ];
    268     TTemplateParams            Disconn;
    269     TTemplateParams            ArpRsp;
    270 
    271 } TTemplateListParams;
    272 
    273 typedef struct
    274 {
    275     TI_UINT8                   enaDisFlag;
    276     TKeepAliveParams           keepAliveParams[ KLV_MAX_TMPL_NUM ];
    277 } TKeepAliveList;
    278 
    279 /* Security keys structure for reconfigure phase */
    280 typedef struct
    281 {
    282     TI_BOOL                    bReconfHwEncEnable;
    283     TI_BOOL                    bHwEncDecrEnableValid;
    284     TI_UINT8                   uReconfDefaultKeyId;
    285     TI_BOOL                    bDefaultKeyIdValid;
    286     TSecurityKeys*             pReconfKeys;
    287 
    288 } TSecurReconf;
    289 
    290 
    291 /* Rx Data Filters */
    292 typedef struct
    293 {
    294     TI_UINT8                   uIndex;
    295     TI_UINT8                   uCommand;
    296     filter_e                   eAction;
    297     TI_UINT8                   uNumFieldPatterns;
    298     TI_UINT8                   uLenFieldPatterns;
    299     TI_UINT8                   aFieldPattern[MAX_DATA_FILTER_SIZE];
    300 
    301 } TRxDataFilter;
    302 
    303 typedef struct
    304 {
    305     TI_BOOL                    bEnabled;
    306     filter_e                   eDefaultAction;
    307     TRxDataFilter              aRxDataFilter[MAX_DATA_FILTERS];
    308 
    309 } TRxDataFiltersTable;
    310 
    311 typedef struct
    312 {
    313 	RateMangeParams_t rateMngParams;
    314 
    315 } TRateMngParams;
    316 
    317 
    318 
    319 /*
    320  * ----------------------------------------------------------------
    321  *                  MAIN PARAMETERS STRUCTURE
    322  * ----------------------------------------------------------------
    323  */
    324 typedef struct
    325 {
    326     TDmaParams                 dma;                 /* Rx/Tx queue parameters   */
    327     TQueuesParams              queues;              /* Queues params for QOS    */
    328     TAcConfParams              ac;                  /* AC params for QoS        */
    329     TPsRxStreamingParams       psStream;            /* PS-Rx-Streaming params   */
    330     TWlanParams                wlan;                /* Wlan parameters          */
    331     TBssInfoParams             bss;                 /* Bss information          */
    332     TFwInfo                    hw;                  /* HW eeprom & versions info*/
    333     TGenCounters               counters;            /* General counters         */
    334     TTemplateListParams        templateList;        /* Templates for recovery   */
    335     TKeepAliveList             klvList;             /* Keep-Alive paramters     */
    336     TSecurReconf               keys;                /* Security keys            */
    337     TRxDataFiltersTable        rxDataFilters;       /* Rx data filters          */
    338     IniFileGeneralParam        tPlatformGenParams;  /* platfrom gen params from public_radio.h  */
    339     IniFileRadioParam          tRadioIniParams;     /* Radio ini params from public_radio.h     */
    340 	IniFileExtendedRadioParam  tExtRadioIniParams;  /* Extended Radio ini params from public_radio.h     */
    341 	TRateMngParams		       tRateMngParams;      /* rate management params */
    342 } TCmdBldDb;
    343 
    344 #endif
    345 
    346 
    347 
    348