Skip to contentSkip to conversation

ath10k: WMI API updates

PATCH New Sujith Manoharan 3 participants 6 messages Apr 24, 2013 – Apr 25, 2013 Qualcomm Atheros ATH10K wireless driver

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/3 ath10k: WMI API updates

From: Sujith Manoharan <[email protected]>

To sync with new FW ver .614

---
 drivers/net/wireless/ath/ath10k/hw.h  |  3 ++-
 drivers/net/wireless/ath/ath10k/wmi.c |  1 +
 drivers/net/wireless/ath/ath10k/wmi.h | 12 ++++++++++++
 3 files changed, 15 insertions(+), 1 deletion(-)
drivers/net/wireless/ath/ath10k/hw.h +2 -1
index 82465a8..c8f7e52 100644
@@ -24,7 +24,7 @@
 #define SUPPORTED_FW_MAJOR	1
 #define SUPPORTED_FW_MINOR	0
 #define SUPPORTED_FW_RELEASE	0
-#define SUPPORTED_FW_BUILD	548
+#define SUPPORTED_FW_BUILD	614
 
 /* AR9888 1.0 definitions */
 #define AR9888_HW_1_0_VERSION		0x4000002c
@@ -50,6 +50,7 @@
 #define TARGET_AST_SKID_LIMIT			16
 #define TARGET_NUM_PEERS			16
 #define TARGET_NUM_OFFLOAD_PEERS		0
+#define TARGET_NUM_OFFLOAD_REORDER_BUFS         0
 #define TARGET_NUM_PEER_KEYS			2
 #define TARGET_NUM_TIDS	(2 * (TARGET_NUM_PEERS + TARGET_NUM_VDEV))
 #define TARGET_TX_CHAIN_MASK			0x7
drivers/net/wireless/ath/ath10k/wmi.c +1 -0
index 3de4bb2..98c6f1a 100644
@@ -1236,6 +1236,7 @@ int ath10k_wmi_cmd_init(struct ath10k *ar)
 		/* reserve an additional peer for each VDEV */
 		__cpu_to_le32(TARGET_NUM_PEERS + TARGET_NUM_VDEV),
 		__cpu_to_le32(TARGET_NUM_OFFLOAD_PEERS),
+		__cpu_to_le32(TARGET_NUM_OFFLOAD_REORDER_BUFS),
 		__cpu_to_le32(TARGET_NUM_PEER_KEYS),
 		__cpu_to_le32(TARGET_NUM_TIDS),
 		__cpu_to_le32(TARGET_AST_SKID_LIMIT),
drivers/net/wireless/ath/ath10k/wmi.h +12 -0
index 2bb8f0a..3a9f4ad 100644
@@ -378,6 +378,8 @@ enum wmi_cmd_id {
 	WMI_DBGLOG_CFG_CMDID,
 	WMI_PDEV_QVIT_CMDID,
 	WMI_PDEV_FTM_INTG_CMDID,
+	WMI_VDEV_SET_KEEPALIVE_CMDID,
+	WMI_VDEV_GET_KEEPALIVE_CMDID,
 	WMI_PDEV_UTF_CMDID,
 };
 
@@ -440,6 +442,8 @@ enum wmi_event_id {
 	WMI_PDEV_QVIT_EVENTID,
 	WMI_WLAN_PROFILE_DATA_EVENTID,
 	WMI_PDEV_FTM_INTG_EVENTID,
+	WMI_WLAN_FREQ_AVOID_EVENTID,
+	WMI_VDEV_GET_KEEPALIVE_EVENTID,
 	WMI_PDEV_UTF_EVENTID,
 };
 
