• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /******************************************************************************
2  *
3  * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
4  *
5  * This program is free software; you can redistribute it and/or modify it
6  * under the terms of version 2 of the GNU General Public License as
7  * published by the Free Software Foundation.
8  *
9  * This program is distributed in the hope that it will be useful, but WITHOUT
10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12  * more details.
13  *
14  * You should have received a copy of the GNU General Public License along with
15  * this program; if not, write to the Free Software Foundation, Inc.,
16  * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
17  *
18  *
19  ******************************************************************************/
20 #ifndef __RTL8188E_DM_H__
21 #define __RTL8188E_DM_H__
22 enum{
23 	UP_LINK,
24 	DOWN_LINK,
25 };
26 /*  duplicate code,will move to ODM ######### */
27 #define IQK_MAC_REG_NUM		4
28 #define IQK_ADDA_REG_NUM		16
29 #define IQK_BB_REG_NUM			9
30 #define HP_THERMAL_NUM		8
31 /*  duplicate code,will move to ODM ######### */
32 struct	dm_priv {
33 	u8	DM_Type;
34 	u8	DMFlag;
35 	u8	InitDMFlag;
36 	u32	InitODMFlag;
37 
38 	/*  Upper and Lower Signal threshold for Rate Adaptive*/
39 	int	UndecoratedSmoothedPWDB;
40 	int	UndecoratedSmoothedCCK;
41 	int	EntryMinUndecoratedSmoothedPWDB;
42 	int	EntryMaxUndecoratedSmoothedPWDB;
43 	int	MinUndecoratedPWDBForDM;
44 	int	LastMinUndecoratedPWDBForDM;
45 
46 	/* for High Power */
47 	u8 bDynamicTxPowerEnable;
48 	u8 LastDTPLvl;
49 	u8 DynamicTxHighPowerLvl;/* Tx Power Control for Near/Far Range */
50 	u8	PowerIndex_backup[6];
51 };
52 
53 void rtl8188e_init_dm_priv(struct adapter *adapt);
54 void rtl8188e_InitHalDm(struct adapter *adapt);
55 void rtl8188e_HalDmWatchDog(struct adapter *adapt);
56 
57 void AntDivCompare8188E(struct adapter *adapt, struct wlan_bssid_ex *dst,
58 			struct wlan_bssid_ex *src);
59 u8 AntDivBeforeLink8188E(struct adapter *adapt);
60 
61 #endif
62