Bluetooth: Disable FCS only for new HS channels
authorAndrei Emeltchenko <andrei.emeltchenko@intel.com>
Wed, 14 Nov 2012 15:39:31 +0000 (17:39 +0200)
committerGustavo Padovan <gustavo.padovan@collabora.co.uk>
Mon, 19 Nov 2012 21:30:35 +0000 (19:30 -0200)
Set chan->fcs to L2CAP_FCS_NONE only for new L2CAP channels
(not moved). Other side can still request to use FCS.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
net/bluetooth/amp.c
net/bluetooth/l2cap_core.c

index eaf473ffeef9e47fe3e67de9b9245e257ce8aeea..0258b2645edbfc2f97d93642c09b8e5c20f18f59 100644 (file)
@@ -392,7 +392,6 @@ void amp_physical_cfm(struct hci_conn *bredr_hcon, struct hci_conn *hs_hcon)
        bredr_chan->remote_amp_id = hs_hcon->remote_id;
        bredr_chan->hs_hcon = hs_hcon;
        bredr_chan->conn->mtu = hs_hcon->hdev->block_mtu;
-       bredr_chan->fcs = L2CAP_FCS_NONE;
 
        __l2cap_physical_cfm(bredr_chan, 0);
 
index 22c4ef926b0d61340ec7267bcf1cc89f9d8cdbf8..fc92fe3411151108b0ca62abc69c1d734ec6f5d3 100644 (file)
@@ -4517,6 +4517,8 @@ void l2cap_move_start(struct l2cap_chan *chan)
 static void l2cap_do_create(struct l2cap_chan *chan, int result,
                            u8 local_amp_id, u8 remote_amp_id)
 {
+       chan->fcs = L2CAP_FCS_NONE;
+
        if (!test_bit(CONF_CONNECT_PEND, &chan->conf_state)) {
                struct l2cap_conn_rsp rsp;
                char buf[128];