1 /******************************************************************************
3 * Copyright(c) 2009-2014 Realtek Corporation.
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.
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
14 * The full GNU General Public License is included in this distribution in the
15 * file called LICENSE.
17 * Contact Information:
18 * wlanfae <wlanfae@realtek.com>
19 * Realtek Corporation, No. 2, Innovation Road II, Hsinchu Science Park,
20 * Hsinchu 300, Taiwan.
22 * Larry Finger <Larry.Finger@lwfinger.net>
24 *****************************************************************************/
27 #include "dm_common.h"
28 #include "../rtl8723ae/dm.h"
29 #include <linux/module.h>
31 /* These routines are common to RTL8723AE and RTL8723bE */
33 void rtl8723_dm_init_dynamic_txpower(struct ieee80211_hw
*hw
)
35 struct rtl_priv
*rtlpriv
= rtl_priv(hw
);
37 rtlpriv
->dm
.dynamic_txpower_enable
= false;
39 rtlpriv
->dm
.last_dtp_lvl
= TXHIGHPWRLEVEL_NORMAL
;
40 rtlpriv
->dm
.dynamic_txhighpower_lvl
= TXHIGHPWRLEVEL_NORMAL
;
42 EXPORT_SYMBOL_GPL(rtl8723_dm_init_dynamic_txpower
);
44 void rtl8723_dm_init_edca_turbo(struct ieee80211_hw
*hw
)
46 struct rtl_priv
*rtlpriv
= rtl_priv(hw
);
47 rtlpriv
->dm
.current_turbo_edca
= false;
48 rtlpriv
->dm
.is_any_nonbepkts
= false;
49 rtlpriv
->dm
.is_cur_rdlstate
= false;
51 EXPORT_SYMBOL_GPL(rtl8723_dm_init_edca_turbo
);
53 void rtl8723_dm_init_dynamic_bb_powersaving(struct ieee80211_hw
*hw
)
55 struct rtl_priv
*rtlpriv
= rtl_priv(hw
);
56 struct ps_t
*dm_pstable
= &rtlpriv
->dm_pstable
;
58 dm_pstable
->pre_ccastate
= CCA_MAX
;
59 dm_pstable
->cur_ccasate
= CCA_MAX
;
60 dm_pstable
->pre_rfstate
= RF_MAX
;
61 dm_pstable
->cur_rfstate
= RF_MAX
;
62 dm_pstable
->rssi_val_min
= 0;
63 dm_pstable
->initialize
= 0;
65 EXPORT_SYMBOL_GPL(rtl8723_dm_init_dynamic_bb_powersaving
);