Lines Matching refs:conn

1627 		if (p->conn) {  in hci_pend_le_actions_clear()
1628 hci_conn_drop(p->conn); in hci_pend_le_actions_clear()
1629 hci_conn_put(p->conn); in hci_pend_le_actions_clear()
1630 p->conn = NULL; in hci_pend_le_actions_clear()
2313 static bool hci_persistent_key(struct hci_dev *hdev, struct hci_conn *conn, in hci_persistent_key() argument
2329 if (!conn) in hci_persistent_key()
2333 if (conn->type == LE_LINK) in hci_persistent_key()
2337 if (conn->auth_type > 0x01 && conn->remote_auth > 0x01) in hci_persistent_key()
2341 if (conn->auth_type == 0x02 || conn->auth_type == 0x03) in hci_persistent_key()
2345 if (conn->remote_auth == 0x02 || conn->remote_auth == 0x03) in hci_persistent_key()
2427 struct link_key *hci_add_link_key(struct hci_dev *hdev, struct hci_conn *conn, in hci_add_link_key() argument
2439 old_key_type = conn ? conn->key_type : 0xff; in hci_add_link_key()
2452 (!conn || conn->remote_auth == 0xff) && old_key_type == 0xff) { in hci_add_link_key()
2454 if (conn) in hci_add_link_key()
2455 conn->key_type = type; in hci_add_link_key()
2468 *persistent = hci_persistent_key(hdev, conn, type, in hci_add_link_key()
2976 if (params->conn) { in hci_conn_params_free()
2977 hci_conn_drop(params->conn); in hci_conn_params_free()
2978 hci_conn_put(params->conn); in hci_conn_params_free()
3712 struct hci_conn *conn = chan->conn; in hci_queue_acl() local
3713 struct hci_dev *hdev = conn->hdev; in hci_queue_acl()
3723 hci_add_acl_hdr(skb, conn->handle, flags); in hci_queue_acl()
3760 hci_add_acl_hdr(skb, conn->handle, flags); in hci_queue_acl()
3773 struct hci_dev *hdev = chan->conn->hdev; in hci_send_acl()
3783 void hci_send_sco(struct hci_conn *conn, struct sk_buff *skb) in hci_send_sco() argument
3785 struct hci_dev *hdev = conn->hdev; in hci_send_sco()
3790 hdr.handle = cpu_to_le16(conn->handle); in hci_send_sco()
3799 skb_queue_tail(&conn->data_q, skb); in hci_send_sco()
3810 struct hci_conn *conn = NULL, *c; in hci_low_sent() local
3829 conn = c; in hci_low_sent()
3838 if (conn) { in hci_low_sent()
3841 switch (conn->type) { in hci_low_sent()
3862 BT_DBG("conn %p quote %d", conn, *quote); in hci_low_sent()
3863 return conn; in hci_low_sent()
3893 struct hci_conn *conn; in hci_chan_sent() local
3900 list_for_each_entry_rcu(conn, &h->list, list) { in hci_chan_sent()
3903 if (conn->type != type) in hci_chan_sent()
3906 if (conn->state != BT_CONNECTED && conn->state != BT_CONFIG) in hci_chan_sent()
3911 list_for_each_entry_rcu(tmp, &conn->chan_list, list) { in hci_chan_sent()
3929 if (conn->sent < min) { in hci_chan_sent()
3930 min = conn->sent; in hci_chan_sent()
3944 switch (chan->conn->type) { in hci_chan_sent()
3972 struct hci_conn *conn; in hci_prio_recalculate() local
3979 list_for_each_entry_rcu(conn, &h->list, list) { in hci_prio_recalculate()
3982 if (conn->type != type) in hci_prio_recalculate()
3985 if (conn->state != BT_CONNECTED && conn->state != BT_CONFIG) in hci_prio_recalculate()
3990 list_for_each_entry_rcu(chan, &conn->chan_list, list) { in hci_prio_recalculate()
4058 hci_conn_enter_active_mode(chan->conn, in hci_sched_acl_pkt()
4066 chan->conn->sent++; in hci_sched_acl_pkt()
4110 hci_conn_enter_active_mode(chan->conn, in hci_sched_acl_blk()
4120 chan->conn->sent += blocks; in hci_sched_acl_blk()
4154 struct hci_conn *conn; in hci_sched_sco() local
4163 while (hdev->sco_cnt && (conn = hci_low_sent(hdev, SCO_LINK, &quote))) { in hci_sched_sco()
4164 while (quote-- && (skb = skb_dequeue(&conn->data_q))) { in hci_sched_sco()
4168 conn->sent++; in hci_sched_sco()
4169 if (conn->sent == ~0) in hci_sched_sco()
4170 conn->sent = 0; in hci_sched_sco()
4177 struct hci_conn *conn; in hci_sched_esco() local
4186 while (hdev->sco_cnt && (conn = hci_low_sent(hdev, ESCO_LINK, in hci_sched_esco()
4188 while (quote-- && (skb = skb_dequeue(&conn->data_q))) { in hci_sched_esco()
4192 conn->sent++; in hci_sched_esco()
4193 if (conn->sent == ~0) in hci_sched_esco()
4194 conn->sent = 0; in hci_sched_esco()
4237 chan->conn->sent++; in hci_sched_le()
4277 struct hci_conn *conn; in hci_acldata_packet() local
4292 conn = hci_conn_hash_lookup_handle(hdev, handle); in hci_acldata_packet()
4295 if (conn) { in hci_acldata_packet()
4296 hci_conn_enter_active_mode(conn, BT_POWER_FORCE_ACTIVE_OFF); in hci_acldata_packet()
4299 l2cap_recv_acldata(conn, skb, flags); in hci_acldata_packet()
4313 struct hci_conn *conn; in hci_scodata_packet() local
4325 conn = hci_conn_hash_lookup_handle(hdev, handle); in hci_scodata_packet()
4328 if (conn) { in hci_scodata_packet()
4330 sco_recv_scodata(conn, skb); in hci_scodata_packet()