mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-12 07:37:31 -04:00
qcacld-3.0: Fix the TWT suspend operation command failure
TWT params are optional attributes for TWT suspend operation. Do not mandate the check for TWT params for TWT suspend command. Parse the TWT params if attribute is present in the suspend command else use the default value. Change-Id: I62fa5e0e8a9c0346957184b9578bdd273017df21 CRs-Fixed: 3027776
This commit is contained in:
parent
0be03ac373
commit
4173ac8d98
1 changed files with 15 additions and 11 deletions
|
|
@ -2728,22 +2728,25 @@ static int hdd_twt_pause_session(struct hdd_adapter *adapter,
|
|||
qdf_mem_copy(params.peer_macaddr, hdd_sta_ctx->conn_info.bssid.bytes,
|
||||
QDF_MAC_ADDR_SIZE);
|
||||
params.vdev_id = adapter->vdev_id;
|
||||
params.dialog_id = 0;
|
||||
|
||||
ret = wlan_cfg80211_nla_parse_nested(tb,
|
||||
if (twt_param_attr) {
|
||||
ret = wlan_cfg80211_nla_parse_nested(tb,
|
||||
QCA_WLAN_VENDOR_ATTR_TWT_SETUP_MAX,
|
||||
twt_param_attr,
|
||||
qca_wlan_vendor_twt_add_dialog_policy);
|
||||
if (ret) {
|
||||
hdd_debug("command parsing failed");
|
||||
return ret;
|
||||
}
|
||||
if (ret) {
|
||||
hdd_debug("command parsing failed");
|
||||
return ret;
|
||||
}
|
||||
|
||||
id = QCA_WLAN_VENDOR_ATTR_TWT_SETUP_FLOW_ID;
|
||||
if (tb[id]) {
|
||||
params.dialog_id = nla_get_u8(tb[id]);
|
||||
id = QCA_WLAN_VENDOR_ATTR_TWT_SETUP_FLOW_ID;
|
||||
if (tb[id])
|
||||
params.dialog_id = nla_get_u8(tb[id]);
|
||||
else
|
||||
hdd_debug("TWT: FLOW_ID not specified. set to zero");
|
||||
} else {
|
||||
params.dialog_id = 0;
|
||||
hdd_debug("TWT: FLOW_ID not specified. set to zero");
|
||||
hdd_debug("TWT param not present. flow id set to zero");
|
||||
}
|
||||
|
||||
status = hdd_twt_check_all_twt_support(adapter->hdd_ctx->psoc,
|
||||
|
|
@ -3877,7 +3880,8 @@ static int hdd_twt_configure(struct hdd_adapter *adapter,
|
|||
twt_param_attr = tb[id];
|
||||
|
||||
if (!twt_param_attr &&
|
||||
twt_oper != QCA_WLAN_TWT_GET_CAPABILITIES) {
|
||||
twt_oper != QCA_WLAN_TWT_GET_CAPABILITIES &&
|
||||
twt_oper != QCA_WLAN_TWT_SUSPEND) {
|
||||
hdd_err("TWT parameters NOT specified");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue