X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=net%2Fbluetooth%2Faf_bluetooth.c;fp=net%2Fbluetooth%2Faf_bluetooth.c;h=fb031fe9be9ed140bce6fdfe6092f3ab6df8ff87;hb=64ba3f394c830ec48a1c31b53dcae312c56f1604;hp=788ea7a2b74498c10534501e62c3e91fd17c117e;hpb=be1e6109ac94a859551f8e1774eb9a8469fe055c;p=linux-2.6.git diff --git a/net/bluetooth/af_bluetooth.c b/net/bluetooth/af_bluetooth.c index 788ea7a2b..fb031fe9b 100644 --- a/net/bluetooth/af_bluetooth.c +++ b/net/bluetooth/af_bluetooth.c @@ -24,6 +24,7 @@ /* Bluetooth address family and sockets. */ +#include #include #include @@ -48,7 +49,7 @@ #define BT_DBG(D...) #endif -#define VERSION "2.10" +#define VERSION "2.8" /* Bluetooth sockets */ #define BT_MAX_PROTO 8 @@ -237,9 +238,6 @@ unsigned int bt_sock_poll(struct file * file, struct socket *sock, poll_table *w if (sk->sk_err || !skb_queue_empty(&sk->sk_error_queue)) mask |= POLLERR; - if (sk->sk_shutdown & RCV_SHUTDOWN) - mask |= POLLRDHUP; - if (sk->sk_shutdown == SHUTDOWN_MASK) mask |= POLLHUP; @@ -307,22 +305,14 @@ static struct net_proto_family bt_sock_family_ops = { static int __init bt_init(void) { - int err; - BT_INFO("Core ver %s", VERSION); - err = bt_sysfs_init(); - if (err < 0) - return err; - - err = sock_register(&bt_sock_family_ops); - if (err < 0) { - bt_sysfs_cleanup(); - return err; - } + sock_register(&bt_sock_family_ops); BT_INFO("HCI device and connection manager initialized"); + bt_sysfs_init(); + hci_sock_init(); return 0; @@ -332,9 +322,9 @@ static void __exit bt_exit(void) { hci_sock_cleanup(); - sock_unregister(PF_BLUETOOTH); - bt_sysfs_cleanup(); + + sock_unregister(PF_BLUETOOTH); } subsys_initcall(bt_init);