linux/drivers/net/wireless/realtek/rtlwifi/btcoexist/halbtc8821a2ant.c

// SPDX-License-Identifier: GPL-2.0
/* Copyright(c) 2012  Realtek Corporation.*/

/************************************************************
 * Description:
 *
 * This file is for RTL8821A Co-exist mechanism
 *
 * History
 * 2012/08/22 Cosa first check in.
 * 2012/11/14 Cosa Revise for 8821A 2Ant out sourcing.
 *
 ************************************************************/

/************************************************************
 * include files
 ************************************************************/
#include "halbt_precomp.h"
/************************************************************
 * Global variables, these are static variables
 ************************************************************/
static struct coex_dm_8821a_2ant glcoex_dm_8821a_2ant;
static struct coex_dm_8821a_2ant *coex_dm =;
static struct coex_sta_8821a_2ant glcoex_sta_8821a_2ant;
static struct coex_sta_8821a_2ant *coex_sta =;

static const char *const glbt_info_src_8821a_2ant[] =;

static u32 glcoex_ver_date_8821a_2ant =;
static u32 glcoex_ver_8821a_2ant =;

/************************************************************
 * local function proto type if needed
 *
 * local function start with btc8821a2ant_
 ************************************************************/
static u8 btc8821a2ant_bt_rssi_state(struct btc_coexist *btcoexist,
				     u8 level_num, u8 rssi_thresh,
				     u8 rssi_thresh1)
{}

static u8 btc8821a2ant_wifi_rssi_state(struct btc_coexist *btcoexist,
				       u8 index, u8 level_num,
				       u8 rssi_thresh, u8 rssi_thresh1)
{}

static
void btc8821a2ant_limited_rx(struct btc_coexist *btcoexist, bool force_exec,
			     bool rej_ap_agg_pkt, bool bt_ctrl_agg_buf_size,
			     u8 agg_buf_size)
{}

