@@ -289,6 +289,11 @@ struct ath10k_fw_stats_pdev {
s32 mpdu_errs;
s32 rx_ovfl_errs;
s32 rx_timeout_errs;
+
+ /* Other PDEV stats */
+ s32 dram_free;
+ s32 iram_free;
+ s32 sram_free;
};
struct ath10k_fw_stats {
@@ -3046,6 +3046,9 @@ static int ath10k_wmi_10_2_op_pull_fw_stats(struct ath10k *ar,
ath10k_wmi_pull_pdev_stats_base(&src->base, dst);
ath10k_wmi_pull_pdev_stats_tx(&src->tx, dst);
ath10k_wmi_pull_pdev_stats_rx(&src->rx, dst);
+ dst->rx_timeout_errs = __le32_to_cpu(src->pdev_rx_timeout);
+ dst->dram_free = __le32_to_cpu(src->mem.dram_free);
+ dst->iram_free = __le32_to_cpu(src->mem.iram_free);
ath10k_wmi_pull_pdev_stats_extra(&src->extra, dst);
/* FIXME: expose 10.2 specific values */
@@ -3219,6 +3222,9 @@ static int ath10k_wmi_10_4_op_pull_fw_stats(struct ath10k *ar,
ath10k_wmi_pull_pdev_stats_rx(&src->rx, dst);
dst->rx_timeout_errs = __le32_to_cpu(src->pdev_rx_timeout);
dst->rx_ovfl_errs = __le32_to_cpu(src->rx_ovfl_errs);
+ dst->dram_free = __le32_to_cpu(src->mem.dram_free);
+ dst->iram_free = __le32_to_cpu(src->mem.iram_free);
+ dst->sram_free = __le32_to_cpu(src->mem.sram_free);
ath10k_wmi_pull_pdev_stats_extra(&src->extra, dst);
list_add_tail(&dst->list, &stats->pdevs);
@@ -8249,6 +8255,13 @@ void ath10k_wmi_10_4_op_fw_stats_fill(struct ath10k *ar,
len += scnprintf(buf + len, buf_len - len, "%30s %10d\n",
"Num Rx Overflow errors", pdev->rx_ovfl_errs);
+ len += scnprintf(buf + len, buf_len - len, "%30s %10d\n",
+ "DRAM Free", pdev->dram_free);
+ len += scnprintf(buf + len, buf_len - len, "%30s %10d\n",
+ "IRAM Free", pdev->iram_free);
+ len += scnprintf(buf + len, buf_len - len, "%30s %10d\n",
+ "SRAM Free", pdev->sram_free);
+
len += scnprintf(buf + len, buf_len - len, "\n");
len += scnprintf(buf + len, buf_len - len, "%30s (%zu)\n",
"ath10k VDEV stats", num_vdevs);
@@ -4419,6 +4419,12 @@ struct wmi_pdev_stats_mem {
__le32 iram_free;
} __packed;
+struct wmi_pdev_stats_mem_10_4 {
+ __le32 iram_free;
+ __le32 dram_free;
+ __le32 sram_free;
+} __packed;
+
struct wmi_10_2_pdev_stats {
struct wmi_pdev_stats_base base;
struct wmi_pdev_stats_tx tx;
@@ -4436,8 +4442,7 @@ struct wmi_10_4_pdev_stats {
struct wmi_pdev_stats_rx rx;
__le32 pdev_rx_timeout;
__le32 rx_ovfl_errs;
- struct wmi_pdev_stats_mem mem;
- __le32 sram_free_size;
+ struct wmi_pdev_stats_mem_10_4 mem;
struct wmi_pdev_stats_extra extra;
} __packed;