Lines Matching refs:halInfo
362 hal_info *halInfo = NULL; variable
375 halInfo = (hal_info *)malloc(sizeof(hal_info)); in wifi_pre_initialize()
376 if (halInfo == NULL) { in wifi_pre_initialize()
381 memset(halInfo, 0, sizeof(*halInfo)); in wifi_pre_initialize()
384 if (socketpair(AF_UNIX, SOCK_STREAM, 0, halInfo->cleanup_socks) == -1) { in wifi_pre_initialize()
386 free(halInfo); in wifi_pre_initialize()
393 free(halInfo); in wifi_pre_initialize()
408 free(halInfo); in wifi_pre_initialize()
425 free(halInfo); in wifi_pre_initialize()
429 nl_cb_set(cb, NL_CB_SEQ_CHECK, NL_CB_CUSTOM, internal_no_seq_check, halInfo); in wifi_pre_initialize()
430 nl_cb_set(cb, NL_CB_VALID, NL_CB_CUSTOM, internal_valid_message_handler, halInfo); in wifi_pre_initialize()
433 halInfo->cmd_sock = cmd_sock; in wifi_pre_initialize()
434 halInfo->event_sock = event_sock; in wifi_pre_initialize()
435 halInfo->clean_up = false; in wifi_pre_initialize()
436 halInfo->in_event_loop = false; in wifi_pre_initialize()
438 halInfo->event_cb = (cb_info *)malloc(sizeof(cb_info) * DEFAULT_EVENT_CB_SIZE); in wifi_pre_initialize()
439 halInfo->alloc_event_cb = DEFAULT_EVENT_CB_SIZE; in wifi_pre_initialize()
440 halInfo->num_event_cb = 0; in wifi_pre_initialize()
442 halInfo->cmd = (cmd_info *)malloc(sizeof(cmd_info) * DEFAULT_CMD_SIZE); in wifi_pre_initialize()
443 halInfo->alloc_cmd = DEFAULT_CMD_SIZE; in wifi_pre_initialize()
444 halInfo->num_cmd = 0; in wifi_pre_initialize()
446 halInfo->nl80211_family_id = genl_ctrl_resolve(cmd_sock, "nl80211"); in wifi_pre_initialize()
447 if (halInfo->nl80211_family_id < 0) { in wifi_pre_initialize()
451 free(halInfo); in wifi_pre_initialize()
455 pthread_mutex_init(&halInfo->cb_lock, NULL); in wifi_pre_initialize()
458 handle = (wifi_handle) halInfo; in wifi_pre_initialize()
464 pthread_mutex_destroy(&halInfo->cb_lock); in wifi_pre_initialize()
465 free(halInfo); in wifi_pre_initialize()
476 pthread_mutex_destroy(&halInfo->cb_lock); in wifi_pre_initialize()
477 free(halInfo); in wifi_pre_initialize()
482 wlan0Handle = wifi_get_wlan_interface((wifi_handle)halInfo, ifaceHandles, numIfaceHandles); in wifi_pre_initialize()
510 if (halInfo == NULL) { in wifi_initialize()
520 *handle = (wifi_handle) halInfo; in wifi_initialize()
521 wlan0Handle = wifi_get_wlan_interface((wifi_handle)halInfo, ifaceHandles, numIfaceHandles); in wifi_initialize()