Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 65b52bde authored by Johannes Berg's avatar Johannes Berg Committed by Reinette Chatre
Browse files

iwlwifi: make BT coex config a virtual method



Some future hardware will require a different command to
be sent for bluetooth coexist, so make this a virtual
method that can be changed on a per-device basis.

Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
Signed-off-by: default avatarReinette Chatre <reinette.chatre@intel.com>
parent f4388adc
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -2687,6 +2687,7 @@ IWL3945_UCODE_GET(boot_size);
static struct iwl_hcmd_ops iwl3945_hcmd = {
	.rxon_assoc = iwl3945_send_rxon_assoc,
	.commit_rxon = iwl3945_commit_rxon,
	.send_bt_config = iwl_send_bt_config,
};

static struct iwl_ucode_ops iwl3945_ucode = {
+1 −0
Original line number Diff line number Diff line
@@ -2144,6 +2144,7 @@ static struct iwl_hcmd_ops iwl4965_hcmd = {
	.rxon_assoc = iwl4965_send_rxon_assoc,
	.commit_rxon = iwl_commit_rxon,
	.set_rxon_chain = iwl_set_rxon_chain,
	.send_bt_config = iwl_send_bt_config,
};

static struct iwl_ucode_ops iwl4965_ucode = {
+1 −0
Original line number Diff line number Diff line
@@ -262,6 +262,7 @@ struct iwl_hcmd_ops iwlagn_hcmd = {
	.commit_rxon = iwl_commit_rxon,
	.set_rxon_chain = iwl_set_rxon_chain,
	.set_tx_ant = iwlagn_send_tx_ant_config,
	.send_bt_config = iwl_send_bt_config,
};

struct iwl_hcmd_utils_ops iwlagn_hcmd_utils = {
+1 −1
Original line number Diff line number Diff line
@@ -2173,7 +2173,7 @@ static void iwl_alive_start(struct iwl_priv *priv)
	}

	/* Configure Bluetooth device coexistence support */
	iwl_send_bt_config(priv);
	priv->cfg->ops->hcmd->send_bt_config(priv);

	iwl_reset_run_time_calib(priv);

+4 −3
Original line number Diff line number Diff line
@@ -1479,7 +1479,7 @@ irqreturn_t iwl_isr_legacy(int irq, void *data)
}
EXPORT_SYMBOL(iwl_isr_legacy);

int iwl_send_bt_config(struct iwl_priv *priv)
void iwl_send_bt_config(struct iwl_priv *priv)
{
	struct iwl_bt_cmd bt_cmd = {
		.lead_time = BT_LEAD_TIME_DEF,
@@ -1496,8 +1496,9 @@ int iwl_send_bt_config(struct iwl_priv *priv)
	IWL_DEBUG_INFO(priv, "BT coex %s\n",
		(bt_cmd.flags == BT_COEX_DISABLE) ? "disable" : "active");

	return iwl_send_cmd_pdu(priv, REPLY_BT_CONFIG,
				sizeof(struct iwl_bt_cmd), &bt_cmd);
	if (iwl_send_cmd_pdu(priv, REPLY_BT_CONFIG,
			     sizeof(struct iwl_bt_cmd), &bt_cmd))
		IWL_ERR(priv, "failed to send BT Coex Config\n");
}
EXPORT_SYMBOL(iwl_send_bt_config);

Loading