]> err.no Git - linux-2.6/commitdiff
[Bluetooth] Disconnect HID interrupt channel first
authorMarcel Holtmann <marcel@holtmann.org>
Sun, 15 Oct 2006 15:31:00 +0000 (17:31 +0200)
committerDavid S. Miller <davem@sunset.davemloft.net>
Mon, 16 Oct 2006 06:14:31 +0000 (23:14 -0700)
The Bluetooth HID specification demands that the interrupt channel
shall be disconnected first. This is needed to pass the qualification
tests.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
net/bluetooth/hidp/core.c

index 03b5dadb49511f90b0c57ee6d9d677d580c5ef18..b2d6da67d885f3a40503bbdf69195b3ddb945657 100644 (file)
@@ -510,11 +510,11 @@ static int hidp_session(void *arg)
        if (intr_sk->sk_state != BT_CONNECTED)
                wait_event_timeout(*(ctrl_sk->sk_sleep), (ctrl_sk->sk_state == BT_CLOSED), HZ);
 
-       fput(session->ctrl_sock->file);
+       fput(session->intr_sock->file);
 
        wait_event_timeout(*(intr_sk->sk_sleep), (intr_sk->sk_state == BT_CLOSED), HZ);
 
-       fput(session->intr_sock->file);
+       fput(session->ctrl_sock->file);
 
        __hidp_unlink_session(session);