QSAP: Enhance 'set' commmand to configure for OWE
This creates a new hostapd_owe.conf if use below 'set' CMD: "softap qccmd set owe <args>" CRs-Fixed: 2356574 Change-Id: I1ef4f11f7bdb3155dcfbc2c75fa106c8a3ecc61a
This commit is contained in:
@@ -90,7 +90,8 @@ s8 *Cmd_req[eCMD_REQ_LAST] = {
|
||||
*/
|
||||
s8 *Conf_req[CONF_REQ_LAST] = {
|
||||
"dual2g",
|
||||
"dual5g"
|
||||
"dual5g",
|
||||
"owe"
|
||||
};
|
||||
|
||||
/*
|
||||
@@ -2598,6 +2599,9 @@ static void qsap_handle_set_request(s8 *pcmd, s8 *presp, u32 *plen)
|
||||
} else if (!(strncmp(pcmd, Conf_req[CONF_5g], strlen(Conf_req[CONF_5g])))) {
|
||||
pcmd += strlen(Conf_req[CONF_5g]);
|
||||
SKIP_BLANK_SPACE(pcmd);
|
||||
} else if (!(strncmp(pcmd, Conf_req[CONF_owe], strlen(Conf_req[CONF_owe])))) {
|
||||
pcmd += strlen(Conf_req[CONF_owe]);
|
||||
SKIP_BLANK_SPACE(pcmd);
|
||||
} else {
|
||||
// DO NOTHING
|
||||
}
|
||||
@@ -3172,6 +3176,8 @@ void qsap_hostd_exec_cmd(s8 *pcmd, s8 *presp, u32 *plen)
|
||||
pconffile = CONFIG_FILE_2G;
|
||||
} else if (!(strncmp(pcmd+4, Conf_req[CONF_5g], strlen(Conf_req[CONF_5g])))) {
|
||||
pconffile = CONFIG_FILE_5G;
|
||||
} else if (!(strncmp(pcmd+4, Conf_req[CONF_owe], strlen(Conf_req[CONF_owe])))) {
|
||||
pconffile = CONFIG_FILE_OWE;
|
||||
} else {
|
||||
pconffile = CONFIG_FILE;
|
||||
}
|
||||
@@ -3231,7 +3237,9 @@ int qsapsetSoftap(int argc, char *argv[])
|
||||
}
|
||||
|
||||
// check if 2nd arg is dual2g/dual5g
|
||||
if (argc > 2 && (strncmp(argv[2], Conf_req[CONF_2g], 4) == 0)) {
|
||||
if (argc > 2
|
||||
&& (strncmp(argv[2], Conf_req[CONF_2g], 4) == 0
|
||||
|| strncmp(argv[2], Conf_req[CONF_owe], 3) == 0)) {
|
||||
snprintf(setCmd, SET_BUF_LEN, "set %s", argv[2]);
|
||||
offset = 1;
|
||||
argc--;
|
||||
|
||||
Reference in New Issue
Block a user