]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
Bluetooth: h5: Do not initialize Configuration field
authorAndrei Emeltchenko <andrei.emeltchenko@intel.com>
Thu, 10 Dec 2015 15:03:43 +0000 (17:03 +0200)
committerMarcel Holtmann <marcel@holtmann.org>
Thu, 10 Dec 2015 18:19:17 +0000 (19:19 +0100)
Initializing Configuration field in H5 Config message to 0x01 gives
wrong impression that the value is used and needed. Later on the whole
field is rewritten with h5_cfg_field().

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
drivers/bluetooth/hci_h5.c

index 2d1c9f6a912c63a5449038dd8988af0515c383fc..0879d64b1caf58afb6e5d494c07d9ab7e7cdf983 100644 (file)
@@ -123,7 +123,7 @@ static u8 h5_cfg_field(struct h5 *h5)
 static void h5_timed_event(unsigned long arg)
 {
        const unsigned char sync_req[] = { 0x01, 0x7e };
-       unsigned char conf_req[] = { 0x03, 0xfc, 0x01 };
+       unsigned char conf_req[3] = { 0x03, 0xfc };
        struct hci_uart *hu = (struct hci_uart *)arg;
        struct h5 *h5 = hu->priv;
        struct sk_buff *skb;
@@ -281,7 +281,7 @@ static void h5_handle_internal_rx(struct hci_uart *hu)
        struct h5 *h5 = hu->priv;
        const unsigned char sync_req[] = { 0x01, 0x7e };
        const unsigned char sync_rsp[] = { 0x02, 0x7d };
-       unsigned char conf_req[] = { 0x03, 0xfc, 0x01 };
+       unsigned char conf_req[3] = { 0x03, 0xfc };
        const unsigned char conf_rsp[] = { 0x04, 0x7b };
        const unsigned char wakeup_req[] = { 0x05, 0xfa };
        const unsigned char woken_req[] = { 0x06, 0xf9 };