Home
last modified time | relevance | path

Searched refs:conn (Results 1 – 25 of 42) sorted by relevance

12

/system/bt/btif/co/
Dbta_pan_co.cc81 btpan_conn_t* conn = btpan_find_conn_addr(peer_addr); in bta_pan_co_open() local
82 if (conn == NULL) in bta_pan_co_open()
83 conn = btpan_new_conn(handle, peer_addr, local_role, peer_role); in bta_pan_co_open()
84 if (conn) { in bta_pan_co_open()
88 btpan_cb.tap_fd, btpan_cb.open_count, conn->handle, handle, in bta_pan_co_open()
89 conn->local_role, conn->remote_role); in bta_pan_co_open()
93 conn->handle = handle; in bta_pan_co_open()
101 conn->state = PAN_STATE_OPEN; in bta_pan_co_open()
120 btpan_conn_t* conn = btpan_find_conn_handle(handle); in bta_pan_co_close() local
121 if (conn && conn->state == PAN_STATE_OPEN) { in bta_pan_co_close()
[all …]
/system/bt/btif/src/
Dbtif_pan.cc108 static void btpan_cleanup_conn(btpan_conn_t* conn);
237 btpan_conn_t* conn = btpan_find_conn_addr(*bd_addr); in btif_in_pan_generic_evt() local
240 asrt(conn != NULL); in btif_in_pan_generic_evt()
241 if (conn) { in btif_in_pan_generic_evt()
242 btpan_conn_local_role = bta_role_to_btpan(conn->local_role); in btif_in_pan_generic_evt()
243 btpan_remote_role = bta_role_to_btpan(conn->remote_role); in btif_in_pan_generic_evt()
245 BT_STATUS_SUCCESS, &conn->peer, in btif_in_pan_generic_evt()
256 btpan_conn_t* conn = btpan_find_conn_addr(*bd_addr); in btpan_disconnect() local
257 if (conn && conn->handle >= 0) { in btpan_disconnect()
262 BTA_PanClose(conn->handle); in btpan_disconnect()
[all …]
Dbtif_hd.cc203 RawAddress* addr = (RawAddress*)&p_data->conn.bda; in btif_hd_upstreams_evt()
214 btif_storage_set_hidd((RawAddress*)&p_data->conn.bda); in btif_hd_upstreams_evt()
217 (RawAddress*)&p_data->conn.bda, BTHD_CONN_STATE_CONNECTED); in btif_hd_upstreams_evt()
222 RawAddress* addr = (RawAddress*)&p_data->conn.bda; in btif_hd_upstreams_evt()
229 (RawAddress*)&p_data->conn.bda, BTHD_CONN_STATE_DISCONNECTED); in btif_hd_upstreams_evt()
254 (RawAddress*)&p_data->conn.bda, BTHD_CONN_STATE_DISCONNECTED); in btif_hd_upstreams_evt()
255 if (bta_dm_check_if_only_hd_connected(p_data->conn.bda)) { in btif_hd_upstreams_evt()
258 BTA_DmRemoveDevice(p_data->conn.bda); in btif_hd_upstreams_evt()
260 RawAddress* bd_addr = (RawAddress*)&p_data->conn.bda; in btif_hd_upstreams_evt()
272 (RawAddress*)&p_data->conn.bda, in btif_hd_upstreams_evt()
[all …]
Dbtif_gatt_server.cc142 btif_gatt_check_encrypted_link(p_data->conn.remote_bda, in btapp_gatts_handle_cback()
143 p_data->conn.transport); in btapp_gatts_handle_cback()
145 HAL_CBACK(bt_gatt_callbacks, server->connection_cb, p_data->conn.conn_id, in btapp_gatts_handle_cback()
146 p_data->conn.server_if, true, p_data->conn.remote_bda); in btapp_gatts_handle_cback()
151 HAL_CBACK(bt_gatt_callbacks, server->connection_cb, p_data->conn.conn_id, in btapp_gatts_handle_cback()
152 p_data->conn.server_if, false, p_data->conn.remote_bda); in btapp_gatts_handle_cback()
Dbtif_hh.cc778 p_data->conn.handle, p_data->conn.status); in btif_hh_upstreams_evt()
780 if (p_data->conn.status == BTA_HH_OK) { in btif_hh_upstreams_evt()
781 p_dev = btif_hh_find_connected_dev_by_handle(p_data->conn.handle); in btif_hh_upstreams_evt()
785 p_data->conn.handle); in btif_hh_upstreams_evt()
790 BTA_HhClose(p_data->conn.handle); in btif_hh_upstreams_evt()
792 (RawAddress*)&p_data->conn.bda, in btif_hh_upstreams_evt()
797 p_dev->bd_addr = p_data->conn.bda; in btif_hh_upstreams_evt()
801 BTA_HhClose(p_data->conn.handle); in btif_hh_upstreams_evt()
806 p_data->conn.handle); in btif_hh_upstreams_evt()
807 p_dev->bd_addr = p_data->conn.bda; in btif_hh_upstreams_evt()
[all …]
/system/bt/stack/hid/
Dhidh_conn.cc114 hh_cb.devices[xx].conn.conn_state = HID_CONN_STATE_UNUSED; in hidh_conn_reg()
130 tHID_CONN* p_hcon = &hh_cb.devices[dhandle].conn; in hidh_conn_disconnect()
168 if (res == BTM_SUCCESS && p_dev->conn.conn_state == HID_CONN_STATE_SECURITY) { in hidh_sec_check_complete_term()
169 p_dev->conn.disc_reason = HID_SUCCESS; /* Authentication passed. Reset in hidh_sec_check_complete_term()
173 p_dev->conn.conn_state = HID_CONN_STATE_CONNECTING_INTR; in hidh_sec_check_complete_term()
176 L2CA_ConnectRsp(p_dev->addr, p_dev->conn.ctrl_id, p_dev->conn.ctrl_cid, in hidh_sec_check_complete_term()
180 L2CA_ConfigReq(p_dev->conn.ctrl_cid, &hh_cb.l2cap_cfg); in hidh_sec_check_complete_term()
185 p_dev->conn.disc_reason = in hidh_sec_check_complete_term()
187 p_dev->conn.conn_state = HID_CONN_STATE_UNUSED; in hidh_sec_check_complete_term()
188 L2CA_ConnectRsp(p_dev->addr, p_dev->conn.ctrl_id, p_dev->conn.ctrl_cid, in hidh_sec_check_complete_term()
[all …]
Dhidd_conn.cc83 p_hcon = &hd_cb.device.conn; in hidd_check_config_done()
117 if (res == BTM_SUCCESS && p_dev->conn.conn_state == HID_CONN_STATE_SECURITY) { in hidd_sec_check_complete()
118 p_dev->conn.disc_reason = HID_SUCCESS; in hidd_sec_check_complete()
119 p_dev->conn.conn_state = HID_CONN_STATE_CONNECTING_INTR; in hidd_sec_check_complete()
121 L2CA_ConnectRsp(p_dev->addr, p_dev->conn.ctrl_id, p_dev->conn.ctrl_cid, in hidd_sec_check_complete()
123 L2CA_ConfigReq(p_dev->conn.ctrl_cid, &hd_cb.l2cap_cfg); in hidd_sec_check_complete()
127 p_dev->conn.disc_reason = HID_ERR_AUTH_FAILED; in hidd_sec_check_complete()
128 p_dev->conn.conn_state = HID_CONN_STATE_UNUSED; in hidd_sec_check_complete()
129 L2CA_ConnectRsp(p_dev->addr, p_dev->conn.ctrl_id, p_dev->conn.ctrl_cid, in hidd_sec_check_complete()
150 if (p_dev->conn.conn_state != HID_CONN_STATE_SECURITY) { in hidd_sec_check_complete_orig()
[all …]
Dhidh_api.cc277 hh_cb.devices[i].conn.process_repage_timer = in HID_HostRegister()
299 alarm_free(hh_cb.devices[i].conn.process_repage_timer); in HID_HostDeregister()
368 hh_cb.devices[dev_handle].conn.conn_state = HID_CONN_STATE_UNUSED; in HID_HostRemoveDev()
369 hh_cb.devices[dev_handle].conn.ctrl_cid = in HID_HostRemoveDev()
370 hh_cb.devices[dev_handle].conn.intr_cid = 0; in HID_HostRemoveDev()
459 alarm_cancel(hh_cb.devices[dev_handle].conn.process_repage_timer); in HID_HostCloseDev()
Dhidd_api.cc450 hd_cb.device.conn.conn_state = HID_CONN_STATE_UNUSED; in HID_DevUnplugDevice()
451 hd_cb.device.conn.ctrl_cid = 0; in HID_DevUnplugDevice()
452 hd_cb.device.conn.intr_cid = 0; in HID_DevUnplugDevice()
503 if (hd_cb.device.conn.conn_state != HID_CONN_STATE_UNUSED) { in HID_DevDisconnect()
505 hd_cb.device.conn.conn_state = HID_CONN_STATE_UNUSED; in HID_DevDisconnect()
Dhidd_int.h41 tHID_CONN conn; member
Dhidh_int.h45 tHID_CONN conn; /* L2CAP channel info */ member
/system/bt/service/
Dgatt_server.cc208 for (const auto& conn : conn_iter->second) { in SendNotification() local
210 if (pending_indications_.find(conn->conn_id) != in SendNotification()
213 << " is already pending for connection: " << conn->conn_id; in SendNotification()
223 conn->conn_id, confirm, value); in SendNotification()
233 pending_indications_[conn->conn_id] = pending_ind; in SendNotification()
344 auto conn = GetConnection(conn_id, bda, trans_id); in RequestReadCharacteristicCallback() local
345 if (!conn) return; in RequestReadCharacteristicCallback()
354 conn->request_id_to_handle[trans_id] = attribute_handle; in RequestReadCharacteristicCallback()
377 auto conn = GetConnection(conn_id, bda, trans_id); in RequestReadDescriptorCallback() local
378 if (!conn) return; in RequestReadDescriptorCallback()
[all …]
/system/extras/simpleperf/
DUnixSocket_test.cpp110 std::unique_ptr<UnixSocketConnection> conn = server->AcceptConnection(); in TEST() local
111 ASSERT_TRUE(conn != nullptr); in TEST()
121 return conn->NoMoreMessage(); in TEST()
127 return conn->SendMessage(new_msg, true); in TEST()
130 ASSERT_TRUE(conn->PrepareForIO(loop, receive_message_callback, in TEST()
135 ASSERT_TRUE(conn->SendMessage(msg, true)); in TEST()
179 std::unique_ptr<UnixSocketConnection> conn = server->AcceptConnection(); in TEST() local
180 ASSERT_TRUE(conn != nullptr); in TEST()
194 if (!conn->SendMessage(new_msg, true)) { in TEST()
202 ASSERT_TRUE(conn->PrepareForIO(loop, receive_message_callback, in TEST()
Dinplace_sampler_lib.cpp62 SampleManager(std::unique_ptr<UnixSocketConnection> conn) : conn_(std::move(conn)), in SampleManager() argument
334 std::unique_ptr<UnixSocketConnection> conn = server->AcceptConnection(); in CommunicationThread() local
335 if (conn == nullptr) { in CommunicationThread()
338 SampleManager manager(std::move(conn)); in CommunicationThread()
/system/bt/stack/gap/
Dgap_conn.cc81 tGAP_CONN conn; variable
117 memset(&conn, 0, sizeof(tGAP_CONN)); in gap_conn_init()
118 conn.reg_info.pL2CA_ConnectInd_Cb = gap_connect_ind; in gap_conn_init()
119 conn.reg_info.pL2CA_ConnectCfm_Cb = gap_connect_cfm; in gap_conn_init()
120 conn.reg_info.pL2CA_ConnectPnd_Cb = NULL; in gap_conn_init()
121 conn.reg_info.pL2CA_ConfigInd_Cb = gap_config_ind; in gap_conn_init()
122 conn.reg_info.pL2CA_ConfigCfm_Cb = gap_config_cfm; in gap_conn_init()
123 conn.reg_info.pL2CA_DisconnectInd_Cb = gap_disconnect_ind; in gap_conn_init()
124 conn.reg_info.pL2CA_DisconnectCfm_Cb = NULL; in gap_conn_init()
125 conn.reg_info.pL2CA_QoSViolationInd_Cb = NULL; in gap_conn_init()
[all …]
/system/bt/bta/hh/
Dbta_hh_act.cc523 tBTA_HH_CONN conn; in bta_hh_open_cmpl_act() local
527 memset((void*)&conn, 0, sizeof(tBTA_HH_CONN)); in bta_hh_open_cmpl_act()
528 conn.handle = dev_handle; in bta_hh_open_cmpl_act()
529 conn.bda = p_cb->addr; in bta_hh_open_cmpl_act()
539 conn.status = p_cb->status; in bta_hh_open_cmpl_act()
540 conn.le_hid = p_cb->is_le_device; in bta_hh_open_cmpl_act()
541 conn.scps_supported = p_cb->scps_supported; in bta_hh_open_cmpl_act()
559 conn.status = BTA_HH_ERR_PROTO; in bta_hh_open_cmpl_act()
560 (*bta_hh_cb.p_cback)(BTA_HH_OPEN_EVT, (tBTA_HH*)&conn); in bta_hh_open_cmpl_act()
562 conn.status = BTA_HH_OK; in bta_hh_open_cmpl_act()
[all …]
Dbta_hh_main.cc252 cback_data.conn.bda = ((tBTA_HH_API_CONN*)p_data)->bd_addr; in bta_hh_sm_execute()
253 cback_data.conn.status = BTA_HH_ERR_DB_FULL; in bta_hh_sm_execute()
254 cback_data.conn.handle = BTA_HH_INVALID_HANDLE; in bta_hh_sm_execute()
/system/core/adb/
Dtest_adb.py73 conn, _ = ready.accept()
74 rlist.append(conn)
323 with contextlib.closing(accepted_connection) as conn:
326 conn.sendall(("Android Console: type 'help' for a list "
328 conn.sendall(b"OK\r\n")
330 with contextlib.closing(conn.makefile()) as connf:
338 conn.sendall(b"OK: killing emulator, bye bye\r\n")
346 self._reset_socket_on_close(conn)
/system/bt/bta/hf_client/
Dbta_hf_client_act.cc299 evt.conn.bd_addr = client_cb->peer_addr; in bta_hf_client_rfc_close()
453 evt.conn.bd_addr = client_cb->peer_addr; in bta_hf_client_svc_conn_open()
454 evt.conn.peer_feat = client_cb->peer_features; in bta_hf_client_svc_conn_open()
455 evt.conn.chld_feat = client_cb->chld_features; in bta_hf_client_svc_conn_open()
/system/bt/bta/hd/
Dbta_hd_act.cc295 cback_data.conn.bda = p_ctrl->addr; in bta_hd_connect_act()
296 cback_data.conn.status = BTHD_CONN_STATE_CONNECTING; in bta_hd_connect_act()
323 if (HID_DevGetDevice(&cback_data.conn.bda) == HID_SUCCESS) { in bta_hd_disconnect_act()
324 cback_data.conn.status = BTHD_CONN_STATE_DISCONNECTING; in bta_hd_disconnect_act()
459 cback_data.conn.bda = p_cback->addr; in bta_hd_open_act()
489 cback_data.conn.bda = p_cback->addr; in bta_hd_close_act()
672 cback_data.conn.bda = p_cback->addr; in bta_hd_vc_unplug_done_act()
/system/nfc/src/nfa/include/
Dnfa_snep_int.h185 tNFA_SNEP_CONN conn[NFA_SNEP_MAX_CONN]; member
205 conn[NFA_SNEP_DEFAULT_MAX_CONN]; /* connections for default server */ member
/system/bt/profile/avrcp/tests/
Davrcp_connection_handler_test.cc106 ASSERT_EQ(conn_cb.conn, 1); in TEST_F()
181 ASSERT_EQ(conn_cb.conn, 1); in TEST_F()
331 ASSERT_EQ(conn_cb.conn, 1); in TEST_F()
430 ASSERT_EQ(conn_cb.conn, 0); in TEST_F()
475 ASSERT_EQ(conn_cb.conn, 0); in TEST_F()
/system/bt/bta/gatt/
Dbta_gatts_act.cc613 cb_data.conn.conn_id = conn_id; in bta_gatts_conn_cback()
614 cb_data.conn.server_if = gatt_if; in bta_gatts_conn_cback()
615 cb_data.conn.reason = reason; in bta_gatts_conn_cback()
616 cb_data.conn.transport = transport; in bta_gatts_conn_cback()
617 cb_data.conn.remote_bda = bdaddr; in bta_gatts_conn_cback()
/system/bt/bta/dm/
Dbta_dm_act.cc2658 tBTA_DM_SEC conn; in send_busy_level_update() local
2659 memset(&conn, 0, sizeof(tBTA_DM_SEC)); in send_busy_level_update()
2660 conn.busy_level.level = busy_level; in send_busy_level_update()
2661 conn.busy_level.level_flags = busy_level_flags; in send_busy_level_update()
2662 bta_dm_cb.p_sec_cback(BTA_DM_BUSY_LEVEL_EVT, &conn); in send_busy_level_update()
2667 tBTA_DM_SEC conn; in handle_role_change() local
2668 memset(&conn, 0, sizeof(tBTA_DM_SEC)); in handle_role_change()
2704 conn.role_chg.bd_addr = bd_addr; in handle_role_change()
2705 conn.role_chg.new_role = (uint8_t)new_role; in handle_role_change()
2706 if (bta_dm_cb.p_sec_cback) bta_dm_cb.p_sec_cback(BTA_DM_ROLE_CHG_EVT, &conn); in handle_role_change()
[all …]
/system/bt/bta/include/
Dbta_hd_api.h117 tBTA_HD_CONN conn; /* BTA_HD_OPEN_EVT member

12