QSAP: Do not modify hw_mode when channel is set to 0 (for ACS).
Currently when channel value is less than 14, hw_mode is set to g (or b). Application might want to run ACS by setting channel=0 in all possible hw modes. This commit skip changing hw_mode, if channel is set to 0. Change-Id: I0da492d70ec9c9455d79e4df33fb86a7313633ba CRs-Fixed: 2245734
This commit is contained in:
committed by
Gerrit - the friendly Code Review server
parent
c613ebbc1c
commit
168beebc4e
@@ -2373,6 +2373,10 @@ static int qsap_set_channel(s32 channel, s8 *tbuf, u32 *tlen)
|
||||
|
||||
ulen = *tlen;
|
||||
|
||||
/* Do not worry about hw_mode if intention is to use ACS (channel=0) */
|
||||
if (channel == 0)
|
||||
goto end;
|
||||
|
||||
/** Read the current operating mode */
|
||||
if(NULL == (pcfgval = qsap_get_config_value(pconffile, &cmd_list[eCMD_HW_MODE], tbuf, &ulen))) {
|
||||
return eERR_UNKNOWN;
|
||||
@@ -2409,6 +2413,7 @@ static int qsap_set_channel(s32 channel, s8 *tbuf, u32 *tlen)
|
||||
}
|
||||
}
|
||||
|
||||
end:
|
||||
qsap_scnprintf(schan, sizeof(schan), "%ld", channel);
|
||||
|
||||
return qsap_write_cfg(pcfg, &cmd_list[eCMD_CHAN], schan, tbuf, tlen, HOSTAPD_CONF_QCOM_FILE);
|
||||
|
||||
Reference in New Issue
Block a user