static void btc8821a2ant_monitor_bt_ctr(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_monitor_wifi_ctr(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_query_bt_info(struct btc_coexist *btcoexist)
{}

static bool btc8821a2ant_is_wifi_status_changed(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_update_bt_link_info(struct btc_coexist *btcoexist)
{}

static u8 btc8821a2ant_action_algorithm(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_set_fw_dac_swing_lvl(struct btc_coexist *btcoexist,
					      u8 dac_swing_lvl)
{}

static void btc8821a2ant_set_fw_dec_bt_pwr(struct btc_coexist *btcoexist,
					   u8 dec_bt_pwr_lvl)
{}

static void btc8821a2ant_dec_bt_pwr(struct btc_coexist *btcoexist,
				    bool force_exec, u8 dec_bt_pwr_lvl)
{}

static void btc8821a2ant_fw_dac_swing_lvl(struct btc_coexist *btcoexist,
					  bool force_exec, u8 fw_dac_swing_lvl)
{}

static void btc8821a2ant_set_sw_penalty_tx_rate_adaptive(
		struct btc_coexist *btcoexist, bool low_penalty_ra)
{}

static void btc8821a2ant_low_penalty_ra(struct btc_coexist *btcoexist,
					bool force_exec, bool low_penalty_ra)
{}

static void btc8821a2ant_set_dac_swing_reg(struct btc_coexist *btcoexist,
					   u32 level)
{}

static void btc8821a2ant_set_sw_full_dac_swing(struct btc_coexist *btcoexist,
					       bool sw_dac_swing_on,
					       u32 sw_dac_swing_lvl)
{}

static void btc8821a2ant_dac_swing(struct btc_coexist *btcoexist,
				   bool force_exec, bool dac_swing_on,
				   u32 dac_swing_lvl)
{}

static void btc8821a2ant_set_coex_table(struct btc_coexist *btcoexist,
					u32 val0x6c0, u32 val0x6c4,
					u32 val0x6c8, u8 val0x6cc)
{}

static void btc8821a2ant_coex_table(struct btc_coexist *btcoexist,
				    bool force_exec, u32 val0x6c0,
				    u32 val0x6c4, u32 val0x6c8, u8 val0x6cc)
{}

static void btc8821a2ant_coex_table_with_type(struct btc_coexist *btcoexist,
					      bool force_exec, u8 type)
{}

static void btc8821a2ant_set_fw_ignore_wlan_act(struct btc_coexist *btcoex,
						bool enable)
{}

static void btc8821a2ant_set_lps_rpwm(struct btc_coexist *btcoexist, u8 lps_val,
				      u8 rpwm_val)
{}

static void btc8821a2ant_lps_rpwm(struct btc_coexist *btcoexist,
				  bool force_exec, u8 lps_val, u8 rpwm_val)
{}

static void btc8821a2ant_ignore_wlan_act(struct btc_coexist *btcoexist,
					 bool force_exec, bool enable)
{}

static void btc8821a2ant_set_fw_ps_tdma(struct btc_coexist *btcoexist,
					u8 byte1, u8 byte2, u8 byte3,
					u8 byte4, u8 byte5)
{}

static void btc8821a2ant_sw_mechanism1(struct btc_coexist *btcoexist,
				       bool shrink_rx_lpf, bool low_penalty_ra,
				       bool limited_dig, bool bt_lna_constrain)
{}

static void btc8821a2ant_sw_mechanism2(struct btc_coexist *btcoexist,
				       bool agc_table_shift, bool adc_back_off,
				       bool sw_dac_swing, u32 dac_swing_lvl)
{}

static void btc8821a2ant_set_ant_path(struct btc_coexist *btcoexist,
				      u8 ant_pos_type, bool init_hw_cfg,
				      bool wifi_off)
{}

static void btc8821a2ant_ps_tdma(struct btc_coexist *btcoexist,
				 bool force_exec, bool turn_on, u8 type)
{}

static void
btc8821a2ant_ps_tdma_check_for_power_save_state(struct btc_coexist *btcoexist,
						bool new_ps_state)
{}

static void btc8821a2ant_power_save_state(struct btc_coexist *btcoexist,
					  u8 ps_type, u8 lps_val, u8 rpwm_val)
{}

static void btc8821a2ant_coex_all_off(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_coex_under_5g(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_init_coex_dm(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_action_bt_inquiry(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_action_wifi_link_process(struct btc_coexist *btcoexist)
{}

static bool btc8821a2ant_action_wifi_idle_process(struct btc_coexist *btcoexist)
{}

static bool btc8821a2ant_is_common_action(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_tdma_duration_adjust(struct btc_coexist *btcoexist,
					      bool sco_hid, bool tx_pause,
					      u8 max_interval)
{}

/* SCO only or SCO+PAN(HS)*/
static void btc8821a2ant_action_sco(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_action_hid(struct btc_coexist *btcoexist)
{}

/* A2DP only / PAN(EDR) only/ A2DP+PAN(HS) */
static void btc8821a2ant_action_a2dp(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_action_a2dp_pan_hs(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_action_pan_edr(struct btc_coexist *btcoexist)
{}

/* PAN(HS) only */
static void btc8821a2ant_action_pan_hs(struct btc_coexist *btcoexist)
{}

/* PAN(EDR)+A2DP */
static void btc8821a2ant_action_pan_edr_a2dp(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_action_pan_edr_hid(struct btc_coexist *btcoexist)
{}

/* HID+A2DP+PAN(EDR) */
static void btc8821a2ant_act_hid_a2dp_pan_edr(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_action_hid_a2dp(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_action_wifi_multi_port(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_run_coexist_mechanism(struct btc_coexist *btcoexist)
{}

static void btc8821a2ant_wifi_off_hw_cfg(struct btc_coexist *btcoexist)
{}

/**************************************************************
 * extern function start with ex_btc8821a2ant_
 **************************************************************/
void ex_btc8821a2ant_init_hwconfig(struct btc_coexist *btcoexist)
{}

void ex_btc8821a2ant_pre_load_firmware(struct btc_coexist *btcoexist)
{}

void ex_btc8821a2ant_init_coex_dm(struct btc_coexist *btcoexist)
{}

void ex_btc8821a2ant_display_coex_info(struct btc_coexist *btcoexist,
				       struct seq_file *m)
{}

void ex_btc8821a2ant_ips_notify(struct btc_coexist *btcoexist, u8 type)
{}

void ex_btc8821a2ant_lps_notify(struct btc_coexist *btcoexist, u8 type)
{}

void ex_btc8821a2ant_scan_notify(struct btc_coexist *btcoexist, u8 type)
{}

void ex_btc8821a2ant_connect_notify(struct btc_coexist *btcoexist, u8 type)
{}

void ex_btc8821a2ant_media_status_notify(struct btc_coexist *btcoexist,
					 u8 type)
{}

void ex_btc8821a2ant_special_packet_notify(struct btc_coexist *btcoexist,
					   u8 type)
{}

void ex_btc8821a2ant_bt_info_notify(struct btc_coexist *btcoexist,
				    u8 *tmp_buf, u8 length)
{}

void ex_btc8821a2ant_halt_notify(struct btc_coexist *btcoexist)
{}

void ex_btc8821a2ant_pnp_notify(struct btc_coexist *btcoexist, u8 pnp_state)
{}

void ex_btc8821a2ant_periodical(struct btc_coexist *btcoexist)
{}