Lines Matching refs:btif_hh_cb
111 btif_hh_cb_t btif_hh_cb; variable
333 if (btif_hh_cb.devices[i].dev_status == BTHH_CONN_STATE_CONNECTED && in btif_hh_find_connected_dev_by_handle()
334 btif_hh_cb.devices[i].dev_handle == handle) { in btif_hh_find_connected_dev_by_handle()
335 return &btif_hh_cb.devices[i]; in btif_hh_find_connected_dev_by_handle()
352 if (btif_hh_cb.devices[i].dev_status != BTHH_CONN_STATE_UNKNOWN && in btif_hh_find_dev_by_bda()
353 btif_hh_cb.devices[i].bd_addr == bd_addr) { in btif_hh_find_dev_by_bda()
354 return &btif_hh_cb.devices[i]; in btif_hh_find_dev_by_bda()
373 if (btif_hh_cb.devices[i].dev_status == BTHH_CONN_STATE_CONNECTED && in btif_hh_find_connected_dev_by_bda()
374 btif_hh_cb.devices[i].bd_addr == bd_addr) { in btif_hh_find_connected_dev_by_bda()
375 return &btif_hh_cb.devices[i]; in btif_hh_find_connected_dev_by_bda()
429 if (btif_hh_cb.added_devices[i].bd_addr == bda) { in btif_hh_add_added_dev()
435 if (btif_hh_cb.added_devices[i].bd_addr.IsEmpty()) { in btif_hh_add_added_dev()
437 btif_hh_cb.added_devices[i].bd_addr = bda; in btif_hh_add_added_dev()
438 btif_hh_cb.added_devices[i].dev_handle = BTA_HH_INVALID_HANDLE; in btif_hh_add_added_dev()
439 btif_hh_cb.added_devices[i].attr_mask = attr_mask; in btif_hh_add_added_dev()
464 p_added_dev = &btif_hh_cb.added_devices[i]; in btif_hh_remove_device()
489 if (btif_hh_cb.device_num > 0) { in btif_hh_remove_device()
490 btif_hh_cb.device_num--; in btif_hh_remove_device()
556 bd_addr->ToString().c_str(), btif_hh_cb.status); in btif_hh_virtual_unplug()
557 if ((btif_hh_cb.pending_conn_address == *bd_addr) && in btif_hh_virtual_unplug()
558 (btif_hh_cb.status == BTIF_HH_DEV_CONNECTING)) { in btif_hh_virtual_unplug()
559 btif_hh_cb.status = (BTIF_HH_STATUS)BTIF_HH_DEV_DISCONNECTED; in btif_hh_virtual_unplug()
560 btif_hh_cb.pending_conn_address = RawAddress::kEmpty; in btif_hh_virtual_unplug()
581 if (!dev && btif_hh_cb.device_num >= BTIF_HH_MAX_HID) { in btif_hh_connect()
590 if (btif_hh_cb.added_devices[i].bd_addr == *bd_addr) { in btif_hh_connect()
591 added_dev = &btif_hh_cb.added_devices[i]; in btif_hh_connect()
615 btif_hh_cb.status = BTIF_HH_DEV_CONNECTING; in btif_hh_connect()
616 btif_hh_cb.pending_conn_address = *bd_addr; in btif_hh_connect()
688 btif_hh_cb.service_dereg_active = TRUE; in btif_hh_service_registration()
734 btif_hh_cb.service_dereg_active); in btif_hh_upstreams_evt()
741 btif_hh_cb.status = BTIF_HH_ENABLED; in btif_hh_upstreams_evt()
746 btif_hh_cb.status = BTIF_HH_DISABLED; in btif_hh_upstreams_evt()
754 btif_hh_cb.status = BTIF_HH_DISABLED; in btif_hh_upstreams_evt()
755 if (btif_hh_cb.service_dereg_active) { in btif_hh_upstreams_evt()
758 btif_hh_cb.service_dereg_active = FALSE; in btif_hh_upstreams_evt()
764 alarm_free(btif_hh_cb.devices[i].vup_timer); in btif_hh_upstreams_evt()
766 memset(&btif_hh_cb, 0, sizeof(btif_hh_cb)); in btif_hh_upstreams_evt()
768 btif_hh_cb.devices[i].dev_status = BTHH_CONN_STATE_UNKNOWN; in btif_hh_upstreams_evt()
779 btif_hh_cb.pending_conn_address = RawAddress::kEmpty; in btif_hh_upstreams_evt()
786 btif_hh_cb.status = (BTIF_HH_STATUS)BTIF_HH_DEV_DISCONNECTED; in btif_hh_upstreams_evt()
800 btif_hh_cb.status = (BTIF_HH_STATUS)BTIF_HH_DEV_DISCONNECTED; in btif_hh_upstreams_evt()
808 btif_hh_cb.status = (BTIF_HH_STATUS)BTIF_HH_DEV_CONNECTED; in btif_hh_upstreams_evt()
813 btif_hh_cb.p_curr_dev = in btif_hh_upstreams_evt()
834 btif_hh_cb.status = (BTIF_HH_STATUS)BTIF_HH_DEV_DISCONNECTED; in btif_hh_upstreams_evt()
854 btif_hh_cb.status = (BTIF_HH_STATUS)BTIF_HH_DEV_DISCONNECTED; in btif_hh_upstreams_evt()
958 p_dev = btif_hh_cb.p_curr_dev; in btif_hh_upstreams_evt()
1045 if (btif_hh_cb.added_devices[i].bd_addr == p_data->dev_info.bda) { in btif_hh_upstreams_evt()
1047 btif_hh_cb.added_devices[i].dev_handle = p_data->dev_info.handle; in btif_hh_upstreams_evt()
1049 btif_hh_cb.added_devices[i].bd_addr = RawAddress::kEmpty; in btif_hh_upstreams_evt()
1050 btif_hh_cb.added_devices[i].dev_handle = BTA_HH_INVALID_HANDLE; in btif_hh_upstreams_evt()
1066 btif_hh_cb.status = (BTIF_HH_STATUS)BTIF_HH_DEV_DISCONNECTED; in btif_hh_upstreams_evt()
1225 memset(&btif_hh_cb, 0, sizeof(btif_hh_cb)); in init()
1227 btif_hh_cb.devices[i].dev_status = BTHH_CONN_STATE_UNKNOWN; in init()
1245 if (btif_hh_cb.status != BTIF_HH_DEV_CONNECTING) { in connect()
1267 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in disconnect()
1269 btif_hh_cb.status); in disconnect()
1295 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in virtual_unplug()
1296 BTIF_TRACE_ERROR("%s: Error, HH status = %d", __func__, btif_hh_cb.status); in virtual_unplug()
1324 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in get_idle_time()
1325 BTIF_TRACE_ERROR("%s: Error, HH status = %d", __func__, btif_hh_cb.status); in get_idle_time()
1351 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in set_idle_time()
1352 BTIF_TRACE_ERROR("%s: Error, HH status = %d", __func__, btif_hh_cb.status); in set_idle_time()
1387 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in set_info()
1388 BTIF_TRACE_ERROR("%s: Error, HH status = %d", __func__, btif_hh_cb.status); in set_info()
1428 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in get_protocol()
1429 BTIF_TRACE_ERROR("%s: Error, HH status = %d", __func__, btif_hh_cb.status); in get_protocol()
1458 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in set_protocol()
1459 BTIF_TRACE_ERROR("%s: Error, HH status = %d", __func__, btif_hh_cb.status); in set_protocol()
1498 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in get_report()
1499 BTIF_TRACE_ERROR("%s: Error, HH status = %d", __func__, btif_hh_cb.status); in get_report()
1535 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in set_report()
1536 BTIF_TRACE_ERROR("%s: Error, HH status = %d", __func__, btif_hh_cb.status); in set_report()
1589 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in send_data()
1590 BTIF_TRACE_ERROR("%s: Error, HH status = %d", __func__, btif_hh_cb.status); in send_data()
1641 if (btif_hh_cb.status == BTIF_HH_DISABLED) { in cleanup()
1643 __func__, btif_hh_cb.status); in cleanup()
1647 btif_hh_cb.status = BTIF_HH_DISABLING; in cleanup()
1650 btif_hh_cb.service_dereg_active = FALSE; in cleanup()
1655 p_dev = &btif_hh_cb.devices[i]; in cleanup()