qcacld-3.0: Avoid to start ROC with invalid duration

Up layer tx probe response frame with wait/duration 0, which may be
start ROC with duration 0 and then tx mgmt frame fail since of very
short ROC and no enough time to wait for tx ack.

Change-Id: I5243ff10726b642d8cf18992a230d741f9d2655f
CRs-Fixed: 2397719
这个提交包含在:
Wu Gao
2019-02-25 14:37:30 +08:00
提交者 nshrivas
父节点 87b16541a3
当前提交 4fe2308438
修改 3 个文件,包含 13 行新增1 行删除

查看文件

@@ -2804,6 +2804,11 @@ QDF_STATUS p2p_process_mgmt_tx(struct tx_action_context *tx_ctx)
}
}
if (!tx_ctx->duration) {
tx_ctx->duration = P2P_ACTION_FRAME_DEFAULT_WAIT;
p2p_debug("use default wait %d",
P2P_ACTION_FRAME_DEFAULT_WAIT);
}
status = p2p_roc_req_for_tx_action(tx_ctx);
if (status != QDF_STATUS_SUCCESS) {
p2p_err("Failed to request roc before off chan tx");

查看文件

@@ -100,6 +100,12 @@ static QDF_STATUS p2p_scan_start(struct p2p_roc_context *roc_ctx)
ucfg_scan_init_default_params(vdev, req);
if (!roc_ctx->duration) {
roc_ctx->duration = P2P_ROC_DEFAULT_DURATION;
p2p_debug("use default duration %d",
P2P_ROC_DEFAULT_DURATION);
}
roc_ctx->scan_id = ucfg_scan_get_scan_id(p2p_soc_obj->soc);
req->vdev = vdev;
req->scan_req.scan_id = roc_ctx->scan_id;

查看文件

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2017-2018 The Linux Foundation. All rights reserved.
* Copyright (c) 2017-2019 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
@@ -35,6 +35,7 @@
#define P2P_ROC_DURATION_MULTI_GO_PRESENT 6
#define P2P_ROC_DURATION_MULTI_GO_ABSENT 10
#define P2P_ACTION_FRAME_DEFAULT_WAIT 200
#define P2P_ROC_DEFAULT_DURATION 200
struct wlan_objmgr_vdev;
struct scan_event;