qcacld-3.0: Maintain limit off channel params per adapter

The limit off channel parameters were applied to all adapters
even though application sends this command on a particular
interface.

Maintain limit off channel parameters per interafce.

CRs-Fixed: 2103637
Change-Id: Ib768bfb61deac77ea2d67b7d6b6750a96bdc8902
This commit is contained in:
Ganesh Kondabattini 2017-09-28 12:21:58 +05:30 • committed by snandini
commit 1a2aed894a
2 changed files with 6 additions and 6 deletions

View file

@ -1324,6 +1324,7 @@ struct hdd_adapter {
u8 restrict_offchannel_cnt;
bool con_status;
bool dad;
uint8_t active_ac;
};
#define WLAN_HDD_GET_STATION_CTX_PTR(pAdapter) (&(pAdapter)->sessionCtx.station)
@ -1820,7 +1821,6 @@ struct hdd_context {
uint8_t bt_vo_active:1;
struct hdd_nud_stats_context nud_stats_context;
eCsrBand curr_band;
uint8_t active_ac;
bool fw_mem_dump_enabled;
};

View file

@ -12579,17 +12579,17 @@ int hdd_set_limit_off_chan_for_tos(struct hdd_adapter *adapter, enum tos tos,
ac_bit = limit_off_chan_tbl[tos][HDD_AC_BIT_INDX];
if (is_tos_active)
hdd_ctx->active_ac |= ac_bit;
adapter->active_ac |= ac_bit;
else
hdd_ctx->active_ac &= ~ac_bit;
adapter->active_ac &= ~ac_bit;
if (hdd_ctx->active_ac) {
if (hdd_ctx->active_ac & HDD_AC_VO_BIT) {
if (adapter->active_ac) {
if (adapter->active_ac & HDD_AC_VO_BIT) {
cmd->max_off_chan_time =
limit_off_chan_tbl[TOS_VO][HDD_DWELL_TIME_INDX];
policy_mgr_set_cur_conc_system_pref(hdd_ctx->hdd_psoc,
PM_LATENCY);
} else if (hdd_ctx->active_ac & HDD_AC_VI_BIT) {
} else if (adapter->active_ac & HDD_AC_VI_BIT) {
cmd->max_off_chan_time =
limit_off_chan_tbl[TOS_VI][HDD_DWELL_TIME_INDX];
policy_mgr_set_cur_conc_system_pref(hdd_ctx->hdd_psoc,