qcacmn: New HTT H2T msg support

Current HTT_H2T messages from host driver does not have
consistency in message length set by host driver. Some
message types include HTC header length also within the
message length, while other types have message length
itself only, which causes difficulty in handling message
length in FW.

Change-Id: I885a21530a2d8f852387ae54cf7ee0751aad2516
CRs-Fixed: 2345075
This commit is contained in:
jitiphil
2018-11-05 14:31:21 +05:30
committed by nshrivas
parent 264fe67fd1
commit e65cc2defe
4 changed files with 39 additions and 2 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2016-2017 The Linux Foundation. All rights reserved.
* Copyright (c) 2016-2017, 2018 The Linux Foundation. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@@ -306,4 +306,31 @@ cdp_cfg_set_ptp_rx_opt_enabled(ol_txrx_soc_handle soc,
soc->ops->cfg_ops->set_ptp_rx_opt_enabled(cfg_pdev, val);
}
/**
* cdp_cfg_set_new_htt_msg_format() - set htt h2t msg feature
* @soc - datapath soc handle
* @val - enable or disable new htt h2t msg feature
*
* Enable whether htt h2t message length includes htc header length
*
* return NONE
*/
static inline void
cdp_cfg_set_new_htt_msg_format(ol_txrx_soc_handle soc,
uint8_t val)
{
if (!soc || !soc->ops) {
QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_DEBUG,
"%s invalid instance", __func__);
return;
}
if (!soc->ops->cfg_ops ||
!soc->ops->cfg_ops->set_new_htt_msg_format)
return;
soc->ops->cfg_ops->set_new_htt_msg_format(val);
}
#endif /* _CDP_TXRX_CFG_H_ */

View File

@@ -964,6 +964,7 @@ struct cdp_cfg_ops {
void *param);
void (*set_flow_steering)(struct cdp_cfg *cfg_pdev, uint8_t val);
void (*set_ptp_rx_opt_enabled)(struct cdp_cfg *cfg_pdev, uint8_t val);
void (*set_new_htt_msg_format)(uint8_t val);
};
/**

View File

@@ -5236,6 +5236,7 @@ typedef enum {
wmi_service_esp_support,
wmi_service_obss_spatial_reuse,
wmi_service_per_vdev_chain_support,
wmi_service_new_htt_msg_format,
wmi_services_max,
} wmi_conv_service_ids;
#define WMI_SERVICE_UNAVAILABLE 0xFFFF
@@ -5399,7 +5400,8 @@ typedef struct {
uint32_t tt_support;
uint32_t atf_config:1,
mgmt_comp_evt_bundle_support:1,
tx_msdu_new_partition_id_support:1;
tx_msdu_new_partition_id_support:1,
new_htt_msg_format:1;
uint32_t iphdr_pad_config;
uint32_t
qwrap_config:16,

View File

@@ -6274,6 +6274,10 @@ void wmi_copy_resource_config(wmi_resource_config *resource_cfg,
tgt_res_cfg->eapol_minrate_ac_set);
}
}
if (tgt_res_cfg->new_htt_msg_format) {
WMI_RSRC_CFG_FLAG_HTT_H2T_NO_HTC_HDR_LEN_IN_MSG_LEN_SET(
resource_cfg->flag1, 1);
}
wmi_copy_twt_resource_config(resource_cfg, tgt_res_cfg);
resource_cfg->peer_map_unmap_v2_support =
@@ -11856,6 +11860,9 @@ static void populate_tlv_service(uint32_t *wmi_service)
WMI_SERVICE_OBSS_SPATIAL_REUSE;
wmi_service[wmi_service_per_vdev_chain_support] =
WMI_SERVICE_PER_VDEV_CHAINMASK_CONFIG_SUPPORT;
wmi_service[wmi_service_new_htt_msg_format] =
WMI_SERVICE_HTT_H2T_NO_HTC_HDR_LEN_IN_MSG_LEN;
}
#ifndef CONFIG_MCL