@@ -748,6 +752,9 @@ struct wmi_resource_config {
 	 */
 	__le32 num_offload_peers;
 
+	/* For target-based RX reordering */
+	__le32 num_offload_reorder_bufs;
+
 	/* number of keys per peer */
 	__le32 num_peer_keys;
 
@@ -1054,6 +1061,9 @@ struct wmi_start_scan_cmd {
 	__le32 probe_delay;
 	/* Scan control flags */
 	__le32 scan_ctrl_flags;
+
+	/* Burst duration time in msecs */
+	__le32 burst_duration;
 	/*
 	 * TLV (tag length value )  paramerters follow the scan_cmd structure.
 	 * TLV can contain channel list, bssid list, ssid list and
@@ -2038,6 +2048,8 @@ enum wmi_vdev_param {
 	WMI_VDEV_PARAM_MCAST_INDICATE,
 	/* Tx DHCP packet indicate Enable/Disable */
 	WMI_VDEV_PARAM_DHCP_INDICATE,
+	/* Enable host inspection of Tx unicast packet to unknown destination */
+	WMI_VDEV_PARAM_UNKNOWN_DEST_INDICATE,
 
 	/* The minimum amount of time AP begins to consider STA inactive */
 	WMI_VDEV_PARAM_AP_KEEPALIVE_MIN_IDLE_INACTIVE_TIME_SECS,
Signature · 1 line
1.8.2.1
#1 lore raw

PATCH v2 1/3 ath10k: WMI API updates

Quoted 3 lines · Sujith Manoharan

From: Sujith Manoharan <[email protected]>

To sync with new FW ver .614

A rebased patch below.
(Also, http://msujith.org/patches/wl/Apr-24-2013/0005-ath10k-WMI-API-updates.patch).

Sujith

[PATCH] ath10k: WMI API updates

To sync with new FW ver .614

---
 drivers/net/wireless/ath/ath10k/hw.h  |  3 ++-
 drivers/net/wireless/ath/ath10k/wmi.c |  1 +
 drivers/net/wireless/ath/ath10k/wmi.h | 12 ++++++++++++
 3 files changed, 15 insertions(+), 1 deletion(-)
drivers/net/wireless/ath/ath10k/hw.h +2 -1
index 2e6fed9..453cc6c 100644
@@ -26,7 +26,7 @@
 #define SUPPORTED_FW_MAJOR	1
 #define SUPPORTED_FW_MINOR	0
 #define SUPPORTED_FW_RELEASE	0
-#define SUPPORTED_FW_BUILD	599
+#define SUPPORTED_FW_BUILD	614
 
 /* AR9888 1.0 definitions */
 #define AR9888_HW_1_0_VERSION		0x4000002c
@@ -70,6 +70,7 @@ enum ath10k_mcast2ucast_mode {
 #define TARGET_AST_SKID_LIMIT			16
 #define TARGET_NUM_PEERS			16
 #define TARGET_NUM_OFFLOAD_PEERS		0
+#define TARGET_NUM_OFFLOAD_REORDER_BUFS         0
 #define TARGET_NUM_PEER_KEYS			2
 #define TARGET_NUM_TIDS				(2 * ((TARGET_NUM_PEERS) + (TARGET_NUM_VDEVS)))
 #define TARGET_TX_CHAIN_MASK			(BIT(0) | BIT(1) | BIT(2))
drivers/net/wireless/ath/ath10k/wmi.c +1 -0
index b6048c1..0a853f2 100644
@@ -1235,6 +1235,7 @@ int ath10k_wmi_cmd_init(struct ath10k *ar)
 		.num_vdevs = __cpu_to_le32(TARGET_NUM_VDEVS),
 		.num_peers = __cpu_to_le32(TARGET_NUM_PEERS + TARGET_NUM_VDEVS),
 		.num_offload_peers = __cpu_to_le32(TARGET_NUM_OFFLOAD_PEERS),
+		.num_offload_reorder_bufs = __cpu_to_le32(TARGET_NUM_OFFLOAD_REORDER_BUFS),
 		.num_peer_keys = __cpu_to_le32(TARGET_NUM_PEER_KEYS),
 		.num_tids = __cpu_to_le32(TARGET_NUM_TIDS),
 		.ast_skid_limit = __cpu_to_le32(TARGET_AST_SKID_LIMIT),
drivers/net/wireless/ath/ath10k/wmi.h +12 -0
index 50f94a37..4f0dd7e 100644
@@ -378,6 +378,8 @@ enum wmi_cmd_id {
 	WMI_DBGLOG_CFG_CMDID,
 	WMI_PDEV_QVIT_CMDID,
 	WMI_PDEV_FTM_INTG_CMDID,
+	WMI_VDEV_SET_KEEPALIVE_CMDID,
+	WMI_VDEV_GET_KEEPALIVE_CMDID,
 	WMI_PDEV_UTF_CMDID,
 };
 
@@ -440,6 +442,8 @@ enum wmi_event_id {
 	WMI_PDEV_QVIT_EVENTID,
 	WMI_WLAN_PROFILE_DATA_EVENTID,
 	WMI_PDEV_FTM_INTG_EVENTID,
+	WMI_WLAN_FREQ_AVOID_EVENTID,
+	WMI_VDEV_GET_KEEPALIVE_EVENTID,
 	WMI_PDEV_UTF_EVENTID,
 };
 
@@ -748,6 +752,9 @@ struct wmi_resource_config {
 	 */
 	__le32 num_offload_peers;
 
+	/* For target-based RX reordering */
+	__le32 num_offload_reorder_bufs;
+
 	/* number of keys per peer */
 	__le32 num_peer_keys;
 
@@ -1056,6 +1063,9 @@ struct wmi_start_scan_cmd {
 	__le32 probe_delay;
 	/* Scan control flags */
 	__le32 scan_ctrl_flags;
+
+	/* Burst duration time in msecs */
+	__le32 burst_duration;
 	/*
 	 * TLV (tag length value )  paramerters follow the scan_cmd structure.
 	 * TLV can contain channel list, bssid list, ssid list and
@@ -2040,6 +2050,8 @@ enum wmi_vdev_param {
 	WMI_VDEV_PARAM_MCAST_INDICATE,
 	/* Tx DHCP packet indicate Enable/Disable */
 	WMI_VDEV_PARAM_DHCP_INDICATE,
+	/* Enable host inspection of Tx unicast packet to unknown destination */
+	WMI_VDEV_PARAM_UNKNOWN_DEST_INDICATE,
 
 	/* The minimum amount of time AP begins to consider STA inactive */
 	WMI_VDEV_PARAM_AP_KEEPALIVE_MIN_IDLE_INACTIVE_TIME_SECS,
Signature · 1 line
1.8.2.1
#2 lore raw

PATCH v2 1/3 ath10k: WMI API updates

Quoted 8 lines · Sujith Manoharan
Quoted 3 lines · Sujith Manoharan

From: Sujith Manoharan <[email protected]>

To sync with new FW ver .614

A rebased patch below.
(Also, http://msujith.org/patches/wl/Apr-24-2013/0005-ath10k-WMI-API-updates.patch).

Quoted 7 lines

Sujith

[PATCH] ath10k: WMI API updates

To sync with new FW ver .614

Thanks, I applied this rebased version of patch 1as well as patch 2 and 3 from the original patchset. But in the future, when rebasing please just resend the complete patchset. It's much more reliable that way.

Signature · 1 line
Kalle Valo
#3 lore raw

PATCH v2 2/3 ath10k: Merge debug levels

In reply to Sujith Manoharan

From: Sujith Manoharan <[email protected]>

BMI, BOOT with CORE and RX with HTT.

---
 drivers/net/wireless/ath/ath10k/bmi.c   |  8 ++++----
 drivers/net/wireless/ath/ath10k/core.c  |  4 ++--
 drivers/net/wireless/ath/ath10k/debug.h | 19 ++++++++-----------
 drivers/net/wireless/ath/ath10k/txrx.c  |  2 +-
 4 files changed, 15 insertions(+), 18 deletions(-)
drivers/net/wireless/ath/ath10k/bmi.c +4 -4
index 85bf366..512f54f 100644
@@ -27,7 +27,7 @@ int ath10k_bmi_done(struct ath10k *ar)
 	int ret;
 
 	if (ar->bmi.done_sent) {
-		ath10k_dbg(ATH10K_DBG_BMI, "%s skipped\n", __func__);
+		ath10k_dbg(ATH10K_DBG_CORE, "%s skipped\n", __func__);
 		return 0;
 	}
 
@@ -91,7 +91,7 @@ int ath10k_bmi_read_memory(struct ath10k *ar,
 		return -EBUSY;
 	}
 
-	ath10k_dbg(ATH10K_DBG_BMI,
+	ath10k_dbg(ATH10K_DBG_CORE,
 		   "%s: (device: 0x%p, address: 0x%x, length: %d)\n",
 		   __func__, ar, address, length);
 
@@ -130,7 +130,7 @@ int ath10k_bmi_write_memory(struct ath10k *ar,
 		return -EBUSY;
 	}
 
-	ath10k_dbg(ATH10K_DBG_BMI,
+	ath10k_dbg(ATH10K_DBG_CORE,
 		   "%s: (device: 0x%p, address: 0x%x, length: %d)\n",
 		   __func__, ar, address, length);
 
@@ -176,7 +176,7 @@ int ath10k_bmi_execute(struct ath10k *ar, u32 address, u32 *param)
 		return -EBUSY;
 	}
 
-	ath10k_dbg(ATH10K_DBG_BMI,
+	ath10k_dbg(ATH10K_DBG_CORE,
 		   "%s: (device: 0x%p, address: 0x%x, param: %d)\n",
 		   __func__, ar, address, *param);
 
drivers/net/wireless/ath/ath10k/core.c +2 -2
index 07102b8..e2379ff 100644
@@ -266,7 +266,7 @@ static int ath10k_init_transfer_bin_file(struct ath10k *ar,
 		/* Determine where in Target RAM to write Board Data */
 		ath10k_bmi_read32(ar, hi_board_ext_data, &board_ext_address);
 
-		ath10k_dbg(ATH10K_DBG_BOOT,
+		ath10k_dbg(ATH10K_DBG_CORE,
 			   "ath10k: Board extended Data download addr: 0x%x\n",
 			   board_ext_address);
 
@@ -347,7 +347,7 @@ static int ath10k_init_download_firmware(struct ath10k *ar)
 
 	/* Transfer One Time Programmable data */
 	address = ar->hw_params.patch_load_addr;
-	ath10k_dbg(ATH10K_DBG_BOOT,
+	ath10k_dbg(ATH10K_DBG_CORE,
 		   "Using 0x%x for the remainder of init\n", address);
 
 	status = ath10k_init_transfer_bin_file(ar, ATH10K_FILE_OTP,
drivers/net/wireless/ath/ath10k/debug.h +8 -11
index 3ae598a..8c0a499 100644
@@ -23,17 +23,14 @@
 
 enum ath10k_debug_mask {
 	ATH10K_DBG_PCI		= 0x00000001,
-	ATH10K_DBG_BMI		= 0x00000002,
-	ATH10K_DBG_WMI		= 0x00000004,
-	ATH10K_DBG_HTC		= 0x00000008,
-	ATH10K_DBG_HTT		= 0x00000010,
-	ATH10K_DBG_MAC		= 0x00000020,
-	ATH10K_DBG_CORE		= 0x00000040,
-	ATH10K_DBG_BOOT		= 0x00000080,
-	ATH10K_DBG_PCI_DUMP	= 0x00000100,
-	ATH10K_DBG_HTT_DUMP	= 0x00000200,
-	ATH10K_DBG_RX		= 0x00000400,
-	ATH10K_DBG_BEACON	= 0x00000800,
+	ATH10K_DBG_WMI		= 0x00000002,
+	ATH10K_DBG_HTC		= 0x00000004,
+	ATH10K_DBG_HTT		= 0x00000008,
+	ATH10K_DBG_MAC		= 0x00000010,
+	ATH10K_DBG_CORE		= 0x00000020,
+	ATH10K_DBG_PCI_DUMP	= 0x00000040,
+	ATH10K_DBG_HTT_DUMP	= 0x00000080,
+	ATH10K_DBG_BEACON	= 0x00000100,
 	ATH10K_DBG_ANY		= 0xffffffff,
 };
 
drivers/net/wireless/ath/ath10k/txrx.c +1 -1
index 6a66dc2..0e8f86d 100644
@@ -269,7 +269,7 @@ void ath10k_process_rx(struct ath10k *ar, struct htt_rx_info *info)
 	status->freq = ch->center_freq;
 	rcu_read_unlock();
 
-	ath10k_dbg(ATH10K_DBG_RX,
+	ath10k_dbg(ATH10K_DBG_HTT,
 		   "rx skb %p len %u %s%s%s%s%s %srate_idx %u vht_nss %u freq %u band %u\n",
 		   info->skb,
 		   info->skb->len,
Signature · 1 line
1.8.2.1
#4 lore raw

PATCH v2 1/3 ath10k: WMI API updates

In reply to Sujith Manoharan
Quoted 11 lines · Sujith Manoharan

From: Sujith Manoharan <[email protected]>

To sync with new FW ver .614

---
  drivers/net/wireless/ath/ath10k/hw.h  |  3 ++-
  drivers/net/wireless/ath/ath10k/wmi.c |  1 +
  drivers/net/wireless/ath/ath10k/wmi.h | 12 ++++++++++++
  3 files changed, 15 insertions(+), 1 deletion(-)

Thanks!

I have checked this also.
ACK from me for this firmware step up.

-Bartosz

#5 lore raw

PATCH v2 3/3 ath10k: Initialize CW mode

In reply to Sujith Manoharan

From: Sujith Manoharan <[email protected]>

Set the channel width mode to static by default.

---
 drivers/net/wireless/ath/ath10k/mac.c | 7 +++++++
 1 file changed, 7 insertions(+)
drivers/net/wireless/ath/ath10k/mac.c +7 -0
index dd9430a..ce899a6 100644
@@ -1492,6 +1492,9 @@ static void ath10k_tx(struct ieee80211_hw *hw,
 	ath10k_tx_htt(ar, skb);
 }
 
+/*
+ * Initialize various parameters with default vaules.
+ */
 static int ath10k_start(struct ieee80211_hw *hw)
 {
 	struct ath10k *ar = hw->priv;
@@ -1501,6 +1504,10 @@ static int ath10k_start(struct ieee80211_hw *hw)
 	if (ret)
 		ath10k_warn("could not enable WMI_PDEV_PARAM_PMF_QOS (%d)\n", ret);
 
+	ret = ath10k_wmi_pdev_set_param(ar, WMI_PDEV_PARAM_DYNAMIC_BW, 0);
+	if (ret)
+		ath10k_warn("could not init WMI_PDEV_PARAM_DYNAMIC_BW (%d)\n", ret);
+
 	return 0;
 }
 
Signature · 1 line
1.8.2.1