Commit de23d3ef authored by Michal Kazior's avatar Michal Kazior Committed by Kalle Valo

ath10k: change request stats command prototype

The expected parameter is not a single value but a
mask of values.
Signed-off-by: default avatarMichal Kazior <michal.kazior@tieto.com>
Signed-off-by: default avatarKalle Valo <kvalo@qca.qualcomm.com>
parent 7b6b153a
...@@ -110,8 +110,7 @@ struct wmi_ops { ...@@ -110,8 +110,7 @@ struct wmi_ops {
bool deliver_cab); bool deliver_cab);
struct sk_buff *(*gen_pdev_set_wmm)(struct ath10k *ar, struct sk_buff *(*gen_pdev_set_wmm)(struct ath10k *ar,
const struct wmi_wmm_params_all_arg *arg); const struct wmi_wmm_params_all_arg *arg);
struct sk_buff *(*gen_request_stats)(struct ath10k *ar, struct sk_buff *(*gen_request_stats)(struct ath10k *ar, u32 stats_mask);
enum wmi_stats_id stats_id);
struct sk_buff *(*gen_force_fw_hang)(struct ath10k *ar, struct sk_buff *(*gen_force_fw_hang)(struct ath10k *ar,
enum wmi_force_fw_hang_type type, enum wmi_force_fw_hang_type type,
u32 delay_ms); u32 delay_ms);
...@@ -816,14 +815,14 @@ ath10k_wmi_pdev_set_wmm_params(struct ath10k *ar, ...@@ -816,14 +815,14 @@ ath10k_wmi_pdev_set_wmm_params(struct ath10k *ar,
} }
static inline int static inline int
ath10k_wmi_request_stats(struct ath10k *ar, enum wmi_stats_id stats_id) ath10k_wmi_request_stats(struct ath10k *ar, u32 stats_mask)
{ {
struct sk_buff *skb; struct sk_buff *skb;
if (!ar->wmi.ops->gen_request_stats) if (!ar->wmi.ops->gen_request_stats)
return -EOPNOTSUPP; return -EOPNOTSUPP;
skb = ar->wmi.ops->gen_request_stats(ar, stats_id); skb = ar->wmi.ops->gen_request_stats(ar, stats_mask);
if (IS_ERR(skb)) if (IS_ERR(skb))
return PTR_ERR(skb); return PTR_ERR(skb);
......
...@@ -2080,8 +2080,7 @@ ath10k_wmi_tlv_op_gen_pdev_set_wmm(struct ath10k *ar, ...@@ -2080,8 +2080,7 @@ ath10k_wmi_tlv_op_gen_pdev_set_wmm(struct ath10k *ar,
} }
static struct sk_buff * static struct sk_buff *
ath10k_wmi_tlv_op_gen_request_stats(struct ath10k *ar, ath10k_wmi_tlv_op_gen_request_stats(struct ath10k *ar, u32 stats_mask)
enum wmi_stats_id stats_id)
{ {
struct wmi_request_stats_cmd *cmd; struct wmi_request_stats_cmd *cmd;
struct wmi_tlv *tlv; struct wmi_tlv *tlv;
...@@ -2095,7 +2094,7 @@ ath10k_wmi_tlv_op_gen_request_stats(struct ath10k *ar, ...@@ -2095,7 +2094,7 @@ ath10k_wmi_tlv_op_gen_request_stats(struct ath10k *ar,
tlv->tag = __cpu_to_le16(WMI_TLV_TAG_STRUCT_REQUEST_STATS_CMD); tlv->tag = __cpu_to_le16(WMI_TLV_TAG_STRUCT_REQUEST_STATS_CMD);
tlv->len = __cpu_to_le16(sizeof(*cmd)); tlv->len = __cpu_to_le16(sizeof(*cmd));
cmd = (void *)tlv->value; cmd = (void *)tlv->value;
cmd->stats_id = __cpu_to_le32(stats_id); cmd->stats_id = __cpu_to_le32(stats_mask);
ath10k_dbg(ar, ATH10K_DBG_WMI, "wmi tlv request stats\n"); ath10k_dbg(ar, ATH10K_DBG_WMI, "wmi tlv request stats\n");
return skb; return skb;
......
...@@ -4974,7 +4974,7 @@ ath10k_wmi_op_gen_pdev_set_wmm(struct ath10k *ar, ...@@ -4974,7 +4974,7 @@ ath10k_wmi_op_gen_pdev_set_wmm(struct ath10k *ar,
} }
static struct sk_buff * static struct sk_buff *
ath10k_wmi_op_gen_request_stats(struct ath10k *ar, enum wmi_stats_id stats_id) ath10k_wmi_op_gen_request_stats(struct ath10k *ar, u32 stats_mask)
{ {
struct wmi_request_stats_cmd *cmd; struct wmi_request_stats_cmd *cmd;
struct sk_buff *skb; struct sk_buff *skb;
...@@ -4984,9 +4984,10 @@ ath10k_wmi_op_gen_request_stats(struct ath10k *ar, enum wmi_stats_id stats_id) ...@@ -4984,9 +4984,10 @@ ath10k_wmi_op_gen_request_stats(struct ath10k *ar, enum wmi_stats_id stats_id)
return ERR_PTR(-ENOMEM); return ERR_PTR(-ENOMEM);
cmd = (struct wmi_request_stats_cmd *)skb->data; cmd = (struct wmi_request_stats_cmd *)skb->data;
cmd->stats_id = __cpu_to_le32(stats_id); cmd->stats_id = __cpu_to_le32(stats_mask);
ath10k_dbg(ar, ATH10K_DBG_WMI, "wmi request stats %d\n", (int)stats_id); ath10k_dbg(ar, ATH10K_DBG_WMI, "wmi request stats 0x%08x\n",
stats_mask);
return skb; return skb;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment