Lines Matching refs:gas
32 struct gas_server *gas; member
89 gas_server_send_resp(struct gas_server *gas, struct gas_server_handler *handler, in gas_server_send_resp() argument
155 dl_list_add(&gas->responses, &response->list); in gas_server_send_resp()
156 gas->tx(gas->ctx, freq, da, resp, comeback_delay ? 2000 : 0); in gas_server_send_resp()
164 gas_server_rx_initial_req(struct gas_server *gas, const u8 *da, const u8 *sa, in gas_server_rx_initial_req() argument
224 dl_list_for_each(handler, &gas->handlers, struct gas_server_handler, in gas_server_rx_initial_req()
243 gas_server_send_resp(gas, handler, response, sa, freq, in gas_server_rx_initial_req()
259 struct gas_server *gas = handler->gas; in gas_server_handle_rx_comeback_req() local
329 gas->tx(gas->ctx, response->freq, response->dst, resp, wait_time); in gas_server_handle_rx_comeback_req()
335 gas_server_rx_comeback_req(struct gas_server *gas, const u8 *da, const u8 *sa, in gas_server_rx_comeback_req() argument
340 dl_list_for_each(response, &gas->responses, struct gas_server_response, in gas_server_rx_comeback_req()
367 int gas_server_rx(struct gas_server *gas, const u8 *da, const u8 *sa, in gas_server_rx() argument
374 if (!gas || len < 2) in gas_server_rx()
397 return gas_server_rx_initial_req(gas, da, sa, bssid, in gas_server_rx()
400 return gas_server_rx_comeback_req(gas, da, sa, bssid, in gas_server_rx()
436 void gas_server_tx_status(struct gas_server *gas, const u8 *dst, const u8 *data, in gas_server_tx_status() argument
458 dl_list_for_each(response, &gas->responses, struct gas_server_response, in gas_server_tx_status()
471 int gas_server_set_resp(struct gas_server *gas, void *resp_ctx, in gas_server_set_resp() argument
476 dl_list_for_each(tmp, &gas->responses, struct gas_server_response, in gas_server_set_resp()
492 bool gas_server_response_sent(struct gas_server *gas, void *resp_ctx) in gas_server_response_sent() argument
496 dl_list_for_each(tmp, &gas->responses, struct gas_server_response, in gas_server_response_sent()
513 struct gas_server *gas; in gas_server_init() local
515 gas = os_zalloc(sizeof(*gas)); in gas_server_init()
516 if (!gas) in gas_server_init()
518 gas->ctx = ctx; in gas_server_init()
519 gas->tx = tx; in gas_server_init()
520 dl_list_init(&gas->handlers); in gas_server_init()
521 dl_list_init(&gas->responses); in gas_server_init()
522 return gas; in gas_server_init()
526 void gas_server_deinit(struct gas_server *gas) in gas_server_deinit() argument
531 if (!gas) in gas_server_deinit()
534 dl_list_for_each_safe(handler, tmp, &gas->handlers, in gas_server_deinit()
540 dl_list_for_each_safe(response, tmp_r, &gas->responses, in gas_server_deinit()
546 os_free(gas); in gas_server_deinit()
550 int gas_server_register(struct gas_server *gas, in gas_server_register() argument
562 if (!gas || adv_proto_id_len > MAX_ADV_PROTO_ID_LEN) in gas_server_register()
573 handler->gas = gas; in gas_server_register()
574 dl_list_add(&gas->handlers, &handler->list); in gas_server_register()