diff options
Diffstat (limited to 'drivers/net/wireless/ath/ath10k/wmi-tlv.c')
-rw-r--r-- | drivers/net/wireless/ath/ath10k/wmi-tlv.c | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath10k/wmi-tlv.c b/drivers/net/wireless/ath/ath10k/wmi-tlv.c index 23a376124de3..00ca544bc94d 100644 --- a/drivers/net/wireless/ath/ath10k/wmi-tlv.c +++ b/drivers/net/wireless/ath/ath10k/wmi-tlv.c | |||
@@ -1600,6 +1600,42 @@ static void *ath10k_wmi_tlv_put_wmm(void *ptr, | |||
1600 | } | 1600 | } |
1601 | 1601 | ||
1602 | static struct sk_buff * | 1602 | static struct sk_buff * |
1603 | ath10k_wmi_tlv_op_gen_vdev_wmm_conf(struct ath10k *ar, u32 vdev_id, | ||
1604 | const struct wmi_wmm_params_all_arg *arg) | ||
1605 | { | ||
1606 | struct wmi_tlv_vdev_set_wmm_cmd *cmd; | ||
1607 | struct wmi_wmm_params *wmm; | ||
1608 | struct wmi_tlv *tlv; | ||
1609 | struct sk_buff *skb; | ||
1610 | size_t len; | ||
1611 | void *ptr; | ||
1612 | |||
1613 | len = (sizeof(*tlv) + sizeof(*cmd)) + | ||
1614 | (4 * (sizeof(*tlv) + sizeof(*wmm))); | ||
1615 | skb = ath10k_wmi_alloc_skb(ar, len); | ||
1616 | if (!skb) | ||
1617 | return ERR_PTR(-ENOMEM); | ||
1618 | |||
1619 | ptr = (void *)skb->data; | ||
1620 | tlv = ptr; | ||
1621 | tlv->tag = __cpu_to_le16(WMI_TLV_TAG_STRUCT_VDEV_SET_WMM_PARAMS_CMD); | ||
1622 | tlv->len = __cpu_to_le16(sizeof(*cmd)); | ||
1623 | cmd = (void *)tlv->value; | ||
1624 | cmd->vdev_id = __cpu_to_le32(vdev_id); | ||
1625 | |||
1626 | ptr += sizeof(*tlv); | ||
1627 | ptr += sizeof(*cmd); | ||
1628 | |||
1629 | ptr = ath10k_wmi_tlv_put_wmm(ptr, &arg->ac_be); | ||
1630 | ptr = ath10k_wmi_tlv_put_wmm(ptr, &arg->ac_bk); | ||
1631 | ptr = ath10k_wmi_tlv_put_wmm(ptr, &arg->ac_vi); | ||
1632 | ptr = ath10k_wmi_tlv_put_wmm(ptr, &arg->ac_vo); | ||
1633 | |||
1634 | ath10k_dbg(ar, ATH10K_DBG_WMI, "wmi tlv vdev wmm conf\n"); | ||
1635 | return skb; | ||
1636 | } | ||
1637 | |||
1638 | static struct sk_buff * | ||
1603 | ath10k_wmi_tlv_op_gen_peer_create(struct ath10k *ar, u32 vdev_id, | 1639 | ath10k_wmi_tlv_op_gen_peer_create(struct ath10k *ar, u32 vdev_id, |
1604 | const u8 peer_addr[ETH_ALEN]) | 1640 | const u8 peer_addr[ETH_ALEN]) |
1605 | { | 1641 | { |
@@ -2426,6 +2462,7 @@ static struct wmi_cmd_map wmi_tlv_cmd_map = { | |||
2426 | .gpio_config_cmdid = WMI_TLV_GPIO_CONFIG_CMDID, | 2462 | .gpio_config_cmdid = WMI_TLV_GPIO_CONFIG_CMDID, |
2427 | .gpio_output_cmdid = WMI_TLV_GPIO_OUTPUT_CMDID, | 2463 | .gpio_output_cmdid = WMI_TLV_GPIO_OUTPUT_CMDID, |
2428 | .pdev_get_temperature_cmdid = WMI_TLV_CMD_UNSUPPORTED, | 2464 | .pdev_get_temperature_cmdid = WMI_TLV_CMD_UNSUPPORTED, |
2465 | .vdev_set_wmm_params_cmdid = WMI_TLV_VDEV_SET_WMM_PARAMS_CMDID, | ||
2429 | }; | 2466 | }; |
2430 | 2467 | ||
2431 | static struct wmi_pdev_param_map wmi_tlv_pdev_param_map = { | 2468 | static struct wmi_pdev_param_map wmi_tlv_pdev_param_map = { |
@@ -2569,6 +2606,7 @@ static const struct wmi_ops wmi_tlv_ops = { | |||
2569 | .gen_vdev_down = ath10k_wmi_tlv_op_gen_vdev_down, | 2606 | .gen_vdev_down = ath10k_wmi_tlv_op_gen_vdev_down, |
2570 | .gen_vdev_set_param = ath10k_wmi_tlv_op_gen_vdev_set_param, | 2607 | .gen_vdev_set_param = ath10k_wmi_tlv_op_gen_vdev_set_param, |
2571 | .gen_vdev_install_key = ath10k_wmi_tlv_op_gen_vdev_install_key, | 2608 | .gen_vdev_install_key = ath10k_wmi_tlv_op_gen_vdev_install_key, |
2609 | .gen_vdev_wmm_conf = ath10k_wmi_tlv_op_gen_vdev_wmm_conf, | ||
2572 | .gen_peer_create = ath10k_wmi_tlv_op_gen_peer_create, | 2610 | .gen_peer_create = ath10k_wmi_tlv_op_gen_peer_create, |
2573 | .gen_peer_delete = ath10k_wmi_tlv_op_gen_peer_delete, | 2611 | .gen_peer_delete = ath10k_wmi_tlv_op_gen_peer_delete, |
2574 | .gen_peer_flush = ath10k_wmi_tlv_op_gen_peer_flush, | 2612 | .gen_peer_flush = ath10k_wmi_tlv_op_gen_peer_flush, |