@@ -1784,24 +1784,6 @@ int hci_update_random_address(struct hci_request *req, bool require_privacy,
return 0;
}
-static bool disconnected_accept_list_entries(struct hci_dev *hdev)
-{
- struct bdaddr_list *b;
-
- list_for_each_entry(b, &hdev->accept_list, list) {
- struct hci_conn *conn;
-
- conn = hci_conn_hash_lookup_ba(hdev, ACL_LINK, &b->bdaddr);
- if (!conn)
- return true;
-
- if (conn->state != BT_CONNECTED && conn->state != BT_CONFIG)
- return true;
- }
-
- return false;
-}
-
void __hci_req_update_scan(struct hci_request *req)
{
struct hci_dev *hdev = req->hdev;
@@ -120,6 +120,8 @@ void __hci_req_update_scan(struct hci_request *req);
int hci_update_random_address(struct hci_request *req, bool require_privacy,
bool use_rpa, u8 *own_addr_type);
+bool disconnected_accept_list_entries(struct hci_dev *hdev);
+
int hci_abort_conn(struct hci_conn *conn, u8 reason);
void __hci_abort_conn(struct hci_request *req, struct hci_conn *conn,
u8 reason);
@@ -2419,7 +2419,7 @@ int hci_write_fast_connectable_sync(struct hci_dev *hdev, bool enable)
return err;
}
-static bool disconnected_accept_list_entries(struct hci_dev *hdev)
+bool disconnected_accept_list_entries(struct hci_dev *hdev)
{
struct bdaddr_list *b;
both hci_request.c and hci_sync.c have the same definition for disconnected_accept_list_entries(), so remove a redundant copy. Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com> --- v3->v4 -use 75 characters per line for Linux commit message bodies v2->v3 -remove table char to solve gitlint checking failure v1->v2 -remove the func copy within hci_request.c instead of hci_sync.c net/bluetooth/hci_request.c | 18 ------------------ net/bluetooth/hci_request.h | 2 ++ net/bluetooth/hci_sync.c | 2 +- 3 files changed, 3 insertions(+), 19 deletions(-)