Path: blob/master/ALFA-W1F1/RTL8814AU/include/Hal8192EPhyCfg.h
1307 views
/******************************************************************************1*2* Copyright(c) 2012 - 2017 Realtek Corporation.3*4* This program is free software; you can redistribute it and/or modify it5* under the terms of version 2 of the GNU General Public License as6* published by the Free Software Foundation.7*8* This program is distributed in the hope that it will be useful, but WITHOUT9* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or10* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for11* more details.12*13*****************************************************************************/14#ifndef __INC_HAL8192EPHYCFG_H__15#define __INC_HAL8192EPHYCFG_H__161718/*--------------------------Define Parameters-------------------------------*/19#define LOOP_LIMIT 520#define MAX_STALL_TIME 50 /* us */21#define AntennaDiversityValue 0x80 /* (Adapter->bSoftwareAntennaDiversity ? 0x00 : 0x80) */22#define MAX_TXPWR_IDX_NMODE_92S 6323#define Reset_Cnt_Limit 32425#ifdef CONFIG_PCI_HCI26#define MAX_AGGR_NUM 0x0B27#else28#define MAX_AGGR_NUM 0x0729#endif /* CONFIG_PCI_HCI */303132/*--------------------------Define Parameters-------------------------------*/3334/*------------------------------Define structure----------------------------*/3536/* BB/RF related */3738/*------------------------------Define structure----------------------------*/394041/*------------------------Export global variable----------------------------*/42/*------------------------Export global variable----------------------------*/434445/*------------------------Export Marco Definition---------------------------*/46/*------------------------Export Marco Definition---------------------------*/474849/*--------------------------Exported Function prototype---------------------*/50/*51* BB and RF register read/write52* */53u32 PHY_QueryBBReg8192E(PADAPTER Adapter,54u32 RegAddr,55u32 BitMask);56void PHY_SetBBReg8192E(PADAPTER Adapter,57u32 RegAddr,58u32 BitMask,59u32 Data);60u32 PHY_QueryRFReg8192E(PADAPTER Adapter,61enum rf_path eRFPath,62u32 RegAddr,63u32 BitMask);64void PHY_SetRFReg8192E(PADAPTER Adapter,65enum rf_path eRFPath,66u32 RegAddr,67u32 BitMask,68u32 Data);6970/*71* Initialization related function72*73* MAC/BB/RF HAL config */74int PHY_MACConfig8192E(PADAPTER Adapter);75int PHY_BBConfig8192E(PADAPTER Adapter);76int PHY_RFConfig8192E(PADAPTER Adapter);7778/* RF config */798081/*82* BB TX Power R/W83* */84void PHY_SetTxPowerLevel8192E(PADAPTER Adapter, u8 channel);8586void87PHY_SetTxPowerIndex_8192E(88PADAPTER Adapter,89u32 PowerIndex,90enum rf_path RFPath,91u8 Rate92);9394u895PHY_GetTxPowerIndex_8192E(96PADAPTER pAdapter,97enum rf_path RFPath,98u8 Rate,99u8 BandWidth,100u8 Channel,101struct txpwr_idx_comp *tic102);103104/*105* channel switch related funciton106* */107void108PHY_SetSwChnlBWMode8192E(109PADAPTER Adapter,110u8 channel,111enum channel_width Bandwidth,112u8 Offset40,113u8 Offset80114);115116void117PHY_SetRFEReg_8192E(118PADAPTER Adapter119);120121void122phy_SpurCalibration_8192E(123PADAPTER Adapter,124enum spur_cal_method method125);126void PHY_SpurCalibration_8192E( PADAPTER Adapter);127128#ifdef CONFIG_SPUR_CAL_NBI129void130phy_SpurCalibration_8192E_NBI(131PADAPTER Adapter132);133#endif134/*135* BB/MAC/RF other monitor API136* */137138void139phy_set_rf_path_switch_8192e(140struct dm_struct *phydm,141bool bMain142);143144/*--------------------------Exported Function prototype---------------------*/145#endif /* __INC_HAL8192CPHYCFG_H */146147148