diff -ur --exclude-from=kernel-diff-exclude.txt linux-2.6.18-mh1/net/bluetooth/hidp/core.c linux-2.6.18-my-bt/net/bluetooth/hidp/core.c --- linux-2.6.18-mh1/net/bluetooth/hidp/core.c 2006-09-23 19:56:07.000000000 -0700 +++ linux-2.6.18-my-bt/net/bluetooth/hidp/core.c 2006-09-23 23:00:22.000000000 -0700 @@ -41,7 +41,6 @@ #include "hid.h" #include -#include #include #include "hidp.h" @@ -573,26 +572,6 @@ return 0; } -static struct device *hidp_get_device(struct hidp_session *session) -{ - bdaddr_t *src = &bt_sk(session->ctrl_sock->sk)->src; - bdaddr_t *dst = &bt_sk(session->ctrl_sock->sk)->dst; - struct hci_dev *hdev; - struct hci_conn *conn; - - hdev = hci_get_route(dst, src); - if (!hdev) - return NULL; - - conn = hci_conn_hash_lookup_ba(hdev, ACL_LINK, dst); - if (!conn) - return NULL; - - hci_dev_put(hdev); - - return &conn->dev; -} - static inline void hidp_setup_input(struct hidp_session *session, struct hidp_connadd_req *req) { struct input_dev *input = session->input; @@ -631,8 +610,6 @@ input->relbit[0] |= BIT(REL_WHEEL); } - input->cdev.dev = hidp_get_device(session); - input->event = hidp_input_event; input_register_device(input); @@ -660,8 +637,6 @@ strncpy(hid->phys, batostr(&src), 64); strncpy(hid->uniq, batostr(&dst), 64); - hid->dev = hidp_get_device(session); - hid->send = hid_send_report; hid_register_device(hid);