Lines Matching full:ctrl
48 static void update_stations(struct wpa_ctrl *ctrl);
82 static void register_event_handler(struct wpa_ctrl *ctrl) in register_event_handler() argument
88 !eloop_register_read_sock(wpa_ctrl_get_fd(ctrl), in register_event_handler()
95 static void unregister_event_handler(struct wpa_ctrl *ctrl) in unregister_event_handler() argument
100 eloop_unregister_read_sock(wpa_ctrl_get_fd(ctrl)); in unregister_event_handler()
193 static int _wpa_ctrl_command(struct wpa_ctrl *ctrl, const char *cmd, int print) in _wpa_ctrl_command() argument
204 ret = wpa_ctrl_request(ctrl, cmd, strlen(cmd), buf, &len, in _wpa_ctrl_command()
221 static inline int wpa_ctrl_command(struct wpa_ctrl *ctrl, const char *cmd) in wpa_ctrl_command() argument
223 return _wpa_ctrl_command(ctrl, cmd, 1); in wpa_ctrl_command()
227 static int hostapd_cli_cmd(struct wpa_ctrl *ctrl, const char *cmd, in hostapd_cli_cmd() argument
239 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd()
243 static int hostapd_cli_cmd_ping(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_ping() argument
245 return wpa_ctrl_command(ctrl, "PING"); in hostapd_cli_cmd_ping()
249 static int hostapd_cli_cmd_relog(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_relog() argument
251 return wpa_ctrl_command(ctrl, "RELOG"); in hostapd_cli_cmd_relog()
255 static int hostapd_cli_cmd_close_log(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_close_log() argument
258 return wpa_ctrl_command(ctrl, "CLOSE_LOG"); in hostapd_cli_cmd_close_log()
262 static int hostapd_cli_cmd_status(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_status() argument
265 return wpa_ctrl_command(ctrl, "STATUS-DRIVER"); in hostapd_cli_cmd_status()
266 return wpa_ctrl_command(ctrl, "STATUS"); in hostapd_cli_cmd_status()
270 static int hostapd_cli_cmd_mib(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_mib() argument
275 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_mib()
277 return wpa_ctrl_command(ctrl, "MIB"); in hostapd_cli_cmd_mib()
323 static int hostapd_cli_cmd_sta(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_sta() argument
335 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_sta()
354 static int hostapd_cli_cmd_new_sta(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_new_sta() argument
364 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_new_sta()
368 static int hostapd_cli_cmd_deauthenticate(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_deauthenticate() argument
382 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_deauthenticate()
386 static int hostapd_cli_cmd_disassociate(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_disassociate() argument
400 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_disassociate()
405 static int hostapd_cli_cmd_signature(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_signature() argument
415 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_signature()
420 static int hostapd_cli_cmd_sa_query(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_sa_query() argument
430 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_sa_query()
435 static int hostapd_cli_cmd_wps_pin(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_wps_pin() argument
452 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_wps_pin()
456 static int hostapd_cli_cmd_wps_check_pin(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_wps_check_pin() argument
478 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_wps_check_pin()
482 static int hostapd_cli_cmd_wps_pbc(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_wps_pbc() argument
485 return wpa_ctrl_command(ctrl, "WPS_PBC"); in hostapd_cli_cmd_wps_pbc()
489 static int hostapd_cli_cmd_wps_cancel(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_wps_cancel() argument
492 return wpa_ctrl_command(ctrl, "WPS_CANCEL"); in hostapd_cli_cmd_wps_cancel()
497 static int hostapd_cli_cmd_wps_nfc_tag_read(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_wps_nfc_tag_read() argument
516 ret = wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_wps_nfc_tag_read()
523 static int hostapd_cli_cmd_wps_nfc_config_token(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_wps_nfc_config_token() argument
541 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_wps_nfc_config_token()
545 static int hostapd_cli_cmd_wps_nfc_token(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_wps_nfc_token() argument
562 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_wps_nfc_token()
566 static int hostapd_cli_cmd_nfc_get_handover_sel(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_nfc_get_handover_sel() argument
584 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_nfc_get_handover_sel()
590 static int hostapd_cli_cmd_wps_ap_pin(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_wps_ap_pin() argument
607 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_wps_ap_pin()
611 static int hostapd_cli_cmd_wps_get_status(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_wps_get_status() argument
614 return wpa_ctrl_command(ctrl, "WPS_GET_STATUS"); in hostapd_cli_cmd_wps_get_status()
618 static int hostapd_cli_cmd_wps_config(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_wps_config() argument
658 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_wps_config()
663 static int hostapd_cli_cmd_disassoc_imminent(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_disassoc_imminent() argument
679 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_disassoc_imminent()
683 static int hostapd_cli_cmd_ess_disassoc(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_ess_disassoc() argument
699 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_ess_disassoc()
703 static int hostapd_cli_cmd_bss_tm_req(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_bss_tm_req() argument
726 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_bss_tm_req()
730 static int hostapd_cli_cmd_get_config(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_get_config() argument
733 return wpa_ctrl_command(ctrl, "GET_CONFIG"); in hostapd_cli_cmd_get_config()
737 static int wpa_ctrl_command_sta(struct wpa_ctrl *ctrl, const char *cmd, in wpa_ctrl_command_sta() argument
749 ret = wpa_ctrl_request(ctrl, cmd, strlen(cmd), buf, &len, in wpa_ctrl_command_sta()
774 static int hostapd_cli_cmd_all_sta(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_all_sta() argument
779 if (wpa_ctrl_command_sta(ctrl, "STA-FIRST", addr, sizeof(addr), 1)) in hostapd_cli_cmd_all_sta()
783 } while (wpa_ctrl_command_sta(ctrl, cmd, addr, sizeof(addr), 1) == 0); in hostapd_cli_cmd_all_sta()
789 static int hostapd_cli_cmd_list_sta(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_list_sta() argument
794 if (wpa_ctrl_command_sta(ctrl, "STA-FIRST", addr, sizeof(addr), 0)) in hostapd_cli_cmd_list_sta()
800 } while (wpa_ctrl_command_sta(ctrl, cmd, addr, sizeof(addr), 0) == 0); in hostapd_cli_cmd_list_sta()
806 static int hostapd_cli_cmd_help(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_help() argument
828 static int hostapd_cli_cmd_license(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_license() argument
836 static int hostapd_cli_cmd_set_qos_map_set(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_set_qos_map_set() argument
852 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_set_qos_map_set()
856 static int hostapd_cli_cmd_send_qos_map_conf(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_send_qos_map_conf() argument
871 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_send_qos_map_conf()
875 static int hostapd_cli_cmd_hs20_wnm_notif(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_hs20_wnm_notif() argument
891 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_hs20_wnm_notif()
895 static int hostapd_cli_cmd_hs20_deauth_req(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_hs20_deauth_req() argument
916 return wpa_ctrl_command(ctrl, buf); in hostapd_cli_cmd_hs20_deauth_req()
920 static int hostapd_cli_cmd_quit(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_quit() argument
929 static int hostapd_cli_cmd_level(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_level() argument
938 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_level()
942 static void update_stations(struct wpa_ctrl *ctrl) in update_stations() argument
946 if (!ctrl || !interactive) in update_stations()
951 if (wpa_ctrl_command_sta(ctrl, "STA-FIRST", addr, sizeof(addr), 0)) in update_stations()
957 } while (wpa_ctrl_command_sta(ctrl, cmd, addr, sizeof(addr), 0) == 0); in update_stations()
961 static void hostapd_cli_get_interfaces(struct wpa_ctrl *ctrl, in hostapd_cli_get_interfaces() argument
967 if (!ctrl || !interfaces) in hostapd_cli_get_interfaces()
983 static void hostapd_cli_list_interfaces(struct wpa_ctrl *ctrl) in hostapd_cli_list_interfaces() argument
1006 static int hostapd_cli_cmd_interface(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_interface() argument
1010 hostapd_cli_list_interfaces(ctrl); in hostapd_cli_cmd_interface()
1039 static int hostapd_cli_cmd_set(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_set() argument
1055 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_set()
1097 static int hostapd_cli_cmd_get(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_get() argument
1113 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_get()
1143 static int hostapd_cli_cmd_fst(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_fst() argument
1166 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_fst()
1172 static int hostapd_cli_cmd_color_change(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_color_change() argument
1175 return hostapd_cli_cmd(ctrl, "COLOR_CHANGE", 1, argc, argv); in hostapd_cli_cmd_color_change()
1180 static int hostapd_cli_cmd_chan_switch(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_chan_switch() argument
1215 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_chan_switch()
1219 static int hostapd_cli_cmd_notify_cw_change(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_notify_cw_change() argument
1222 return hostapd_cli_cmd(ctrl, "NOTIFY_CW_CHANGE", 1, argc, argv); in hostapd_cli_cmd_notify_cw_change()
1226 static int hostapd_cli_cmd_enable(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_enable() argument
1229 return wpa_ctrl_command(ctrl, "ENABLE"); in hostapd_cli_cmd_enable()
1233 static int hostapd_cli_cmd_reload(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_reload() argument
1236 return wpa_ctrl_command(ctrl, "RELOAD"); in hostapd_cli_cmd_reload()
1240 static int hostapd_cli_cmd_reload_bss(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_reload_bss() argument
1243 return wpa_ctrl_command(ctrl, "RELOAD_BSS"); in hostapd_cli_cmd_reload_bss()
1247 static int hostapd_cli_cmd_reload_config(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_reload_config() argument
1250 return wpa_ctrl_command(ctrl, "RELOAD_CONFIG"); in hostapd_cli_cmd_reload_config()
1254 static int hostapd_cli_cmd_disable(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_disable() argument
1257 return wpa_ctrl_command(ctrl, "DISABLE"); in hostapd_cli_cmd_disable()
1261 static int hostapd_cli_cmd_enable_mld(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_enable_mld() argument
1264 return wpa_ctrl_command(ctrl, "ENABLE_MLD"); in hostapd_cli_cmd_enable_mld()
1268 static int hostapd_cli_cmd_disable_mld(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_disable_mld() argument
1271 return wpa_ctrl_command(ctrl, "DISABLE_MLD"); in hostapd_cli_cmd_disable_mld()
1275 static int hostapd_cli_cmd_update_beacon(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_update_beacon() argument
1278 return wpa_ctrl_command(ctrl, "UPDATE_BEACON"); in hostapd_cli_cmd_update_beacon()
1282 static int hostapd_cli_cmd_stop_ap(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_stop_ap() argument
1285 return wpa_ctrl_command(ctrl, "STOP_AP"); in hostapd_cli_cmd_stop_ap()
1289 static int hostapd_cli_cmd_vendor(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_vendor() argument
1307 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_vendor()
1311 static int hostapd_cli_cmd_erp_flush(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_erp_flush() argument
1314 return wpa_ctrl_command(ctrl, "ERP_FLUSH"); in hostapd_cli_cmd_erp_flush()
1318 static int hostapd_cli_cmd_log_level(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_log_level() argument
1333 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_log_level()
1337 static int hostapd_cli_cmd_raw(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_raw() argument
1341 return hostapd_cli_cmd(ctrl, argv[0], 0, argc - 1, &argv[1]); in hostapd_cli_cmd_raw()
1345 static int hostapd_cli_cmd_pmksa(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_pmksa() argument
1347 return wpa_ctrl_command(ctrl, "PMKSA"); in hostapd_cli_cmd_pmksa()
1351 static int hostapd_cli_cmd_pmksa_flush(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_pmksa_flush() argument
1354 return wpa_ctrl_command(ctrl, "PMKSA_FLUSH"); in hostapd_cli_cmd_pmksa_flush()
1358 static int hostapd_cli_cmd_set_neighbor(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_set_neighbor() argument
1376 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_set_neighbor()
1380 static int hostapd_cli_cmd_show_neighbor(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_show_neighbor() argument
1383 return wpa_ctrl_command(ctrl, "SHOW_NEIGHBOR"); in hostapd_cli_cmd_show_neighbor()
1387 static int hostapd_cli_cmd_remove_neighbor(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_remove_neighbor() argument
1390 return hostapd_cli_cmd(ctrl, "REMOVE_NEIGHBOR", 1, argc, argv); in hostapd_cli_cmd_remove_neighbor()
1394 static int hostapd_cli_cmd_req_lci(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_req_lci() argument
1410 return wpa_ctrl_command(ctrl, cmd); in hostapd_cli_cmd_req_lci()
1414 static int hostapd_cli_cmd_req_range(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_req_range() argument
1422 return hostapd_cli_cmd(ctrl, "REQ_RANGE", 4, argc, argv); in hostapd_cli_cmd_req_range()
1426 static int hostapd_cli_cmd_driver_flags(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_driver_flags() argument
1429 return wpa_ctrl_command(ctrl, "DRIVER_FLAGS"); in hostapd_cli_cmd_driver_flags()
1433 static int hostapd_cli_cmd_driver_flags2(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_driver_flags2() argument
1436 return wpa_ctrl_command(ctrl, "DRIVER_FLAGS2"); in hostapd_cli_cmd_driver_flags2()
1442 static int hostapd_cli_cmd_dpp_qr_code(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_qr_code() argument
1445 return hostapd_cli_cmd(ctrl, "DPP_QR_CODE", 1, argc, argv); in hostapd_cli_cmd_dpp_qr_code()
1449 static int hostapd_cli_cmd_dpp_bootstrap_gen(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_bootstrap_gen() argument
1452 return hostapd_cli_cmd(ctrl, "DPP_BOOTSTRAP_GEN", 1, argc, argv); in hostapd_cli_cmd_dpp_bootstrap_gen()
1456 static int hostapd_cli_cmd_dpp_bootstrap_remove(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_bootstrap_remove() argument
1459 return hostapd_cli_cmd(ctrl, "DPP_BOOTSTRAP_REMOVE", 1, argc, argv); in hostapd_cli_cmd_dpp_bootstrap_remove()
1463 static int hostapd_cli_cmd_dpp_bootstrap_get_uri(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_dpp_bootstrap_get_uri() argument
1466 return hostapd_cli_cmd(ctrl, "DPP_BOOTSTRAP_GET_URI", 1, argc, argv); in hostapd_cli_cmd_dpp_bootstrap_get_uri()
1470 static int hostapd_cli_cmd_dpp_bootstrap_info(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_bootstrap_info() argument
1473 return hostapd_cli_cmd(ctrl, "DPP_BOOTSTRAP_INFO", 1, argc, argv); in hostapd_cli_cmd_dpp_bootstrap_info()
1477 static int hostapd_cli_cmd_dpp_bootstrap_set(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_bootstrap_set() argument
1480 return hostapd_cli_cmd(ctrl, "DPP_BOOTSTRAP_SET", 1, argc, argv); in hostapd_cli_cmd_dpp_bootstrap_set()
1484 static int hostapd_cli_cmd_dpp_auth_init(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_auth_init() argument
1487 return hostapd_cli_cmd(ctrl, "DPP_AUTH_INIT", 1, argc, argv); in hostapd_cli_cmd_dpp_auth_init()
1491 static int hostapd_cli_cmd_dpp_listen(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_listen() argument
1494 return hostapd_cli_cmd(ctrl, "DPP_LISTEN", 1, argc, argv); in hostapd_cli_cmd_dpp_listen()
1498 static int hostapd_cli_cmd_dpp_stop_listen(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_stop_listen() argument
1501 return wpa_ctrl_command(ctrl, "DPP_STOP_LISTEN"); in hostapd_cli_cmd_dpp_stop_listen()
1505 static int hostapd_cli_cmd_dpp_configurator_add(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_configurator_add() argument
1508 return hostapd_cli_cmd(ctrl, "DPP_CONFIGURATOR_ADD", 0, argc, argv); in hostapd_cli_cmd_dpp_configurator_add()
1512 static int hostapd_cli_cmd_dpp_configurator_remove(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_dpp_configurator_remove() argument
1515 return hostapd_cli_cmd(ctrl, "DPP_CONFIGURATOR_REMOVE", 1, argc, argv); in hostapd_cli_cmd_dpp_configurator_remove()
1519 static int hostapd_cli_cmd_dpp_configurator_get_key(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_dpp_configurator_get_key() argument
1522 return hostapd_cli_cmd(ctrl, "DPP_CONFIGURATOR_GET_KEY", 1, argc, argv); in hostapd_cli_cmd_dpp_configurator_get_key()
1526 static int hostapd_cli_cmd_dpp_configurator_sign(struct wpa_ctrl *ctrl, in hostapd_cli_cmd_dpp_configurator_sign() argument
1529 return hostapd_cli_cmd(ctrl, "DPP_CONFIGURATOR_SIGN", 1, argc, argv); in hostapd_cli_cmd_dpp_configurator_sign()
1533 static int hostapd_cli_cmd_dpp_pkex_add(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_pkex_add() argument
1536 return hostapd_cli_cmd(ctrl, "DPP_PKEX_ADD", 1, argc, argv); in hostapd_cli_cmd_dpp_pkex_add()
1540 static int hostapd_cli_cmd_dpp_pkex_remove(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_pkex_remove() argument
1543 return hostapd_cli_cmd(ctrl, "DPP_PKEX_REMOVE", 1, argc, argv); in hostapd_cli_cmd_dpp_pkex_remove()
1549 static int hostapd_cli_cmd_dpp_controller_start(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_controller_start() argument
1552 return hostapd_cli_cmd(ctrl, "DPP_CONTROLLER_START", 0, argc, argv); in hostapd_cli_cmd_dpp_controller_start()
1556 static int hostapd_cli_cmd_dpp_controller_stop(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_controller_stop() argument
1559 return wpa_ctrl_command(ctrl, "DPP_CONTROLLER_STOP"); in hostapd_cli_cmd_dpp_controller_stop()
1563 static int hostapd_cli_cmd_dpp_chirp(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_chirp() argument
1566 return hostapd_cli_cmd(ctrl, "DPP_CHIRP", 1, argc, argv); in hostapd_cli_cmd_dpp_chirp()
1570 static int hostapd_cli_cmd_dpp_stop_chirp(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_stop_chirp() argument
1573 return wpa_ctrl_command(ctrl, "DPP_STOP_CHIRP"); in hostapd_cli_cmd_dpp_stop_chirp()
1580 static int hostapd_cli_cmd_dpp_push_button(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_dpp_push_button() argument
1583 return hostapd_cli_cmd(ctrl, "DPP_PUSH_BUTTON", 0, argc, argv); in hostapd_cli_cmd_dpp_push_button()
1589 static int hostapd_cli_cmd_accept_macacl(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_accept_macacl() argument
1592 return hostapd_cli_cmd(ctrl, "ACCEPT_ACL", 1, argc, argv); in hostapd_cli_cmd_accept_macacl()
1596 static int hostapd_cli_cmd_deny_macacl(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_deny_macacl() argument
1599 return hostapd_cli_cmd(ctrl, "DENY_ACL", 1, argc, argv); in hostapd_cli_cmd_deny_macacl()
1603 static int hostapd_cli_cmd_poll_sta(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_poll_sta() argument
1606 return hostapd_cli_cmd(ctrl, "POLL_STA", 1, argc, argv); in hostapd_cli_cmd_poll_sta()
1610 static int hostapd_cli_cmd_req_beacon(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_req_beacon() argument
1613 return hostapd_cli_cmd(ctrl, "REQ_BEACON", 2, argc, argv); in hostapd_cli_cmd_req_beacon()
1617 static int hostapd_cli_cmd_req_link_measurement(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_req_link_measurement() argument
1620 return hostapd_cli_cmd(ctrl, "REQ_LINK_MEASUREMENT", 1, argc, argv); in hostapd_cli_cmd_req_link_measurement()
1624 static int hostapd_cli_cmd_reload_wpa_psk(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_reload_wpa_psk() argument
1627 return wpa_ctrl_command(ctrl, "RELOAD_WPA_PSK"); in hostapd_cli_cmd_reload_wpa_psk()
1633 static int hostapd_cli_cmd_get_rxkhs(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_get_rxkhs() argument
1636 return wpa_ctrl_command(ctrl, "GET_RXKHS"); in hostapd_cli_cmd_get_rxkhs()
1640 static int hostapd_cli_cmd_reload_rxkhs(struct wpa_ctrl *ctrl, int argc, in hostapd_cli_cmd_reload_rxkhs() argument
1643 return wpa_ctrl_command(ctrl, "RELOAD_RXKHS"); in hostapd_cli_cmd_reload_rxkhs()
1650 static int hostapd_cli_cmd_driver(struct wpa_ctrl *ctrl, int argc, char *argv[]) in hostapd_cli_cmd_driver() argument
1652 return hostapd_cli_cmd(ctrl, "DRIVER", 1, argc, argv); in hostapd_cli_cmd_driver()
1659 int (*handler)(struct wpa_ctrl *ctrl, int argc, char *argv[]);
1922 static void wpa_request(struct wpa_ctrl *ctrl, int argc, char *argv[]) in wpa_request() argument
1956 match->handler(ctrl, argc - 1, &argv[1]); in wpa_request()
1989 static void hostapd_cli_recv_pending(struct wpa_ctrl *ctrl, int in_read, in hostapd_cli_recv_pending() argument
1995 while (wpa_ctrl_pending(ctrl)) { in hostapd_cli_recv_pending()
1998 if (wpa_ctrl_recv(ctrl, buf, &len) == 0) { in hostapd_cli_recv_pending()
2168 struct wpa_ctrl *ctrl = eloop_ctx; in hostapd_cli_action_ping() local
2174 if (wpa_ctrl_request(ctrl, "PING", 4, buf, &len, in hostapd_cli_action_ping()
2182 ctrl, NULL); in hostapd_cli_action_ping()
2189 struct wpa_ctrl *ctrl = eloop_ctx; in hostapd_cli_action_receive() local
2191 hostapd_cli_recv_pending(ctrl, 0, 1); in hostapd_cli_action_receive()
2195 static void hostapd_cli_action(struct wpa_ctrl *ctrl) in hostapd_cli_action() argument
2199 fd = wpa_ctrl_get_fd(ctrl); in hostapd_cli_action()
2201 ctrl, NULL); in hostapd_cli_action()
2202 eloop_register_read_sock(fd, hostapd_cli_action_receive, ctrl, NULL); in hostapd_cli_action()
2204 eloop_cancel_timeout(hostapd_cli_action_ping, ctrl, NULL); in hostapd_cli_action()